void List<T>::FastWriteTo( ByteBuffer& bb ) const { bb.FastVarWrite( (uint)size ); if( !std::is_pointer<T>::value && std::is_pod<T>::value ) { if( !size ) return; bb.FastWrite( (char*)buf, size * sizeof( T ) ); return; } for( int i = 0; i < size; ++i ) { bb.FastWrite( buf[ i ] ); } }
void String::FastWriteTo( ByteBuffer& bb ) const { bb.FastVarWrite( (uint)dataLen ); if( !dataLen ) return; bb.FastWrite( buf, dataLen ); }