aboutsummaryrefslogtreecommitdiff
path: root/src/unstable/json.h
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/unstable/json.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/unstable/json.h b/src/unstable/json.h
index 2d1770d..76d96be 100644
--- a/src/unstable/json.h
+++ b/src/unstable/json.h
@@ -32,7 +32,10 @@ namespace Bu
32 32
33 public: 33 public:
34 Json(); 34 Json();
35 Json( const Bu::String &sJson ); 35 Json( const Bu::String &sValue );
36 Json( double dValue );
37 Json( bool bValue );
38 Json( Type eType );
36 Json( Bu::Stream &sInput ); 39 Json( Bu::Stream &sInput );
37 virtual ~Json(); 40 virtual ~Json();
38 41
@@ -49,6 +52,7 @@ namespace Bu
49 const_iterator end() const; 52 const_iterator end() const;
50 53
51 void parse( Bu::Stream &sInput ); 54 void parse( Bu::Stream &sInput );
55 void parse( const Bu::String &sInput );
52 void reset(); 56 void reset();
53 57
54 void write( Bu::Stream &sOutput ) const; 58 void write( Bu::Stream &sOutput ) const;
@@ -75,6 +79,10 @@ namespace Bu
75 union DatUnion 79 union DatUnion
76 { 80 {
77 DatUnion() : pObject( NULL ) { } 81 DatUnion() : pObject( NULL ) { }
82 DatUnion( const Bu::String &sValue ) :
83 pString( new Bu::String( sValue ) ) { }
84 DatUnion( double dValue ) : dNumber( dValue ) { }
85 DatUnion( bool bValue ) : bBoolean( bValue ) { }
78 JsonHash *pObject; 86 JsonHash *pObject;
79 JsonList *pArray; 87 JsonList *pArray;
80 Bu::String *pString; 88 Bu::String *pString;