|
BitMagic-C++
|
layout class for serialization buffer structure More...
#include <bmsparsevec_serial.h>

Public Types | |
| typedef SV::value_type | value_type |
| typedef SV::bvector_type | bvector_type |
| typedef bvector_type::allocator_type | allocator_type |
| typedef serializer< bvector_type >::buffer | buffer_type |
Public Member Functions | |
| sparse_vector_serial_layout () BMNOEXCEPT | |
| ~sparse_vector_serial_layout () | |
| unsigned char * | reserve (size_t capacity) |
| resize capacity | |
| size_t | size () const BMNOEXCEPT |
| return current serialized size | |
| void | resize (size_t ssize) |
| Set new serialized size. | |
| size_t | capacity () const BMNOEXCEPT |
| return serialization buffer capacity | |
| void | freemem () BMNOEXCEPT |
| free memory | |
| void | set_plane (unsigned i, unsigned char *ptr, size_t buf_size) BMNOEXCEPT |
| Set plane output pointer and size. | |
| const unsigned char * | get_plane (unsigned i) const BMNOEXCEPT |
| Get plane pointer. | |
| const unsigned char * | buf () const BMNOEXCEPT |
| Return serialization buffer pointer. | |
| const unsigned char * | data () const BMNOEXCEPT |
| Return serialization buffer pointer. | |
| void | resize_slices (unsigned new_slices_size) |
| Resize for the target number of plains / bit-slices. | |
Protected Types | |
| typedef bm::heap_vector< unsigned char *, allocator_type, true > | ptr_vector_type |
| typedef bm::heap_vector< size_t, allocator_type, true > | sizet_vector_type |
Protected Attributes | |
| buffer_type | buf_ |
| serialization buffer | |
| ptr_vector_type | plane_ptrs_ |
| pointers on serialized bit-planes | |
| sizet_vector_type | plane_size_ |
| serialized plane size | |
layout class for serialization buffer structure
Class keeps a memory block sized for the target sparse vector BLOB. This class also provides acess to bit-plane memory, so it becomes possible to use parallel storage methods to save bit-planes into different storage shards.
Definition at line 57 of file bmsparsevec_serial.h.
| typedef bvector_type::allocator_type bm::sparse_vector_serial_layout< SV >::allocator_type |
Definition at line 61 of file bmsparsevec_serial.h.
| typedef serializer<bvector_type>::buffer bm::sparse_vector_serial_layout< SV >::buffer_type |
Definition at line 62 of file bmsparsevec_serial.h.
| typedef SV::bvector_type bm::sparse_vector_serial_layout< SV >::bvector_type |
Definition at line 60 of file bmsparsevec_serial.h.
|
protected |
Definition at line 123 of file bmsparsevec_serial.h.
|
protected |
Definition at line 124 of file bmsparsevec_serial.h.
| typedef SV::value_type bm::sparse_vector_serial_layout< SV >::value_type |
Definition at line 59 of file bmsparsevec_serial.h.
|
inline |
Definition at line 64 of file bmsparsevec_serial.h.
References BMNOEXCEPT.
|
inline |
Definition at line 66 of file bmsparsevec_serial.h.
|
inline |
Return serialization buffer pointer.
Definition at line 108 of file bmsparsevec_serial.h.
References BMNOEXCEPT, and buf_.
|
inline |
return serialization buffer capacity
Definition at line 91 of file bmsparsevec_serial.h.
References BMNOEXCEPT, and buf_.
Referenced by reserve(), and bm::sparse_vector_serializer< SV >::serialize().
|
inline |
Return serialization buffer pointer.
Definition at line 110 of file bmsparsevec_serial.h.
References BMNOEXCEPT, and buf_.
Referenced by SDemo2(), write_as_rsc_svector(), and write_as_svector().
|
inline |
free memory
Definition at line 94 of file bmsparsevec_serial.h.
References BMNOEXCEPT, and buf_.
Referenced by reserve().
|
inline |
Get plane pointer.
Definition at line 104 of file bmsparsevec_serial.h.
References BMNOEXCEPT, and plane_ptrs_.
Referenced by bm::sparse_vector_serializer< SV >::serialize().
|
inline |
resize capacity
| capacity | - new capacity |
Definition at line 73 of file bmsparsevec_serial.h.
References buf_, capacity(), and freemem().
Referenced by bm::sparse_vector_serializer< SV >::serialize().
|
inline |
Set new serialized size.
Definition at line 88 of file bmsparsevec_serial.h.
References buf_.
Referenced by bm::sparse_vector_serializer< SV >::serialize().
|
inline |
Resize for the target number of plains / bit-slices.
Definition at line 113 of file bmsparsevec_serial.h.
References plane_ptrs_, and plane_size_.
Referenced by bm::sparse_vector_serializer< SV >::serialize().
|
inline |
Set plane output pointer and size.
Definition at line 97 of file bmsparsevec_serial.h.
References BMNOEXCEPT, plane_ptrs_, and plane_size_.
Referenced by bm::sv_serialization_plan_builder< SV >::build_plan(), and bm::sparse_vector_serializer< SV >::serialize().
|
inline |
return current serialized size
Definition at line 85 of file bmsparsevec_serial.h.
References BMNOEXCEPT, and buf_.
Referenced by compress_inv_dump_file(), main(), SDemo1(), SDemo2(), serialize_df0(), serialize_df2(), write_as_rsc_svector(), and write_as_svector().
|
protected |
serialization buffer
Definition at line 127 of file bmsparsevec_serial.h.
Referenced by buf(), capacity(), data(), freemem(), reserve(), resize(), and size().
|
protected |
pointers on serialized bit-planes
Definition at line 128 of file bmsparsevec_serial.h.
Referenced by get_plane(), resize_slices(), and set_plane().
|
protected |
serialized plane size
Definition at line 129 of file bmsparsevec_serial.h.
Referenced by resize_slices(), and set_plane().