nodejs-db-informix  master
nodejs bindings for Informix
 All Classes Functions Pages
Public Member Functions | Protected Attributes | Private Member Functions | Private Attributes | List of all members
nodejs_db_informix::Connection Class Reference
Inheritance diagram for nodejs_db_informix::Connection:
Inheritance graph
[legend]
Collaboration diagram for nodejs_db_informix::Connection:
Collaboration graph
[legend]

Public Member Functions

 Connection (std::string, std::string, std::string, std::string, uint32_t=0)
 
void setCharset (const std::string &charset) throw ()
 
void setCompress (const bool compress) throw ()
 
void setInitCommand (const std::string &initCommand) throw ()
 
void setReadTimeout (const uint32_t readTimeout) throw ()
 
void setReconnect (const bool reconnect) throw ()
 
void setSocket (const std::string &socket) throw ()
 
void setSslVerifyServer (const bool sslVerifyServer) throw ()
 
void setTimeout (const uint32_t timeout) throw ()
 
void setWriteTimeout (const uint32_t writeTimeout) throw ()
 
bool isAlive (bool=false) throw ()
 
void open () throw (nodejs_db::Exception&)
 
void close ()
 
std::string escape (const std::string &string) const throw (nodejs_db::Exception&)
 
std::string version () const
 
nodejs_db::Resultquery (const std::string &query) const throw (nodejs_db::Exception&)
 
nodejs_db::Resultquery_x (const std::string &query) const throw (nodejs_db::Exception&)
 
- Public Member Functions inherited from nodejs_db::Connection
virtual std::string getHostname () const
 
virtual void setHostname (const std::string &hostname)
 
virtual std::string getUser () const
 
virtual void setUser (const std::string &user)
 
virtual std::string getPassword () const
 
virtual void setPassword (const std::string &password)
 
virtual std::string getDatabase () const
 
virtual void setDatabase (const std::string &database)
 
virtual uint32_t getPort () const
 
virtual void setPort (uint32_t port)
 
virtual std::string escapeName (const std::string &string) const throw (Exception&)
 
virtual void lock ()
 
virtual void unlock ()
 

Protected Attributes

std::string charset
 
bool compress
 
std::string initCommand
 
uint32_t readTimeout
 
bool reconnect
 
std::string socket
 
bool sslVerifyServer
 
uint32_t timeout
 
uint32_t writeTimeout
 
- Protected Attributes inherited from nodejs_db::Connection
std::string hostname
 
std::string user
 
std::string password
 
std::string database
 
uint32_t port
 
bool alive
 
char quoteName
 
pthread_mutex_t * connectionLock
 

Private Member Functions

bool _prepareITDBInfo (ITDBInfo &)
 

Private Attributes

ITConnection * connection
 

Additional Inherited Members

- Public Attributes inherited from nodejs_db::Connection
const char quoteString
 
- Static Public Attributes inherited from nodejs_db::Connection
static pthread_mutex_t staticConnectionLock = PTHREAD_MUTEX_INITIALIZER
 

Detailed Description

Definition at line 11 of file connection.h.

Member Function Documentation

bool nodejs_db_informix::Connection::_prepareITDBInfo ( ITDBInfo &  dbInfo)
private

XXX: do we really need to pass dbInfo?

Definition at line 111 of file connection.cxx.

std::string nodejs_db_informix::Connection::escape ( const std::string &  s) const throw (nodejs_db::Exception&)
virtual

Escape single quotes, line feed and carriage return

Implements nodejs_db::Connection.

Definition at line 219 of file connection.cxx.

nodejs_db::Result * nodejs_db_informix::Connection::query ( const std::string &  query) const throw (nodejs_db::Exception&)
virtual

execute select query

Implements nodejs_db::Connection.

Definition at line 324 of file connection.cxx.

nodejs_db::Result * nodejs_db_informix::Connection::query_x ( const std::string &  query) const throw (nodejs_db::Exception&)
virtual

For insert, update, delete etc. we need a different ITQuery object Therefore, we need a new function

Implements nodejs_db::Connection.

Definition at line 378 of file connection.cxx.

std::string nodejs_db_informix::Connection::version ( ) const
virtual

Version string

Implements nodejs_db::Connection.

Definition at line 259 of file connection.cxx.


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