Changeset 273
- Timestamp:
- 09/15/11 10:08:53 (13 years ago)
- Location:
- XMLIO_V2/dev/dev_rv
- Files:
-
- 2 deleted
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
XMLIO_V2/dev/dev_rv/src/xmlio/node/variable.cpp
r272 r273 62 62 } 63 63 64 void CVariable::toBinary(StdOStream & os) const 65 { 66 const StdString & content = this->content; 67 const StdSize size = content.size(); 68 SuperClass::toBinary(os); 69 70 os.write (reinterpret_cast<const char*>(&size), sizeof(StdSize)); 71 os.write (content.data(), size * sizeof(char)); 72 } 73 74 void CVariable::fromBinary(StdIStream & is) 75 { 76 SuperClass::fromBinary(is); 77 StdSize size = 0; 78 is.read (reinterpret_cast<char*>(&size), sizeof(StdSize)); 79 this->content.assign(size, ' '); 80 is.read (const_cast<char *>(this->content.data()), size * sizeof(char)); 81 } 82 64 83 void CVariableGroup::parse(xml::CXMLNode & node, bool withAttr) 65 84 { -
XMLIO_V2/dev/dev_rv/src/xmlio/node/variable.hpp
r272 r273 57 57 virtual StdString toString(void) const; 58 58 59 //virtual void toBinary (StdOStream & os) const;60 //virtual void fromBinary(StdIStream & is);59 virtual void toBinary (StdOStream & os) const; 60 virtual void fromBinary(StdIStream & is); 61 61 62 62 /// Accesseur ///
Note: See TracChangeset
for help on using the changeset viewer.