DCL 3.7.4
Loading...
Searching...
No Matches
IFXConnection.h
Go to the documentation of this file.
1#ifndef __DCL_IFX_CONNECTION_H__
2#define __DCL_IFX_CONNECTION_H__ 20030717
3
4__DCL_BEGIN_NAMESPACE
5
7{
9protected:
10 ByteString __connectionID;
11 ByteString __lastErrorMessage;
12
13 void reset();
14public:
15 void setErrorHandle(
16 SQL::Error _error, long _SQLCODE,
17 const wchar_t* _filename, int _line
18 );
19
20 void setErrorMessage(
21 const ByteString& _message,
22 const wchar_t* _filename, int _line
23 );
24
25 _CONST char* connectionID() const;
26
27public:
28 // interface implementation
29 virtual void destroy();
30 IFXConnection(const wchar_t* _serverTitle);
31 virtual ~IFXConnection();
32 virtual bool __open(const char* _conns, size_t _connlen);
33 virtual bool __close();
34 virtual bool __execute(const char* _sql, size_t _sqllen);
35 virtual bool __startTrans();
36 virtual bool __commitTrans();
37 virtual bool __rollbackTrans();
38 virtual bool __createQueryInstance(SQL::Query** _queryHandleOut);
39 virtual bool __getErrorMessage(char* _buf, size_t* _buflen);
40 virtual bool __getServerInfo(char* _buf, size_t* _buflen);
41};
42
44 const ByteString& _message,
45 const wchar_t* _filename, int _line
46 )
47{
48 Connection::setErrorStatus(SQL::eServerError, _filename, _line);
49 __lastErrorMessage = _message;
50}
51
53{
54 return (_CONST char*)__connectionID.data();
55}
56
57__DCL_END_NAMESPACE
58
59#endif // __DCL_IFX_CONNECTION_H__
#define _CONST
Definition Config.h:325
#define DECLARE_CLASSINFO(class_name)
Definition Object.h:227
virtual ~IFXConnection()
_CONST char * connectionID() const
virtual bool __startTrans()
virtual bool __open(const char *_conns, size_t _connlen)
virtual bool __commitTrans()
virtual bool __rollbackTrans()
void setErrorHandle(SQL::Error _error, long _SQLCODE, const wchar_t *_filename, int _line)
virtual bool __createQueryInstance(SQL::Query **_queryHandleOut)
virtual void destroy()
void setErrorMessage(const ByteString &_message, const wchar_t *_filename, int _line)
virtual bool __close()
virtual bool __execute(const char *_sql, size_t _sqllen)
virtual bool __getServerInfo(char *_buf, size_t *_buflen)
IFXConnection(const wchar_t *_serverTitle)
virtual bool __getErrorMessage(char *_buf, size_t *_buflen)
_PROTECTED const wchar_t * _filename
Definition SQLCore.h:439
_PROTECTED const wchar_t int _line
Definition SQLCore.h:441
Error
Definition SQLCore.h:19
@ eServerError
Definition SQLCore.h:21