ATLAS Offline Software
Loading...
Searching...
No Matches
TPIntegerVector_p2 Class Reference

#include <TPIntegerVector_p2.h>

Collaboration diagram for TPIntegerVector_p2:

Public Types

typedef unsigned int value_type
typedef value_typeiterator
typedef const value_typeconst_iterator
typedef TPIntegerVector_p2 IsAnIntVect

Public Member Functions

 TPIntegerVector_p2 (TPIntegerVectorStorage_p2 *storage, int idx)
unsigned size () const
unsigned reserved () const
void resize (size_t new_size)
void reserve (size_t new_size)
void grow (const size_t diff=1)
value_typeoperator[] (size_t idx)
const value_typeoperator[] (size_t idx) const
void push_back (const value_type &val)
void push_int (const int &val)
void push_float (const float &val)
void push_double (const double &val)
void push_chars (const char *const)
 store zero-terminated C string (does not write out the size)
void push_string (const std::string &)
 store std::string (assuming 8-bit chars). Uses push_chars()
void push_bytes (const void *s, size_t len)
 store blob of a given size (will write out the size)
void push_TPObjRef (const TPObjRef &val)
void push_vTPObjRef (const std::vector< TPObjRef > &val)
size_t next_string_size (const const_iterator &iter) const
 return the size of the next string/chars
size_t next_blob_size (const const_iterator &iter) const
 return the size of the next blob, in bytes
const value_typenext (const_iterator &iter) const
int next_int (const_iterator &iter) const
float next_float (const_iterator &iter) const
double next_double (const_iterator &iter) const
TPObjRef next_TPObjRef (const_iterator &iter) const
std::string next_string (const_iterator &iter) const
void next_chars (const_iterator &iter, char *buff, size_t bufflen) const
void next_bytes (const_iterator &iter, void *buff, size_t bufflen) const
void next_vTPObjRef (const_iterator &iter, std::vector< TPObjRef > &vect) const
iterator begin ()
iterator end ()
const_iterator begin () const
const_iterator end () const

Static Public Member Functions

template<typename T>
static size_t size_for (const T &)
 tell how much space the object will take in the INT vector, so it can be reserved
static size_t size_for (const char *)
static size_t size_for_ref ()
static size_t size_for_blob (size_t blobsize)

Protected Member Functions

unsigned startPos () const
bool lastElement () const
void _store_bytes (const void *, size_t len)

Protected Attributes

TPIntegerVectorStorage_p2m_storage
unsigned int m_position

Detailed Description

Definition at line 21 of file TPIntegerVector_p2.h.

Member Typedef Documentation

◆ const_iterator

Definition at line 26 of file TPIntegerVector_p2.h.

◆ IsAnIntVect

◆ iterator

Definition at line 25 of file TPIntegerVector_p2.h.

◆ value_type

typedef unsigned int TPIntegerVector_p2::value_type

Definition at line 24 of file TPIntegerVector_p2.h.

Constructor & Destructor Documentation

◆ TPIntegerVector_p2()

TPIntegerVector_p2::TPIntegerVector_p2 ( TPIntegerVectorStorage_p2 * storage,
int idx )
inline

Definition at line 30 of file TPIntegerVector_p2.h.

31 : m_storage( storage ),
32 m_position( idx<<1 )
33 {}
TPIntegerVectorStorage_p2 * m_storage

Member Function Documentation

◆ _store_bytes()

void TPIntegerVector_p2::_store_bytes ( const void * ,
size_t len )
protected

◆ begin() [1/2]

iterator TPIntegerVector_p2::begin ( )
inline

Definition at line 92 of file TPIntegerVector_p2.h.

92{ return &operator[](0); }
value_type & operator[](size_t idx)

◆ begin() [2/2]

const_iterator TPIntegerVector_p2::begin ( ) const
inline

Definition at line 95 of file TPIntegerVector_p2.h.

95{ return &operator[](0); }

◆ end() [1/2]

iterator TPIntegerVector_p2::end ( )
inline

Definition at line 93 of file TPIntegerVector_p2.h.

93{ return &operator[](size()); };
unsigned size() const

◆ end() [2/2]

