libpqxx  v4.0-1
C++ library for PostgreSQL
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
pqxx::tablewriter Class Reference

#include <tablewriter.hxx>

Inheritance diagram for pqxx::tablewriter:
Collaboration diagram for pqxx::tablewriter:

Public Types

typedef unsigned size_type
 

Public Member Functions

 tablewriter (transaction_base &, const PGSTD::string &WName, const PGSTD::string &Null=PGSTD::string())
 
template<typename ITER >
 tablewriter (transaction_base &, const PGSTD::string &WName, ITER begincolumns, ITER endcolumns)
 
template<typename ITER >
 tablewriter (transaction_base &T, const PGSTD::string &WName, ITER begincolumns, ITER endcolumns, const PGSTD::string &Null)
 
 ~tablewriter () throw ()
 
const PGSTD::string & classname () const throw ()
 
template<typename ITER >
PGSTD::string columnlist (ITER colbegin, ITER colend)
 
virtual void complete ()
 
PGSTD::string description () const
 
template<typename IT >
PGSTD::string generate (IT Begin, IT End) const
 
template<typename TUPLE >
PGSTD::string generate (const TUPLE &) const
 
template<typename IT >
void insert (IT Begin, IT End)
 
template<typename TUPLE >
void insert (const TUPLE &)
 
const PGSTD::string & name () const throw ()
 
template<typename TUPLE >
tablewriteroperator<< (const TUPLE &)
 
tablewriteroperator<< (tablereader &)
 
template<typename IT >
void push_back (IT Begin, IT End)
 
template<typename TUPLE >
void push_back (const TUPLE &)
 
void reserve (size_type)
 
void write_raw_line (const PGSTD::string &)
 

Protected Member Functions

void base_close ()
 
bool is_finished () const throw ()
 
const PGSTD::string & NullStr () const
 
void reg_pending_error (const PGSTD::string &) throw ()
 
void register_me ()
 
bool registered () const throw ()
 
void unregister_me () throw ()
 

Static Protected Member Functions

template<typename ITER >
static PGSTD::string columnlist (ITER colbegin, ITER colend)
 

Protected Attributes

transaction_basem_Trans
 

Private Member Functions

void setup (transaction_base &, const PGSTD::string &WName, const PGSTD::string &Columns=PGSTD::string())
 
void PQXX_PRIVATE writer_close ()
 

Detailed Description

Deprecated:
Efficiently write data directly to a database table.
Warning
This class does not work reliably with multibyte encodings. Using it with some multi-byte encodings may pose a security risk.

Member Typedef Documentation

typedef unsigned pqxx::tablewriter::size_type

Constructor & Destructor Documentation

pqxx::tablewriter::tablewriter ( transaction_base ,
const PGSTD::string &  WName,
const PGSTD::string &  Null = PGSTD::string() 
)
template<typename ITER >
pqxx::tablewriter::tablewriter ( transaction_base T,
const PGSTD::string &  WName,
ITER  begincolumns,
ITER  endcolumns 
)
inline

References pqxx::tablestream::columnlist(), and setup().

Here is the call graph for this function:

template<typename ITER >
pqxx::tablewriter::tablewriter ( transaction_base T,
const PGSTD::string &  WName,
ITER  begincolumns,
ITER  endcolumns,
const PGSTD::string &  Null 
)
inline

References pqxx::tablestream::columnlist(), and setup().

Here is the call graph for this function:

pqxx::tablewriter::~tablewriter ( ) throw ()

Member Function Documentation

void pqxx::tablestream::base_close ( )
protectedinherited
const PGSTD::string& pqxx::internal::namedclass::classname ( ) const throw ()
inlineinherited
template<typename ITER >
static PGSTD::string pqxx::tablestream::columnlist ( ITER  colbegin,
ITER  colend 
)
staticprotectedinherited

Referenced by pqxx::tablereader::tablereader(), and tablewriter().

Here is the caller graph for this function:

template<typename ITER >
PGSTD::string pqxx::tablestream::columnlist ( ITER  colbegin,
ITER  colend 
)
inlineinherited

References pqxx::separated_list().

Here is the call graph for this function:

virtual void pqxx::tablewriter::complete ( )
virtual

Implements pqxx::tablestream.

PGSTD::string pqxx::internal::namedclass::description ( ) const
inherited
template<typename IT >
PGSTD::string pqxx::tablewriter::generate ( IT  Begin,
IT  End 
) const
inline

References pqxx::tablestream::NullStr(), and pqxx::separated_list().

Referenced by generate(), and insert().

Here is the call graph for this function:

Here is the caller graph for this function:

template<typename TUPLE >
PGSTD::string pqxx::tablewriter::generate ( const TUPLE &  T) const
inline

References generate().

Here is the call graph for this function:

template<typename IT >
void pqxx::tablewriter::insert ( IT  Begin,
IT  End 
)
inline

References generate(), and write_raw_line().

Referenced by insert(), operator<<(), and push_back().

Here is the call graph for this function:

Here is the caller graph for this function:

template<typename TUPLE >
void pqxx::tablewriter::insert ( const TUPLE &  T)
inline

References insert().

Here is the call graph for this function:

bool pqxx::tablestream::is_finished ( ) const throw ()
inlineprotectedinherited
const PGSTD::string& pqxx::internal::namedclass::name ( ) const throw ()
inlineinherited
const PGSTD::string& pqxx::tablestream::NullStr ( ) const
inlineprotectedinherited

Referenced by generate().

Here is the caller graph for this function:

template<typename TUPLE >
tablewriter & pqxx::tablewriter::operator<< ( const TUPLE &  T)
inline

References insert().

Here is the call graph for this function:

tablewriter& pqxx::tablewriter::operator<< ( tablereader )
template<typename IT >
void pqxx::tablewriter::push_back ( IT  Begin,
IT  End 
)
inline

References insert().

Here is the call graph for this function:

template<typename TUPLE >
void pqxx::tablewriter::push_back ( const TUPLE &  T)
inline

References insert().

Here is the call graph for this function:

void pqxx::internal::transactionfocus::reg_pending_error ( const PGSTD::string &  ) throw ()
protectedinherited
void pqxx::internal::transactionfocus::register_me ( )
protectedinherited
bool pqxx::internal::transactionfocus::registered ( ) const throw ()
inlineprotectedinherited
void pqxx::tablewriter::reserve ( size_type  )
inline
void pqxx::tablewriter::setup ( transaction_base ,
const PGSTD::string &  WName,
const PGSTD::string &  Columns = PGSTD::string() 
)
private

Referenced by tablewriter().

Here is the caller graph for this function:

void pqxx::internal::transactionfocus::unregister_me ( ) throw ()
protectedinherited
void pqxx::tablewriter::write_raw_line ( const PGSTD::string &  )

Referenced by insert().

Here is the caller graph for this function:

void PQXX_PRIVATE pqxx::tablewriter::writer_close ( )
private

Member Data Documentation

transaction_base& pqxx::internal::transactionfocus::m_Trans
protectedinherited

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