#include <lldatapacker.h>
Inheritance diagram for LLDataPackerBinaryBuffer:
Public Member Functions | |
LLDataPackerBinaryBuffer (U8 *bufferp, S32 size) | |
LLDataPackerBinaryBuffer () | |
BOOL | packString (const char *value, const char *name) |
BOOL | unpackString (std::string &value, const char *name) |
BOOL | packBinaryData (const U8 *value, S32 size, const char *name) |
BOOL | unpackBinaryData (U8 *value, S32 &size, const char *name) |
BOOL | packBinaryDataFixed (const U8 *value, S32 size, const char *name) |
BOOL | unpackBinaryDataFixed (U8 *value, S32 size, const char *name) |
BOOL | packU8 (const U8 value, const char *name) |
BOOL | unpackU8 (U8 &value, const char *name) |
BOOL | packU16 (const U16 value, const char *name) |
BOOL | unpackU16 (U16 &value, const char *name) |
BOOL | packU32 (const U32 value, const char *name) |
BOOL | unpackU32 (U32 &value, const char *name) |
BOOL | packS32 (const S32 value, const char *name) |
BOOL | unpackS32 (S32 &value, const char *name) |
BOOL | packF32 (const F32 value, const char *name) |
BOOL | unpackF32 (F32 &value, const char *name) |
BOOL | packColor4 (const LLColor4 &value, const char *name) |
BOOL | unpackColor4 (LLColor4 &value, const char *name) |
BOOL | packColor4U (const LLColor4U &value, const char *name) |
BOOL | unpackColor4U (LLColor4U &value, const char *name) |
BOOL | packVector2 (const LLVector2 &value, const char *name) |
BOOL | unpackVector2 (LLVector2 &value, const char *name) |
BOOL | packVector3 (const LLVector3 &value, const char *name) |
BOOL | unpackVector3 (LLVector3 &value, const char *name) |
BOOL | packVector4 (const LLVector4 &value, const char *name) |
BOOL | unpackVector4 (LLVector4 &value, const char *name) |
BOOL | packUUID (const LLUUID &value, const char *name) |
BOOL | unpackUUID (LLUUID &value, const char *name) |
S32 | getCurrentSize () const |
S32 | getBufferSize () const |
void | reset () |
void | freeBuffer () |
void | assignBuffer (U8 *bufferp, S32 size) |
const LLDataPackerBinaryBuffer & | operator= (const LLDataPackerBinaryBuffer &a) |
BOOL | hasNext () const |
void | dumpBufferToLog () |
Protected Member Functions | |
BOOL | verifyLength (const S32 data_size, const char *name) |
Protected Attributes | |
U8 * | mBufferp |
U8 * | mCurBufferp |
S32 | mBufferSize |
Definition at line 110 of file lldatapacker.h.
LLDataPackerBinaryBuffer::LLDataPackerBinaryBuffer | ( | ) | [inline] |
Definition at line 122 of file lldatapacker.h.
Definition at line 177 of file lldatapacker.h.
References mBufferp, mBufferSize, mCurBufferp, LLDataPacker::mWriteEnabled, and TRUE.
Referenced by LLVOCacheEntry::assignCRC(), LLVOCacheEntry::LLVOCacheEntry(), and LLViewerObjectList::processObjectUpdate().
void LLDataPackerBinaryBuffer::dumpBufferToLog | ( | ) | [virtual] |
Reimplemented from LLDataPacker.
Definition at line 552 of file lldatapacker.cpp.
References i, llendl, llwarns, mBufferp, mBufferSize, and S32.
void LLDataPackerBinaryBuffer::freeBuffer | ( | ) | [inline] |
Definition at line 176 of file lldatapacker.h.
References FALSE, mBufferp, mBufferSize, mCurBufferp, LLDataPacker::mWriteEnabled, and NULL.
Referenced by LLVOCacheEntry::assignCRC().
S32 LLDataPackerBinaryBuffer::getBufferSize | ( | ) | const [inline] |
Definition at line 174 of file lldatapacker.h.
References mBufferSize.
Referenced by LLVOCacheEntry::assignCRC(), LLVOCacheEntry::getDP(), hasNext(), LLVOCacheEntry::LLVOCacheEntry(), operator=(), and LLVOCacheEntry::writeToFile().
S32 LLDataPackerBinaryBuffer::getCurrentSize | ( | ) | const [inline] |
Definition at line 173 of file lldatapacker.h.
References mBufferp, mCurBufferp, and S32.
Referenced by LLKeyframeMotion::getFileSize(), LLBVHLoader::getOutputSize(), hasNext(), LLFloaterAnimPreview::onBtnOK(), LLViewerObject::parameterChanged(), LLViewerThrottleGroup::sendToSim(), LLTransferTargetChannel::sendTransferRequest(), and LLTransferSource::sendTransferStatus().
BOOL LLDataPackerBinaryBuffer::hasNext | ( | ) | const [inline, virtual] |
Implements LLDataPacker.
Definition at line 186 of file lldatapacker.h.
References getBufferSize(), and getCurrentSize().
const LLDataPackerBinaryBuffer & LLDataPackerBinaryBuffer::operator= | ( | const LLDataPackerBinaryBuffer & | a | ) |
Definition at line 541 of file lldatapacker.cpp.
References a, getBufferSize(), llendl, llerrs, and mBufferp.
BOOL LLDataPackerBinaryBuffer::packBinaryData | ( | const U8 * | value, | |
S32 | size, | |||
const char * | name | |||
) | [virtual] |
Implements LLDataPacker.
Definition at line 202 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_S32, MVT_VARIABLE, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
BOOL LLDataPackerBinaryBuffer::packBinaryDataFixed | ( | const U8 * | value, | |
S32 | size, | |||
const char * | name | |||
) | [virtual] |
Implements LLDataPacker.
Definition at line 242 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_VARIABLE, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 391 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLColor4::mV, MVT_LLVector4, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 416 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLColor4U::mV, MVT_VARIABLE, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 366 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_F32, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
Referenced by LLViewerThrottleGroup::sendToSim().
Implements LLDataPacker.
Definition at line 341 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_S32, LLDataPacker::mWriteEnabled, S32, TRUE, and verifyLength().
BOOL LLDataPackerBinaryBuffer::packString | ( | const char * | value, | |
const char * | name | |||
) | [virtual] |
Implements LLDataPacker.
Definition at line 173 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_VARIABLE, LLDataPacker::mWriteEnabled, S32, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 291 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_U16, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 316 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_U32, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 266 of file lldatapacker.cpp.
References mCurBufferp, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 517 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLUUID::mData, MVT_LLUUID, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 442 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLVector2::mV, MVT_F32, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 469 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLVector3::mV, MVT_LLVector3, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 493 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLVector4::mV, MVT_LLVector4, LLDataPacker::mWriteEnabled, TRUE, and verifyLength().
void LLDataPackerBinaryBuffer::reset | ( | ) | [inline, virtual] |
Reimplemented from LLDataPacker.
Definition at line 175 of file lldatapacker.h.
References mBufferp, mCurBufferp, LLDataPacker::mWriteEnabled, and NULL.
Referenced by LLFloaterAnimPreview::postBuild(), and LLViewerObjectList::processObjectUpdate().
BOOL LLDataPackerBinaryBuffer::unpackBinaryData | ( | U8 * | value, | |
S32 & | size, | |||
const char * | name | |||
) | [virtual] |
Implements LLDataPacker.
Definition at line 221 of file lldatapacker.cpp.
References FALSE, htonmemcpy(), llendl, llwarns, mCurBufferp, MVT_S32, MVT_VARIABLE, TRUE, and verifyLength().
Referenced by LLViewerObject::processUpdateMessage().
BOOL LLDataPackerBinaryBuffer::unpackBinaryDataFixed | ( | U8 * | value, | |
S32 | size, | |||
const char * | name | |||
) | [virtual] |
Implements LLDataPacker.
Definition at line 256 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_VARIABLE, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 405 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLColor4::mV, MVT_LLVector4, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 430 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLColor4U::mV, MVT_VARIABLE, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 380 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_F32, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 355 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_S32, S32, TRUE, and verifyLength().
BOOL LLDataPackerBinaryBuffer::unpackString | ( | std::string & | value, | |
const char * | name | |||
) | [virtual] |
Implements LLDataPacker.
Definition at line 189 of file lldatapacker.cpp.
References mCurBufferp, S32, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 305 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_U16, TRUE, and verifyLength().
Referenced by LLViewerObject::processUpdateMessage().
Implements LLDataPacker.
Definition at line 330 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, MVT_U32, TRUE, and verifyLength().
Referenced by LLPartSysData::isNullPS(), and LLViewerObjectList::processObjectUpdate().
Implements LLDataPacker.
Definition at line 280 of file lldatapacker.cpp.
References mCurBufferp, TRUE, and verifyLength().
Referenced by LLViewerObjectList::processObjectUpdate(), and LLViewerObject::processUpdateMessage().
Implements LLDataPacker.
Definition at line 531 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLUUID::mData, MVT_LLUUID, TRUE, and verifyLength().
Referenced by LLViewerObjectList::processObjectUpdate().
Implements LLDataPacker.
Definition at line 457 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLVector2::mV, MVT_F32, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 483 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLVector3::mV, MVT_LLVector3, TRUE, and verifyLength().
Implements LLDataPacker.
Definition at line 507 of file lldatapacker.cpp.
References htonmemcpy(), mCurBufferp, LLVector4::mV, MVT_LLVector4, TRUE, and verifyLength().
BOOL LLDataPackerBinaryBuffer::verifyLength | ( | const S32 | data_size, | |
const char * | name | |||
) | [inline, protected] |
Definition at line 197 of file lldatapacker.h.
References FALSE, llendl, llwarns, mBufferp, mBufferSize, mCurBufferp, LLDataPacker::mWriteEnabled, and TRUE.
Referenced by packBinaryData(), packBinaryDataFixed(), packColor4(), packColor4U(), packF32(), packS32(), packString(), packU16(), packU32(), packU8(), packUUID(), packVector2(), packVector3(), packVector4(), unpackBinaryData(), unpackBinaryDataFixed(), unpackColor4(), unpackColor4U(), unpackF32(), unpackS32(), unpackString(), unpackU16(), unpackU32(), unpackU8(), unpackUUID(), unpackVector2(), unpackVector3(), and unpackVector4().
U8* LLDataPackerBinaryBuffer::mBufferp [protected] |
Definition at line 192 of file lldatapacker.h.
Referenced by assignBuffer(), dumpBufferToLog(), freeBuffer(), getCurrentSize(), operator=(), reset(), and verifyLength().
S32 LLDataPackerBinaryBuffer::mBufferSize [protected] |
Definition at line 194 of file lldatapacker.h.
Referenced by assignBuffer(), dumpBufferToLog(), freeBuffer(), getBufferSize(), and verifyLength().
U8* LLDataPackerBinaryBuffer::mCurBufferp [protected] |
Definition at line 193 of file lldatapacker.h.
Referenced by assignBuffer(), freeBuffer(), getCurrentSize(), packBinaryData(), packBinaryDataFixed(), packColor4(), packColor4U(), packF32(), packS32(), packString(), packU16(), packU32(), packU8(), packUUID(), packVector2(), packVector3(), packVector4(), reset(), unpackBinaryData(), unpackBinaryDataFixed(), unpackColor4(), unpackColor4U(), unpackF32(), unpackS32(), unpackString(), unpackU16(), unpackU32(), unpackU8(), unpackUUID(), unpackVector2(), unpackVector3(), unpackVector4(), and verifyLength().