void ArraySet::From( I_PacketRcv* inPacket, bool inBlock ) { argused1( inBlock ); // Destroy existing content first. InitSelf( 0 ); // 1) Allocated len. vuint32 allocLen = inPacket->get_ULongParam(); if( allocLen > 0 ) { InitSelf( allocLen / sizeof(REC_ID) ); // 2) Actual len. vuint32 actualLen = inPacket->get_ULongParam(); if( actualLen > 0) { // 3) BitSet's data. inPacket->get_BinaryParam( mpStart, actualLen ); mpFinish = mpStart + (actualLen / sizeof(REC_ID)); // 4) 'Sorted' flag. mIsSorted = inPacket->get_BoolParam(); } } }
void ArraySet::From( I_IStream_Ptr inStream, bool inBlock ) { argused1( inBlock ); // Destroy existing content first. InitSelf( 0 ); // 1) Allocated len. vuint32 allocLen; inStream->get( allocLen ); if( allocLen > 0 ) { InitSelf( allocLen / sizeof(REC_ID) ); // 2) Actual len. vuint32 actualLen; inStream->get(actualLen); if( actualLen > 0) { // 3) BitSet's data. inStream->get((vuint8*)mpStart, actualLen); mpFinish = mpStart + (actualLen / sizeof(REC_ID)); // 4) 'Sorted' flag. inStream->get( mIsSorted ); } } }
void Value_Raw::Clear( void ) { if( m_pStart ) { delete [] m_pStart; InitSelf(); } }
FBL_Begin_Namespace /**********************************************************************************************/ Value_Raw::Value_Raw( void ) : mDeltaPlus( 0 ), mIsRemote( false ) { InitSelf(); }
NotificationManager::NotificationManager(InworldSceneController *inworld_scene_controller) : QObject(), inworld_scene_controller_(inworld_scene_controller), scene_(inworld_scene_controller->GetInworldScene()), notice_max_width_(200), notice_start_pos_(QPointF()), browser_widget_(new CoreUi::NotificationBrowserWidget()), panel_(inworld_scene_controller_->GetControlPanelManager()) { InitSelf(); }
void ArraySet::InitSelfWithArraySet( const ArraySet& inSet ) { // A new array will get the size EXACTLY as the number of items in the inSet. // i.e. we do not copy empty space. vuint32 inItems = inSet.get_Count(); InitSelf( inItems ); memcpy( mpStart, inSet.begin(), inItems * sizeof(ID_TYPE) ); mpFinish = mpStart + inItems; mIsSorted = inSet.mIsSorted; }
Value_Raw::Value_Raw( const Value_Raw& inOther ) : mDeltaPlus( inOther.mDeltaPlus ), mIsRemote( false ) { InitSelf(); Alloc( inOther.get_Allocated() ); if( vuint32 len = inOther.get_Length() ) { char* pb = (char*)inOther.begin(); memcpy( m_pStart, pb, len ); m_pEnd = m_pStart + len; } }
// Convert bit vector to the ArraySet. // Note, Array is sorted automatically! // ArraySet::ArraySet( const BitSet& inSet, vuint32 ioLimitCount ) { InitSelf( inSet.get_Bits_1_Count() ); SetIterator_Ptr iter = inSet.get_Iterator(); SetIterator& refIter = *iter; ID_TYPE id; if( (id = refIter.FirstItem()) != 0 ) { do { Append( id ); } while( (id = refIter.NextItem()) && ioLimitCount-- ); put_IsSorted( true ); } }
cvar_t::cvar_t(const char* var_name, const char* def, const char* help, cvartype_t type, DWORD flags, void (*callback)(cvar_t &), float minval, float maxval) { InitSelf(var_name, def, help, type, flags, callback, minval, maxval); }
cvar_t::cvar_t(const char* var_name, const char* def, const char* help, cvartype_t type, DWORD flags, float minval, float maxval) { InitSelf(var_name, def, help, type, flags, NULL, minval, maxval); }
ArraySet::ArraySet( vuint32 ioLimitCount ) { InitSelf( ioLimitCount ); }
cvar_t::cvar_t (const char *var_name, const char *def, DWORD flags, void (*callback)(cvar_t &)) { InitSelf (var_name, def, flags, callback); }
cvar_t::cvar_t (const char *var_name, const char *def, DWORD flags) { InitSelf (var_name, def, flags, NULL); }
cvar_t::cvar_t (const char *var_name, const char *def, const char *help, cvartype_t type, DWORD flags, void (*callback)(cvar_t &)) { InitSelf (var_name, def, help, type, flags, callback); }
cvar_t::cvar_t (const char *var_name, const char *def, const char *help, cvartype_t type, DWORD flags) { InitSelf (var_name, def, help, type, flags, NULL); }