Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members | Related Pages

pqxx::binarystring Class Reference

Reveals "unescaped" version of PostgreSQL bytea string. More...

Inheritance diagram for pqxx::binarystring:

pqxx::PQAlloc< unsigned char > List of all members.

Public Types

typedef size_t size_type

Public Member Functions

 binarystring (const result::field &F)
 Read and unescape bytea field.

size_type size () const throw ()
 Size of unescaped buffer, including terminating zero.

const unsigned char * bytes () const throw ()
 Unescaped field contents.


Detailed Description

Reveals "unescaped" version of PostgreSQL bytea string.

This class represents a postgres-internal buffer containing the original, binary string represented by a field of type bytea. The raw value returned by such a field contains escape sequences for certain characters, which are filtered out by binarystring. The binarystring retains its value even if the result it was obtained from is destroyed, but it cannot be copied or assigned.


Member Typedef Documentation

typedef size_t pqxx::binarystring::size_type
 


Constructor & Destructor Documentation

pqxx::binarystring::binarystring const result::field F  )  [explicit]
 

Read and unescape bytea field.

The field will be zero-terminated, even if the original bytea field isn't.

Parameters:
F the field to read; must be a bytea field


Member Function Documentation

const unsigned char* pqxx::binarystring::bytes  )  const throw ()
 

Unescaped field contents.

size_type pqxx::binarystring::size  )  const throw ()
 

Size of unescaped buffer, including terminating zero.


The documentation for this class was generated from the following file:
Generated on Tue Jul 15 13:03:57 2003 for libpqxx by doxygen 1.3.2