source/ariba/utility/serialization/DataUtilities.hpp File Reference

#include "../internal/Utilities.hpp"
#include <boost/cstdint.hpp>
#include <memory>
#include <string>

Include dependency graph for DataUtilities.hpp:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

template<typename X>
static finline X bitblk (size_t index, size_t length, bool value, if_uint(X))
template<typename X, bool value>
static finline X bitblk (size_t index, size_t length, if_uint(X))
template<typename X, bool value>
static finline X bitblk (size_t length, if_uint(X))
template<typename X, typename Y>
static finline Y bitcpy (X src, size_t srcIdx, Y dst, size_t dstIdx, size_t len=sizeof(X)*8, bool srcInvert=false, bool dstInvert=false, if_uint(X), if_uint(Y))
template<typename X>
static finline void bitcpy (X *src, size_t srcIdx, X *dst, size_t dstIdx, size_t len)
template<typename X, typename Y>
static finline void bitcpy (X *src, size_t srcIdx, Y &dst, size_t dstIdx, size_t len=sizeof(Y)*8, if_uint(Y), if_uint(X))
template<typename X>
static finline void bitcpy (X src, size_t srcIdx, X *dst, size_t dstIdx, size_t len=sizeof(X)*8, bool srcInvert=false, if_uint(X))
template<typename Y, typename X>
static finline void bitcpy (Y src, size_t srcIdx, X *dst, size_t dstIdx, size_t len=sizeof(Y)*8, bool srcInvert=false, if_uint(X), if_uint(Y))
template<typename T, typename X>
static finline T bitget (X *src, size_t idx, size_t len=sizeof(T)*8, if_uint(X), if_uint(T))
template<typename T, typename X>
static finline T bitget (X src, size_t idx, size_t len=sizeof(T)*8, if_uint(X), if_uint(T))
template<typename X>
static finline bool bitget (X *src, size_t index, if_uint(X))
template<typename X>
static finline bool bitget (X src, size_t index, if_uint(X))
template<typename T, typename X>
static finline void bitset (T src, X *dst, size_t index, if_uint(X), if_uint(T))
template<typename X>
static finline void bitset (bool src, X *dst, size_t index, if_uint(X))
template<typename X>
static finline X bitset (bool src, X dst, size_t index, if_uint(X))
template<typename X>
static finline X bitrev (X src, if_uint(X))
template<typename X>
static finline void bitrev (X *src, size_t len, if_uint(X))
template<typename X>
static finline X switch_endian (X src, if_uint(X))
template<typename X>
static finline std::string bitstr (X src, int log2base=4, if_uint(X))
template<typename X>
static finline std::string bitstr (X *src, size_t len, int log2base=4, bool dot=false, if_uint(X))


Function Documentation

template<typename X, bool value>
static finline X bitblk ( size_t  length,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 95 of file DataUtilities.hpp.

template<typename X, bool value>
static finline X bitblk ( size_t  index,
size_t  length,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 87 of file DataUtilities.hpp.

template<typename X>
static finline X bitblk ( size_t  index,
size_t  length,
bool  value,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 77 of file DataUtilities.hpp.

template<typename Y, typename X>
static finline void bitcpy ( src,
size_t  srcIdx,
X *  dst,
size_t  dstIdx,
size_t  len = sizeof(Y) * 8,
bool  srcInvert = false,
if_uint(X)  ,
if_uint(Y)   
) [inline, static]

TODO: Doc

Definition at line 268 of file DataUtilities.hpp.

References bitcpy().

template<typename X>
static finline void bitcpy ( src,
size_t  srcIdx,
X *  dst,
size_t  dstIdx,
size_t  len = sizeof(X) * 8,
bool  srcInvert = false,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 230 of file DataUtilities.hpp.

References bitcpy().

template<typename X, typename Y>
static finline void bitcpy ( X *  src,
size_t  srcIdx,
Y &  dst,
size_t  dstIdx,
size_t  len = sizeof(Y) * 8,
if_uint(Y)  ,
if_uint(X)   
) [inline, static]

array -> integral

Definition at line 189 of file DataUtilities.hpp.

template<typename X>
static finline void bitcpy ( X *  src,
size_t  srcIdx,
X *  dst,
size_t  dstIdx,
size_t  len 
) [inline, static]

This method copies bits from an array to another of the same integral type.

Definition at line 119 of file DataUtilities.hpp.

References bitcpy().

template<typename X, typename Y>
static finline Y bitcpy ( src,
size_t  srcIdx,
dst,
size_t  dstIdx,
size_t  len = sizeof(X) * 8,
bool  srcInvert = false,
bool  dstInvert = false,
if_uint(X)  ,
if_uint(Y)   
) [inline, static]

template<typename X>
static finline bool bitget ( src,
size_t  index,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 327 of file DataUtilities.hpp.

References bitcpy().

template<typename X>
static finline bool bitget ( X *  src,
size_t  index,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 317 of file DataUtilities.hpp.

References bitcpy().

template<typename T, typename X>
static finline T bitget ( src,
size_t  idx,
size_t  len = sizeof(T) * 8,
if_uint(X)  ,
if_uint(T)   
) [inline, static]

TODO: Doc

Definition at line 307 of file DataUtilities.hpp.

References bitcpy().

template<typename T, typename X>
static finline T bitget ( X *  src,
size_t  idx,
size_t  len = sizeof(T) * 8,
if_uint(X)  ,
if_uint(T)   
) [inline, static]

TODO: Doc

Definition at line 297 of file DataUtilities.hpp.

References bitcpy().

Referenced by bitrev(), and DataTpl< T, DataModel >::DataManipulator::get().

template<typename X>
static finline void bitrev ( X *  src,
size_t  len,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 373 of file DataUtilities.hpp.

References bitget(), and bitset().

template<typename X>
static finline X bitrev ( src,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 361 of file DataUtilities.hpp.

References bitget(), and bitset().

template<typename X>
static finline X bitset ( bool  src,
dst,
size_t  index,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 353 of file DataUtilities.hpp.

References bitcpy().

template<typename X>
static finline void bitset ( bool  src,
X *  dst,
size_t  index,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 345 of file DataUtilities.hpp.

References bitcpy().

template<typename T, typename X>
static finline void bitset ( src,
X *  dst,
size_t  index,
if_uint(X)  ,
if_uint(T)   
) [inline, static]

TODO: Doc

Definition at line 337 of file DataUtilities.hpp.

References bitcpy().

Referenced by bitrev(), and DataTpl< T, DataModel >::DataManipulator::operator=().

template<typename X>
static finline std::string bitstr ( X *  src,
size_t  len,
int  log2base = 4,
bool  dot = false,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 415 of file DataUtilities.hpp.

References bitstr().

template<typename X>
static finline std::string bitstr ( src,
int  log2base = 4,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 401 of file DataUtilities.hpp.

Referenced by bitstr(), and operator<<().

template<typename X>
static finline X switch_endian ( src,
if_uint(X)   
) [inline, static]

TODO: Doc

Definition at line 386 of file DataUtilities.hpp.


Generated on Wed May 27 18:23:22 2009 for Ariba by  doxygen 1.5.6