# Coin_C_defines.h

Go to the documentation of this file.

    00001 /* $Id: Coin_C_defines.h 1690 2014-03-13 17:45:21Z mlubin $ */
    00002 /*
    00003   Copyright (C) 2002, 2003 International Business Machines Corporation
    00004   and others.  All Rights Reserved.
    00005
    00006   This code is licensed under the terms of the Eclipse Public License (EPL).
    00007 */
    00008 #ifndef CoinCDefine_H
    00009 #define CoinCDefine_H
    00010
    00015 #if defined (CLP_EXTERN_C)
    00016 #define COIN_EXTERN_C
    00017 #define COIN_NO_SBB
    00018 #define COIN_NO_CBC
    00019 #endif
    00020 #if defined (SBB_EXTERN_C)
    00021 #define COIN_EXTERN_C
    00022 #define COIN_NO_CLP
    00023 #endif
    00024 #if defined (CBC_EXTERN_C)
    00025 #define COIN_EXTERN_C
    00026 #define COIN_NO_CLP
    00027 #endif
    00028 /* We need to allow for Microsoft */
    00029 #ifndef COINLIBAPI
    00030
    00031 #if defined(CBCCINTERFACEDLL_EXPORTS) || defined(CLPMSDLL)
    00032 #if defined (COIN_EXTERN_C)
    00033 #   define COINLIBAPI __declspec(dllexport)
    00034 #else
    00035 #   define COINLIBAPI __declspec(dllexport)
    00036 #endif
    00037 #   define COINLINKAGE  __stdcall
    00038 #   define COINLINKAGE_CB  __cdecl
    00039 #else
    00040 #if defined (COIN_EXTERN_C)
    00041 #   define COINLIBAPI extern "C"
    00042 #else
    00043 #   define COINLIBAPI
    00044 #endif
    00045 #   define COINLINKAGE
    00046 #   define COINLINKAGE_CB
    00047 #endif
    00048
    00049 #endif
    00050
    00051 #if defined (CLP_EXTERN_C)
    00052 /* Real typedef for structure */
    00053 class CMessageHandler;
    00054 typedef struct {
    00055   ClpSimplex * model_;
    00056   CMessageHandler * handler_;
    00057 } Clp_Simplex;
    00058 #else
    00059 typedef void Clp_Simplex;
    00060 #endif
    00061
    00062 #ifndef COIN_NO_CLP
    00063
    00065 typedef  void (COINLINKAGE_CB *clp_callback) (Clp_Simplex * model,int  msgno, int ndouble,
    00066                             const double * dvec, int nint, const int * ivec,
    00067                             int nchar, char ** cvec);
    00068 #endif
    00069
    00070 #if defined (SBB_EXTERN_C)
    00071 /* Real typedef for structure */
    00072 class Sbb_MessageHandler;
    00073 typedef struct {
    00074   OsiClpSolverInterface * solver_;
    00075   SbbModel              * model_;
    00076   Sbb_MessageHandler    * handler_;
    00077   char                  * information_;
    00078 } Sbb_Model;
    00079 #else
    00080 typedef void Sbb_Model;
    00081 #endif
    00082 #if defined (CBC_EXTERN_C)
    00083 /* Real typedef for structure */
    00084 class Cbc_MessageHandler;
    00085 typedef struct {
    00086   OsiClpSolverInterface * solver_;
    00087   CbcModel              * model_;
    00088   Cbc_MessageHandler    * handler_;
    00089   std::vector<std::string> cmdargs_;
    00090 } Cbc_Model;
    00091 #else
    00092 typedef void Cbc_Model;
    00093 #endif
    00094 #ifndef COIN_NO_SBB
    00095
    00097 typedef  void (COINLINKAGE_CB *sbb_callback) (Sbb_Model * model,int  msgno, int ndouble,
    00098                             const double * dvec, int nint, const int * ivec,
    00099                             int nchar, char ** cvec);
    00100 typedef  void (COINLINKAGE_CB *cbc_callback) (Cbc_Model * model,int  msgno, int ndouble,
    00101                             const double * dvec, int nint, const int * ivec,
    00102                             int nchar, char ** cvec);
    00103 #endif
    00104 #if COIN_BIG_INDEX==0
    00105 typedef int CoinBigIndex;
    00106 #elif COIN_BIG_INDEX==1
    00107 typedef long CoinBigIndex;
    00108 #else
    00109 typedef long long CoinBigIndex;
    00110 #endif
    00111 /* just in case used somewhere */
    00112 #undef COIN_NO_CLP
    00113 #undef COIN_NO_SBB
    00114 #undef COIN_NO_CBC
    00115 #endif

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines