2016-05-22 21:34:27 +02:00
|
|
|
#ifndef _SQMYSQL_COMMON_HPP_
|
|
|
|
#define _SQMYSQL_COMMON_HPP_
|
|
|
|
|
|
|
|
// ------------------------------------------------------------------------------------------------
|
2016-06-03 20:33:21 +02:00
|
|
|
#include "Base/Utility.hpp"
|
2016-05-22 21:34:27 +02:00
|
|
|
|
2016-06-03 20:33:21 +02:00
|
|
|
// ------------------------------------------------------------------------------------------------
|
|
|
|
#include <mysql.h>
|
2016-05-22 21:34:27 +02:00
|
|
|
|
|
|
|
// ------------------------------------------------------------------------------------------------
|
|
|
|
namespace SqMod {
|
|
|
|
|
|
|
|
/* ------------------------------------------------------------------------------------------------
|
|
|
|
* SOFTWARE INFORMATION
|
|
|
|
*/
|
|
|
|
#define SQMYSQL_NAME "Squirrel MySQL Module"
|
|
|
|
#define SQMYSQL_AUTHOR "Sandu Liviu Catalin (S.L.C)"
|
|
|
|
#define SQMYSQL_COPYRIGHT "Copyright (C) 2016 Sandu Liviu Catalin"
|
|
|
|
#define SQMYSQL_HOST_NAME "SqModMySQLHost"
|
|
|
|
#define SQMYSQL_VERSION 001
|
|
|
|
#define SQMYSQL_VERSION_STR "0.0.1"
|
|
|
|
#define SQMYSQL_VERSION_MAJOR 0
|
|
|
|
#define SQMYSQL_VERSION_MINOR 0
|
|
|
|
#define SQMYSQL_VERSION_PATCH 1
|
|
|
|
|
|
|
|
/* ------------------------------------------------------------------------------------------------
|
2016-06-03 20:33:21 +02:00
|
|
|
* Handle validation.
|
2016-05-22 21:34:27 +02:00
|
|
|
*/
|
2016-06-03 20:33:21 +02:00
|
|
|
#if defined(_DEBUG) || defined(SQMOD_EXCEPTLOC)
|
|
|
|
#define THROW_CURRENT(x, a) x.GetHnd().ThrowCurrent(a, __FILE__, __LINE__)
|
|
|
|
#define THROW_CURRENT_HND(x, a) x.ThrowCurrent(a, __FILE__, __LINE__)
|
|
|
|
#else
|
|
|
|
#define THROW_CURRENT(x, a) x.GetHnd().ThrowCurrent(a)
|
|
|
|
#define THROW_CURRENT_HND(x, a) x.ThrowCurrent(a)
|
|
|
|
#endif // _DEBUG
|
2016-05-22 21:34:27 +02:00
|
|
|
|
|
|
|
/* ------------------------------------------------------------------------------------------------
|
2016-06-03 20:33:21 +02:00
|
|
|
* Forward declarations.
|
2016-05-22 21:34:27 +02:00
|
|
|
*/
|
2016-06-03 20:33:21 +02:00
|
|
|
class Account;
|
|
|
|
class Column;
|
|
|
|
class Connection;
|
|
|
|
class ResultSet;
|
|
|
|
class Statement;
|
|
|
|
class Transaction;
|
2016-05-22 21:34:27 +02:00
|
|
|
|
|
|
|
} // Namespace:: SqMod
|
|
|
|
|
|
|
|
#endif // _SQMYSQL_COMMON_HPP_
|