00001 /* -*- mode: C++; c-basic-offset: 2; indent-tabs-mode: nil -*- */ 00002 /* 00003 * Main authors: 00004 * Christian Schulte <schulte@gecode.org> 00005 * 00006 * Contributing authors: 00007 * Guido Tack <tack@gecode.org> 00008 * 00009 * Copyright: 00010 * Christian Schulte, 2004 00011 * Guido Tack, 2004 00012 * 00013 * Last modified: 00014 * $Date: 2010-06-02 21:01:00 +0200 (Wed, 02 Jun 2010) $ by $Author: schulte $ 00015 * $Revision: 11008 $ 00016 * 00017 * This file is part of Gecode, the generic constraint 00018 * development environment: 00019 * http://www.gecode.org 00020 * 00021 * Permission is hereby granted, free of charge, to any person obtaining 00022 * a copy of this software and associated documentation files (the 00023 * "Software"), to deal in the Software without restriction, including 00024 * without limitation the rights to use, copy, modify, merge, publish, 00025 * distribute, sublicense, and/or sell copies of the Software, and to 00026 * permit persons to whom the Software is furnished to do so, subject to 00027 * the following conditions: 00028 * 00029 * The above copyright notice and this permission notice shall be 00030 * included in all copies or substantial portions of the Software. 00031 * 00032 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 00033 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 00034 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 00035 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 00036 * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION 00037 * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 00038 * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 00039 * 00040 */ 00041 00042 #ifndef __GECODE_KERNEL_HH__ 00043 #define __GECODE_KERNEL_HH__ 00044 00045 #include <cstddef> 00046 #include <cstdlib> 00047 #include <cstring> 00048 #include <cassert> 00049 00050 #include <gecode/support.hh> 00051 00052 /* 00053 * Configure linking 00054 * 00055 */ 00056 #if !defined(GECODE_STATIC_LIBS) && \ 00057 (defined(__CYGWIN__) || defined(__MINGW32__) || defined(_MSC_VER)) 00058 00059 #ifdef GECODE_BUILD_KERNEL 00060 #define GECODE_KERNEL_EXPORT __declspec( dllexport ) 00061 #else 00062 #define GECODE_KERNEL_EXPORT __declspec( dllimport ) 00063 #endif 00064 00065 #else 00066 00067 #ifdef GECODE_GCC_HAS_CLASS_VISIBILITY 00068 #define GECODE_KERNEL_EXPORT __attribute__ ((visibility("default"))) 00069 #else 00070 #define GECODE_KERNEL_EXPORT 00071 #endif 00072 00073 #endif 00074 00075 // Configure auto-linking 00076 #ifndef GECODE_BUILD_KERNEL 00077 #define GECODE_LIBRARY_NAME "Kernel" 00078 #include <gecode/support/auto-link.hpp> 00079 #endif 00080 00094 /* 00095 * General exceptions and kernel exceptions 00096 * 00097 */ 00098 00099 #include <gecode/kernel/exception.hpp> 00100 00101 00102 00103 /* 00104 * Basic kernel services 00105 * 00106 */ 00107 00108 #include <gecode/kernel/memory-config.hpp> 00109 #include <gecode/kernel/memory-manager.hpp> 00110 00111 00112 /* 00113 * Macros for checking failure 00114 * 00115 */ 00116 00117 #include <gecode/kernel/macros.hpp> 00118 00119 00120 /* 00121 * Gecode kernel 00122 * 00123 */ 00124 00125 #include <gecode/kernel/global-prop-info.hpp> 00126 #include <gecode/kernel/core.hpp> 00127 #include <gecode/kernel/modevent.hpp> 00128 00129 00130 /* 00131 * Region memory management 00132 * 00133 */ 00134 00135 #include <gecode/kernel/region.hpp> 00136 00137 00138 /* 00139 * Variables and testing for shared variables 00140 * 00141 */ 00142 00143 #include <gecode/kernel/var.hpp> 00144 00145 00146 /* 00147 * Views 00148 * 00149 */ 00150 00151 #include <gecode/kernel/view.hpp> 00152 00153 00154 /* 00155 * Arrays 00156 * 00157 */ 00158 00159 #include <gecode/kernel/array.hpp> 00160 #include <gecode/kernel/shared-array.hpp> 00161 00162 00163 /* 00164 * Common propagator and branching patterns 00165 * 00166 */ 00167 00168 #include <gecode/kernel/propagator.hpp> 00169 #include <gecode/kernel/advisor.hpp> 00170 #include <gecode/kernel/branch.hpp> 00171 #include <gecode/kernel/brancher.hpp> 00172 #include <gecode/kernel/brancher-view.hpp> 00173 #include <gecode/kernel/brancher-tiebreak.hpp> 00174 #include <gecode/kernel/brancher-val.hpp> 00175 00176 00177 /* 00178 * Automatically generated variable implementations 00179 * 00180 */ 00181 00182 #include <gecode/kernel/var-imp.hpp> 00183 00184 /* 00185 * Allocator support 00186 * 00187 */ 00188 00189 #include <gecode/kernel/allocators.hpp> 00190 00191 #endif 00192 00193 // STATISTICS: kernel-other