Changeset 2937 for code/branches/netp2/src/util
- Timestamp:
- Apr 29, 2009, 4:05:35 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/netp2/src/util/MultiType.h
r2861 r2937 330 330 inline void exportData(uint8_t*& mem) { assert(sizeof(MT_Type)<=8); this->setType(*(uint8_t*)mem); mem+=sizeof(uint8_t); this->value_->exportData(mem); } 331 331 /** @brief Saves the value of the MT to a bytestream and increases pointer to bytestream by size of MT */ 332 inline uint8_t*& operator << (uint8_t*& mem) { importData(mem); return mem; }332 inline uint8_t*& operator << (uint8_t*& mem) { importData(mem); return mem; } 333 333 /** @brief Loads the value of the MT to a bytestream and increases pointer to bytestream by size of MT */ 334 inline void operator >> (uint8_t*& mem) { exportData(mem); } 334 inline void operator >> (uint8_t*& mem) { exportData(mem); } 335 inline uint32_t getNetworkSize() { assert(this->value_); return this->value_->getSize() + sizeof(uint8_t); } 335 336 336 337 /** @brief Checks whether the value is a default one. */
Note: See TracChangeset
for help on using the changeset viewer.