2012-05-10 12:06:41 +02:00
|
|
|
/******************************************************************************
|
|
|
|
* Icinga 2 *
|
|
|
|
* Copyright (C) 2012 Icinga Development Team (http://www.icinga.org/) *
|
|
|
|
* *
|
|
|
|
* This program is free software; you can redistribute it and/or *
|
|
|
|
* modify it under the terms of the GNU General Public License *
|
|
|
|
* as published by the Free Software Foundation; either version 2 *
|
|
|
|
* of the License, or (at your option) any later version. *
|
|
|
|
* *
|
|
|
|
* This program is distributed in the hope that it will be useful, *
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
|
|
|
* GNU General Public License for more details. *
|
|
|
|
* *
|
|
|
|
* You should have received a copy of the GNU General Public License *
|
|
|
|
* along with this program; if not, write to the Free Software Foundation *
|
|
|
|
* Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
|
|
|
******************************************************************************/
|
|
|
|
|
2012-04-02 08:56:30 +02:00
|
|
|
#ifndef I2BASE_H
|
|
|
|
#define I2BASE_H
|
2012-03-28 13:24:49 +02:00
|
|
|
|
2012-04-03 15:47:32 +02:00
|
|
|
#ifdef _MSC_VER
|
|
|
|
# define HAVE_CXX11
|
2012-04-06 08:56:52 +02:00
|
|
|
# pragma warning(disable:4251)
|
2012-04-19 11:29:36 +02:00
|
|
|
# define _CRT_SECURE_NO_DEPRECATE
|
2012-05-10 13:46:04 +02:00
|
|
|
# define _CRT_SECURE_NO_WARNINGS
|
2012-04-03 15:47:32 +02:00
|
|
|
#else /* _MSC_VER */
|
2012-04-03 13:38:30 +02:00
|
|
|
# include "config.h"
|
|
|
|
#endif /* _MSC_VER */
|
|
|
|
|
2012-04-26 16:45:00 +02:00
|
|
|
#define PLATFORM_WINDOWS 1
|
|
|
|
#define PLATFORM_UNIX 2
|
|
|
|
|
|
|
|
#ifdef _WIN32
|
|
|
|
# define I2_PLATFORM PLATFORM_WINDOWS
|
|
|
|
# include "win32.h"
|
|
|
|
#else
|
|
|
|
# define I2_PLATFORM PLATFORM_UNIX
|
|
|
|
# include "unix.h"
|
|
|
|
#endif
|
|
|
|
|
2012-04-01 09:48:52 +02:00
|
|
|
#include <cstdlib>
|
|
|
|
#include <cstdarg>
|
|
|
|
#include <cstdio>
|
|
|
|
#include <cstring>
|
|
|
|
#include <cassert>
|
|
|
|
#include <cerrno>
|
2012-03-28 13:24:49 +02:00
|
|
|
|
|
|
|
#include <memory>
|
|
|
|
#include <string>
|
2012-04-26 16:45:00 +02:00
|
|
|
#include <sstream>
|
2012-03-28 13:24:49 +02:00
|
|
|
#include <vector>
|
2012-04-19 08:46:41 +02:00
|
|
|
#include <set>
|
2012-03-28 13:24:49 +02:00
|
|
|
#include <iostream>
|
|
|
|
#include <list>
|
|
|
|
#include <typeinfo>
|
2012-04-02 09:03:29 +02:00
|
|
|
#include <map>
|
2012-03-28 13:24:49 +02:00
|
|
|
#include <list>
|
2012-04-02 09:03:29 +02:00
|
|
|
|
2012-04-24 19:58:32 +02:00
|
|
|
#if defined(__APPLE__) && defined(__MACH__)
|
|
|
|
# pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
|
|
|
#endif
|
|
|
|
|
2012-04-24 14:02:15 +02:00
|
|
|
#include <openssl/bio.h>
|
|
|
|
#include <openssl/ssl.h>
|
|
|
|
#include <openssl/err.h>
|
|
|
|
|
2012-04-03 13:38:30 +02:00
|
|
|
#ifdef HAVE_GCC_ABI_DEMANGLE
|
|
|
|
# include <cxxabi.h>
|
|
|
|
#endif /* HAVE_GCC_ABI_DEMANGLE */
|
|
|
|
|
2012-04-02 09:03:29 +02:00
|
|
|
using namespace std;
|
|
|
|
|
2012-04-03 15:47:32 +02:00
|
|
|
#ifdef HAVE_CXX11
|
2012-03-28 13:24:49 +02:00
|
|
|
# include <memory>
|
|
|
|
# include <functional>
|
2012-04-02 09:03:29 +02:00
|
|
|
|
|
|
|
using namespace std::placeholders;
|
2012-03-28 13:24:49 +02:00
|
|
|
#else
|
|
|
|
# include <tr1/memory>
|
|
|
|
# include <tr1/functional>
|
2012-04-04 10:04:38 +02:00
|
|
|
|
2012-04-02 09:03:29 +02:00
|
|
|
using namespace std::tr1;
|
|
|
|
using namespace std::tr1::placeholders;
|
2012-04-04 10:04:38 +02:00
|
|
|
|
|
|
|
# include "cxx11-compat.h"
|
2012-03-28 13:24:49 +02:00
|
|
|
#endif
|
|
|
|
|
2012-04-06 08:56:52 +02:00
|
|
|
#ifdef I2_BASE_BUILD
|
|
|
|
# define I2_BASE_API I2_EXPORT
|
|
|
|
#else /* I2_BASE_BUILD */
|
|
|
|
# define I2_BASE_API I2_IMPORT
|
|
|
|
#endif /* I2_BASE_BUILD */
|
|
|
|
|
2012-03-31 09:09:40 +02:00
|
|
|
#include "mutex.h"
|
|
|
|
#include "condvar.h"
|
2012-03-31 09:36:00 +02:00
|
|
|
#include "thread.h"
|
2012-04-22 16:45:31 +02:00
|
|
|
#include "utility.h"
|
2012-03-28 13:24:49 +02:00
|
|
|
#include "object.h"
|
2012-04-03 13:01:00 +02:00
|
|
|
#include "exception.h"
|
2012-03-28 13:24:49 +02:00
|
|
|
#include "memory.h"
|
|
|
|
#include "delegate.h"
|
|
|
|
#include "event.h"
|
2012-04-18 15:22:25 +02:00
|
|
|
#include "variant.h"
|
|
|
|
#include "dictionary.h"
|
2012-03-28 13:24:49 +02:00
|
|
|
#include "timer.h"
|
|
|
|
#include "fifo.h"
|
|
|
|
#include "socket.h"
|
|
|
|
#include "tcpsocket.h"
|
|
|
|
#include "tcpclient.h"
|
|
|
|
#include "tcpserver.h"
|
2012-04-24 14:02:15 +02:00
|
|
|
#include "tlsclient.h"
|
2012-03-31 15:18:09 +02:00
|
|
|
#include "configobject.h"
|
2012-04-04 10:04:38 +02:00
|
|
|
#include "configcollection.h"
|
2012-03-31 15:18:09 +02:00
|
|
|
#include "confighive.h"
|
2012-03-28 13:24:49 +02:00
|
|
|
#include "application.h"
|
2012-03-31 15:18:09 +02:00
|
|
|
#include "component.h"
|
2012-03-28 13:24:49 +02:00
|
|
|
|
2012-04-02 08:56:30 +02:00
|
|
|
#endif /* I2BASE_H */
|