-
-
-inline void CopiedString_importString( CopiedString& self, const char* string ){
- self = string;
-}
-typedef ReferenceCaller1<CopiedString, const char*, CopiedString_importString> CopiedStringImportStringCaller;
-inline void CopiedString_exportString( const CopiedString& self, const StringImportCallback& importer ){
- importer( self.c_str() );
-}
-typedef ConstReferenceCaller1<CopiedString, const StringImportCallback&, CopiedString_exportString> CopiedStringExportStringCaller;
-
-inline void Bool_importString( bool& self, const char* string ){
- self = string_equal( string, "true" );
-}
-typedef ReferenceCaller1<bool, const char*, Bool_importString> BoolImportStringCaller;
-inline void Bool_exportString( const bool& self, const StringImportCallback& importer ){
- importer( self ? "true" : "false" );
-}
-typedef ConstReferenceCaller1<bool, const StringImportCallback&, Bool_exportString> BoolExportStringCaller;
-
-inline void Int_importString( int& self, const char* string ){
- if ( !string_parse_int( string, self ) ) {
- self = 0;
- }
-}
-typedef ReferenceCaller1<int, const char*, Int_importString> IntImportStringCaller;
-inline void Int_exportString( const int& self, const StringImportCallback& importer ){
- char buffer[16];
- sprintf( buffer, "%d", self );
- importer( buffer );
-}
-typedef ConstReferenceCaller1<int, const StringImportCallback&, Int_exportString> IntExportStringCaller;
-
-inline void Size_importString( std::size_t& self, const char* string ){
- int i;
- if ( string_parse_int( string, i ) && i >= 0 ) {
- self = i;
- }
- else
- {
- self = 0;