const_iterator TPIntegerVector_p2::end ( ) const
inline

Definition at line 96 of file TPIntegerVector_p2.h.

96{ return &operator[](size()); };

◆ grow()

void TPIntegerVector_p2::grow ( const size_t diff = 1)

◆ lastElement()

bool TPIntegerVector_p2::lastElement ( ) const
protected

◆ next()

const value_type & TPIntegerVector_p2::next ( const_iterator & iter) const

◆ next_blob_size()

size_t TPIntegerVector_p2::next_blob_size ( const const_iterator & iter) const

return the size of the next blob, in bytes

◆ next_bytes()

void TPIntegerVector_p2::next_bytes ( const_iterator & iter,
void * buff,
size_t bufflen ) const

◆ next_chars()

void TPIntegerVector_p2::next_chars ( const_iterator & iter,
char * buff,
size_t bufflen ) const

◆ next_double()

double TPIntegerVector_p2::next_double ( const_iterator & iter) const

◆ next_float()

float TPIntegerVector_p2::next_float ( const_iterator & iter) const

◆ next_int()

int TPIntegerVector_p2::next_int ( const_iterator & iter) const

◆ next_string()

std::string TPIntegerVector_p2::next_string ( const_iterator & iter) const

◆ next_string_size()

size_t TPIntegerVector_p2::next_string_size ( const const_iterator & iter) const

return the size of the next string/chars

◆ next_TPObjRef()

TPObjRef TPIntegerVector_p2::next_TPObjRef ( const_iterator & iter) const

◆ next_vTPObjRef()

void TPIntegerVector_p2::next_vTPObjRef ( const_iterator & iter,
std::vector< TPObjRef > & vect ) const

◆ operator[]() [1/2]

value_type & TPIntegerVector_p2::operator[] ( size_t idx)

◆ operator[]() [2/2]

const value_type & TPIntegerVector_p2::operator[] ( size_t idx) const

◆ push_back()

void TPIntegerVector_p2::push_back ( const value_type & val)

◆ push_bytes()

void TPIntegerVector_p2::push_bytes ( const void * s,
size_t len )

store blob of a given size (will write out the size)

◆ push_chars()

void TPIntegerVector_p2::push_chars ( const char * const )

store zero-terminated C string (does not write out the size)

◆ push_double()

void TPIntegerVector_p2::push_double ( const double & val)

◆ push_float()

void TPIntegerVector_p2::push_float ( const float & val)

◆ push_int()

void TPIntegerVector_p2::push_int ( const int & val)

◆ push_string()

void TPIntegerVector_p2::push_string ( const std::string & )

store std::string (assuming 8-bit chars). Uses push_chars()

◆ push_TPObjRef()

void TPIntegerVector_p2::push_TPObjRef ( const TPObjRef & val)

◆ push_vTPObjRef()

void TPIntegerVector_p2::push_vTPObjRef ( const std::vector< TPObjRef > & val)

◆ reserve()

void TPIntegerVector_p2::reserve ( size_t new_size)

◆ reserved()

unsigned TPIntegerVector_p2::reserved ( ) const

◆ resize()

void TPIntegerVector_p2::resize ( size_t new_size)

◆ size()

unsigned TPIntegerVector_p2::size ( ) const

◆ size_for() [1/2]

size_t TPIntegerVector_p2::size_for ( const char * )
static

◆ size_for() [2/2]

template<typename T>
size_t TPIntegerVector_p2::size_for ( const T & )
static

tell how much space the object will take in the INT vector, so it can be reserved

◆ size_for_blob()

size_t TPIntegerVector_p2::size_for_blob ( size_t blobsize)
static

◆ size_for_ref()

size_t TPIntegerVector_p2::size_for_ref ( )
static

◆ startPos()

unsigned TPIntegerVector_p2::startPos ( ) const
protected

Member Data Documentation

◆ m_position

unsigned int TPIntegerVector_p2::m_position
protected

Definition at line 105 of file TPIntegerVector_p2.h.

◆ m_storage

TPIntegerVectorStorage_p2* TPIntegerVector_p2::m_storage
protected

Definition at line 104 of file TPIntegerVector_p2.h.


The documentation for this class was generated from the following file: