#include <PagedMemory.h>
Public Types | |
typedef eformat::PagedMemory::node_t | node_t |
typedef eformat::PagedMemory::node_t | node_t |
Public Member Functions | |
const_iterator | begin (void) const |
const_iterator | begin (void) const |
size_t | count (void) const |
size_t | count (void) const |
const_iterator | end (void) const |
const_iterator | end (void) const |
PagedMemory (const struct iovec *pages, size_t count) | |
PagedMemory (const struct iovec *pages, size_t count) | |
const struct iovec * | pages (void) const |
const struct iovec * | pages (void) const |
size_t | size (void) const |
size_t | size (void) const |
Static Public Attributes | |
const unsigned int | MAXPAGES = TMAXPAGES |
Private Attributes | |
size_t | m_count |
how many pages do I have in the list above | |
const struct iovec * | m_iovec |
my iovec set of pages | |
const struct iovec * | m_iovec |
my iovec set of pages | |
node_t | m_node [TMAXPAGES] |
index | |
size_t | m_size |
the number of words I have in this Memory |
Attention: PagedMemory's with different index sizes cannot interact directly.
|
Define a private type that is used to index the access to this type of eformat::Memory. The performance of this iterator is dependent on the distance from the current offset and on the page sizes. Try to use the iterator for small scale reach and readjust if necessary. |
|
Define a private type that is used to index the access to this type of eformat::Memory. The performance of this iterator is dependent on the distance from the current offset and on the page sizes. Try to use the iterator for small scale reach and readjust if necessary. |
|
Simpler constructor: starts from an existing set of base addresses and sizes. Please note that for reasons of simplicity, the data in all memory blocks have to be 32-bit aligned. Otherwise, the implementation should be DC::Buffer, where this has all been thought about. Also note that this class is intended for reading data and optimized for such. If you just want to manipulate fragments you are better doing it your self or using the writing part of the library.
|
|
Simpler constructor: starts from an existing set of base addresses and sizes. Please note that for reasons of simplicity, the data in all memory blocks have to be 32-bit aligned. Otherwise, the implementation should be DC::Buffer, where this has all been thought about. Also note that this class is intended for reading data and optimized for such. If you just want to manipulate fragments you are better doing it your self or using the writing part of the library.
|
|
Returns a const iterator to the begin of this list
00250 { return const_iterator(m_node, 0); }
|
|
Returns a const iterator to the begin of this list
00250 { return const_iterator(m_node, 0); }
|
|
Returns the number of blocks in this IO vector 00071 { return m_count; }
|
|
Returns the number of blocks in this IO vector 00071 { return m_count; }
|
|
Returns a const iterator to the end of this list
00258 { return const_iterator(&m_node[m_count], m_size); }
|
|
Returns a const iterator to the end of this list
00258 { return const_iterator(&m_node[m_count], m_size); }
|
|
Returns the base address of the input IO vector 00066 { return m_iovec; }
|
|
Returns the base address of the input IO vector 00066 { return m_iovec; }
|
|
Returns the size in bytes words for this PagedMemory. 00076 { return m_size; }
|
|
Returns the size in bytes words for this PagedMemory. 00076 { return m_size; }
|
|
how many pages do I have in the list above
|
|
my iovec set of pages
|
|
my iovec set of pages
|
|
index
|
|
the number of words I have in this Memory
|
|
|