|
DP3
|
Classes | |
| class | BlobAipsIO |
| A Blob buffer for Aips++ ByteIO. More... | |
| class | BlobHeader |
| Standard header for a blob. More... | |
| class | BlobIBuffer |
| Abstract base class for input buffer for a blob. More... | |
| class | BlobIBufStream |
| Input buffer for a blob using an istream. More... | |
| class | BlobIStream |
| Input stream for a blob. More... | |
| class | BlobOBuffer |
| Abstract base class for output buffer for a blob. More... | |
| class | BlobOBufStream |
| Output buffer for a blob using an ostream. More... | |
| class | BlobOStream |
| Output stream for a blob. More... | |
| class | BlobStreamable |
| Interface for classes that can be streamed using blobs. More... | |
Typedefs | |
| typedef std::runtime_error | BlobException |
| Blob Exception class. More... | |
Functions | |
| void | convertArrayHeader (common::DataFormat, char *header, bool useBlobHeader) |
| Convert the array header data. More... | |
| template<typename T > | |
| BlobIStream & | getBlobArray (BlobIStream &bs, T *&arr, std::vector< uint64_t > &shape, bool fortranOrder) |
| template<typename T > | |
| void | getBlobArrayData (BlobIStream &bs, T *data, uint64_t nr) |
| Helper function to get an array of data. More... | |
| uint64_t | getBlobArrayShape (BlobIStream &bs, uint64_t *shape, unsigned int ndim, bool swapAxes, unsigned int nalign) |
| unsigned int | getBlobArrayStart (BlobIStream &bs, bool &fortranOrder, uint16_t &ndim) |
| template<typename T > | |
| uint64_t | getSpaceBlobArray (BlobIStream &bs, bool useBlobHeader, std::vector< uint64_t > &shape, bool fortranOrder) |
| template<typename T > | |
| void | putBlobArrayData (BlobOStream &bs, const T *data, uint64_t nr) |
| uint64_t | putBlobArrayHeader (BlobOStream &bs, bool useBlobHeader, const std::string &headerName, const uint64_t *shape, uint16_t ndim, bool fortranOrder, unsigned int alignment) |
General function to write a data array | |
Usually it is used by the other functions, but it can be used on its own to write, say, a C-style array. A 1-dim C-style array can be written with putBlobVector. | |
| template<typename T > | |
| BlobOStream & | putBlobArray (BlobOStream &bs, const T *data, const uint64_t *shape, uint16_t ndim, bool fortranOrder) |
| template<typename T > | |
| BlobOStream & | putBlobVector (BlobOStream &bs, const T *vec, uint64_t size) |
| Put a C-style vector of values as an array. More... | |
Reserve space for an array with the given shape | |
The axes ordering (Fortran or C-style) has to be given. It returns the offset of the array in the blob. It is useful for allocating a static blob in a dynamic way. It is only possible if the underlying buffer is seekable. It is meant for use with the BlobOBufString buffer. The function getPointer in that class can be used to turn the position into a pointer. The data will be aligned on the given alignment which defaults to sizeof(T) bytes with a maximum of 8. | |
| template<typename T > | |
| uint64_t | setSpaceBlobArray1 (BlobOStream &bs, bool useBlobHeader, uint64_t size0, unsigned int alignment) |
| Reserve space for a 1-dim array of the given size. More... | |
| template<typename T > | |
| uint64_t | setSpaceBlobArray2 (BlobOStream &bs, bool useBlobHeader, uint64_t size0, uint64_t size1, bool fortranOrder, unsigned int alignment=0) |
| template<typename T > | |
| uint64_t | setSpaceBlobArray3 (BlobOStream &bs, bool useBlobHeader, uint64_t size0, uint64_t size1, uint64_t size2, bool fortranOrder, unsigned int alignment=0) |
| template<typename T > | |
| uint64_t | setSpaceBlobArray4 (BlobOStream &bs, bool useBlobHeader, uint64_t size0, uint64_t size1, uint64_t size2, uint64_t size3, bool fortranOrder, unsigned int alignment=0) |
| template<typename T > | |
| uint64_t | setSpaceBlobArray (BlobOStream &bs, bool useBlobHeader, const std::vector< uint64_t > &shape, bool fortranOrder, unsigned int alignment=0) |
| template<typename T > | |
| uint64_t | setSpaceBlobArray (BlobOStream &bs, bool useBlobHeader, const uint64_t *shape, uint16_t ndim, bool fortranOrder, unsigned int alignment=0) |
Write a vector of objects | |
| BlobOStream & | operator<< (BlobOStream &, const std::vector< bool > &) |
| template<typename T > | |
| BlobOStream & | operator<< (BlobOStream &bs, const std::vector< T > &vec) |
| Put a vector object as an array. More... | |
Read back a vector of objects | |
The dimensionality found in the stream has to be 1. The vector is resized as needed. | |
| BlobIStream & | operator>> (BlobIStream &, std::vector< bool > &) |
| template<typename T > | |
| BlobIStream & | operator>> (BlobIStream &, std::vector< T > &) |
Write a map. | |
Blob handling for STL sequences Define functions to write a map into a blob and to read it back. The map is preceeded by the header 'map<T,U>', where T and U are the type names as defined in TypeNames.h. Type names are only defined for the basic types. Other types are set to 'unknown'. | |
| template<typename T , typename U > | |
| BlobOStream & | operator<< (BlobOStream &, const std::map< T, U > &) |
Read back a map. | |
| template<typename T , typename U > | |
| BlobIStream & | operator>> (BlobIStream &, std::map< T, U > &) |
Write a sequence. | |
Define helper functions to write any STL sequence into a blob and to read it back. The sequence is preceeded by the header 'array<T>', where T is the type name of Seq::value_type as defined in TypeNames.h. Type names are only defined for the basic types. Other types are set to 'unknown'. All sequences are written in the same way (as 1-dim arrays). It means that they can be read back using any other sequence type. | |
| template<typename Seq > | |
| void | sequenceToBlob (BlobOStream &, const Seq &) |
Read back a sequence. | |
| template<typename Seq > | |
| void | sequenceFromBlob (BlobOStream &, Seq &) |
| template<typename T > | |
| void | sequenceFromBlob (BlobOStream &, std::set< T > &) |
| Specialize for a set. More... | |
Write a list. | |
Define helper functions to write an STL sequence into a blob and to read it back. The sequence is preceeded by the header 'array<T>', where T is the type name of T as defined in TypeNames.h. Type names are only defined for the basic types. Other types are set to 'unknown'. All sequences are written in the same way (as 1-dim arrays). It means that they can be read back in any other sequence type (including AIPS++ and Blitz arrays).
| |
| template<typename T > | |
| BlobOStream & | operator<< (BlobOStream &bs, const std::list< T > &seq) |
Read back a list. | |
| template<typename T > | |
| BlobIStream & | operator>> (BlobIStream &bs, std::list< T > &seq) |
Write a set. | |
| template<typename T > | |
| BlobOStream & | operator<< (BlobOStream &bs, const std::set< T > &seq) |
Read back a set. | |
| template<typename T > | |
| BlobIStream & | operator>> (BlobIStream &bs, std::set< T > &seq) |
Write a queue. | |
| template<typename T > | |
| BlobOStream & | operator<< (BlobOStream &bs, const std::queue< T > &seq) |
Read back a queue. | |
| template<typename T > | |
| BlobIStream & | operator>> (BlobIStream &bs, std::queue< T > &seq) |
Write a deque. | |
| template<typename T > | |
| BlobOStream & | operator<< (BlobOStream &bs, const std::deque< T > &seq) |
Read back a deque. | |
| template<typename T > | |
| BlobIStream & | operator>> (BlobIStream &bs, std::deque< T > &seq) |
| typedef std::runtime_error dp3::blob::BlobException |
Blob Exception class.
| BlobOStream& dp3::blob::operator<< | ( | BlobOStream & | , |
| const std::map< T, U > & | |||
| ) |
| BlobOStream& dp3::blob::operator<< | ( | BlobOStream & | bs, |
| const std::deque< T > & | seq | ||
| ) |
| BlobOStream& dp3::blob::operator<< | ( | BlobOStream & | bs, |
| const std::list< T > & | seq | ||
| ) |
| BlobOStream& dp3::blob::operator<< | ( | BlobOStream & | bs, |
| const std::queue< T > & | seq | ||
| ) |
| BlobOStream& dp3::blob::operator<< | ( | BlobOStream & | bs, |
| const std::set< T > & | seq | ||
| ) |
| BlobIStream& dp3::blob::operator>> | ( | BlobIStream & | , |
| std::map< T, U > & | |||
| ) |
| BlobIStream& dp3::blob::operator>> | ( | BlobIStream & | bs, |
| std::deque< T > & | seq | ||
| ) |
| BlobIStream& dp3::blob::operator>> | ( | BlobIStream & | bs, |
| std::list< T > & | seq | ||
| ) |
| BlobIStream& dp3::blob::operator>> | ( | BlobIStream & | bs, |
| std::queue< T > & | seq | ||
| ) |
| BlobIStream& dp3::blob::operator>> | ( | BlobIStream & | bs, |
| std::set< T > & | seq | ||
| ) |
| void dp3::blob::sequenceFromBlob | ( | BlobOStream & | , |
| Seq & | |||
| ) |
| void dp3::blob::sequenceFromBlob | ( | BlobOStream & | , |
| std::set< T > & | |||
| ) |
Specialize for a set.
| void dp3::blob::sequenceToBlob | ( | BlobOStream & | , |
| const Seq & | |||
| ) |