- Timestamp:
- 07/02/13 22:31:23 (11 years ago)
- Location:
- cpp/gdk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
cpp/gdk/extvalue.cpp
r82 r92 7 7 #include <math.h> 8 8 9 SString ExtObject::toString() 9 SString ExtObject::toString() const 10 10 { 11 11 if (isEmpty()) return SString("<empty object>"); -
cpp/gdk/extvalue.h
r66 r92 59 59 int operator==(const ExtObject& src) {if (object!=src.object) return 0; return (object==0)?(param==src.param):1;} 60 60 61 SString toString() ;61 SString toString() const; 62 62 63 63 ExtObject(Param *p,void *o):subtype(2),object(o),param(p){} -
cpp/gdk/sstring.cpp
r81 r92 6 6 #include "sstring.h" 7 7 #include "nonstd_stl.h" 8 8 #include "extvalue.h" 9 9 10 10 static int guessMemSize(int request, int memhint) … … 312 312 return t; 313 313 } 314 const SString& SString::valueOf(long i) 315 { 316 static SString t; 317 sprintf(t.directWrite(20),"%d",i); t.endWrite(); 318 return t; 319 } 314 320 const SString& SString::valueOf(double d) 315 321 { … … 318 324 return t; 319 325 } 326 const SString& SString::valueOf(const SString& s) 327 { 328 return s; 329 } 330 SString SString::valueOf(const ExtValue& v) 331 { 332 return v.getString(); 333 } 334 SString SString::valueOf(const ExtObject& v) 335 { 336 return v.toString(); 337 } 320 338 321 339 SString &SString::empty() -
cpp/gdk/sstring.h
r81 r92 9 9 #include <stdlib.h> 10 10 #include <stdio.h> 11 12 class ExtValue; //this include would result in recurrent inclusion: #include "extvalue.h" 13 class ExtObject; 11 14 12 15 class SBuf … … 155 158 156 159 static const SString& valueOf(int); 160 static const SString& valueOf(long); 157 161 static const SString& valueOf(double); 162 static const SString& valueOf(const SString&); //tylko do kompletu zeby mozna uzyc tej funkcji nie martwiac sie o typ argumentu 163 static SString valueOf(const ExtValue&); //tylko do kompletu zeby mozna uzyc tej funkcji nie martwiac sie o typ argumentu 164 static SString valueOf(const ExtObject&); //tylko do kompletu zeby mozna uzyc tej funkcji nie martwiac sie o typ argumentu 158 165 159 166 static SString &empty();
Note: See TracChangeset
for help on using the changeset viewer.