#include <binarystring.hxx>
Public Types | |
typedef content_type | char_type |
typedef const_pointer | const_iterator |
typedef const value_type * | const_pointer |
typedef const value_type & | const_reference |
typedef long | difference_type |
typedef size_t | size_type |
typedef PGSTD::char_traits < char_type >::char_type | value_type |
Public Member Functions | |
binarystring (const field &) | |
Read and unescape bytea field. More... | |
binarystring (const PGSTD::string &) | |
Copy binary data from std::string. More... | |
binarystring (const void *, size_t) | |
Copy binary data of given length straight out of memory. More... | |
const_reference | at (size_type) const |
Index contained string, checking for valid index. More... | |
const_reference | back () const throw () |
const_iterator | begin () const throw () |
const value_type * | data () const throw () |
Unescaped field contents. More... | |
bool | empty () const throw () |
const_iterator | end () const throw () |
const_reference | front () const throw () |
const char * | get () const throw () |
Raw character buffer (no terminating zero is added) More... | |
size_type | length () const throw () |
Size of converted string in bytes. More... | |
bool | operator!= (const binarystring &rhs) const throw () |
bool PQXX_PURE | operator== (const binarystring &) const throw () |
const_reference | operator[] (size_type i) const throw () |
size_type | size () const throw () |
Size of converted string in bytes. More... | |
PGSTD::string | str () const |
Read as regular C++ string (may include null characters) More... | |
void | swap (binarystring &) |
Swap contents with other binarystring. More... | |
Private Types | |
typedef const unsigned char | content_type |
typedef internal::PQAlloc < value_type, pqxx::internal::freemallocmem_templated < const unsigned char > > | super |
Private Member Functions | |
operator bool () const throw () | |
Is this pointer non-null? More... | |
bool | operator! () const throw () |
Is this pointer null? More... | |
const unsigned char & | operator* () const throw (PGSTD::logic_error) |
Dereference pointer. More... | |
const unsigned char * | operator-> () const throw (PGSTD::logic_error) |
Dereference pointer. More... | |
void | reset () throw () |
void | swap (PQAlloc &rhs) throw () |
Private Attributes | |
size_type | m_size |
Related Functions | |
(Note that these are not member functions.) | |
PGSTD::string PQXX_LIBEXPORT | escape_binary (const PGSTD::string &bin) |
Escape binary string for inclusion in SQL. More... | |
PGSTD::string PQXX_LIBEXPORT | escape_binary (const char bin[]) |
Escape binary string for inclusion in SQL. More... | |
PGSTD::string PQXX_LIBEXPORT | escape_binary (const char bin[], size_t len) |
Escape binary string for inclusion in SQL. More... | |
PGSTD::string PQXX_LIBEXPORT | escape_binary (const unsigned char bin[]) |
Escape binary string for inclusion in SQL. More... | |
PGSTD::string PQXX_LIBEXPORT | escape_binary (const unsigned char bin[], size_t len) |
Escape binary string for inclusion in SQL. More... | |
typedef const value_type* pqxx::binarystring::const_pointer |
typedef const value_type& pqxx::binarystring::const_reference |
|
inherited |
typedef long pqxx::binarystring::difference_type |
typedef size_t pqxx::binarystring::size_type |
|
private |
|
explicit |
Read and unescape bytea field.
The field will be zero-terminated, even if the original bytea field isn't.
F | the field to read; must be a bytea field |
|
explicit |
Copy binary data from std::string.
pqxx::binarystring::binarystring | ( | const void * | , |
size_t | |||
) |
Copy binary data of given length straight out of memory.
const_reference pqxx::binarystring::at | ( | size_type | ) | const |
Index contained string, checking for valid index.
|
inline |
|
inline |
|
inline |
Unescaped field contents.
|
inline |
|
inline |
|
inline |
|
inline |
Raw character buffer (no terminating zero is added)
|
inline |
Size of converted string in bytes.
|
inlineinherited |
Is this pointer non-null?
|
inlineinherited |
Is this pointer null?
|
inline |
|
inlineinherited |
Dereference pointer.
Throws a logic_error if the pointer is null.
|
inlineinherited |
Dereference pointer.
Throws a logic_error if the pointer is null.
bool PQXX_PURE pqxx::binarystring::operator== | ( | const binarystring & | ) | const throw () |
|
inline |
|
inlineinherited |
|
inline |
Size of converted string in bytes.
PGSTD::string pqxx::binarystring::str | ( | ) | const |
Read as regular C++ string (may include null characters)
Referenced by pqxx::internal::statement_parameters::add_binary_param().
void pqxx::binarystring::swap | ( | binarystring & | ) |
Swap contents with other binarystring.
|
inlineinherited |
|
private |