88#endif
99
1010#ifdef _WIN32
11+ #if defined(__MINGW64__ )
12+ #define COPT_INT64 long long
13+ #else
1114#define COPT_INT64 __int64
15+ #endif
1216#elif defined(__LP64__ ) || defined(_LP64 ) || defined(__ILP64__ ) || defined(_ILP64 )
1317#define COPT_INT64 long
1418#else
@@ -20,8 +24,8 @@ extern "C" {
2024#endif
2125
2226#define COPT_VERSION_MAJOR 7
23- #define COPT_VERSION_MINOR 1
24- #define COPT_VERSION_TECHNICAL 4
27+ #define COPT_VERSION_MINOR 2
28+ #define COPT_VERSION_TECHNICAL 2
2529
2630
2731/*
@@ -55,6 +59,11 @@ extern "C" {
5559#define COPT_SOS_TYPE1 1
5660#define COPT_SOS_TYPE2 2
5761
62+ /* Indicator types */
63+ #define COPT_INDICATOR_IF 1
64+ #define COPT_INDICATOR_ONLYIF 2
65+ #define COPT_INDICATOR_IFANDONLYIF 3
66+
5867/* Cone types */
5968#define COPT_CONE_QUAD 1
6069#define COPT_CONE_RQUAD 2
@@ -250,6 +259,9 @@ extern "C" {
250259#define COPT_DBLINFO_RELAXVALUE "RelaxValue"
251260
252261/* COPT client config keywords */
262+ #define COPT_CLIENT_CAFILE "CaFile"
263+ #define COPT_CLIENT_CERTFILE "CertFile"
264+ #define COPT_CLIENT_CERTKEYFILE "CertKeyFile"
253265#define COPT_CLIENT_CLUSTER "Cluster"
254266#define COPT_CLIENT_FLOATING "Floating"
255267#define COPT_CLIENT_PASSWORD "PassWord"
@@ -285,6 +297,7 @@ int COPT_CALL COPT_GetLicenseMsg(copt_env *env, char *buff, int buffSize);
285297
286298int COPT_CALL COPT_CreateProb (copt_env * env , copt_prob * * p_prob );
287299int COPT_CALL COPT_CreateCopy (copt_prob * src_prob , copt_prob * * p_dst_prob );
300+ int COPT_CALL COPT_ClearProb (copt_prob * prob );
288301int COPT_CALL COPT_DeleteProb (copt_prob * * p_prob );
289302
290303int COPT_CALL COPT_LoadProb (copt_prob * prob ,
@@ -458,6 +471,19 @@ int COPT_CALL COPT_AddIndicator(copt_prob *prob,
458471 char cRowSense ,
459472 double dRowBound );
460473
474+ int COPT_CALL COPT_AddIndicators (copt_prob * prob ,
475+ int nInd ,
476+ int * indType ,
477+ int * binColIdx ,
478+ int * binColVal ,
479+ const int * rowMatBeg ,
480+ const int * rowMatCnt ,
481+ const int * rowMatIdx ,
482+ const double * rowMatElem ,
483+ char * cRowSense ,
484+ double * dRowBound ,
485+ char const * const * indNames );
486+
461487int COPT_CALL COPT_GetCols (copt_prob * prob ,
462488 int nCol ,
463489 const int * list ,
@@ -562,6 +588,21 @@ int COPT_CALL COPT_GetIndicator(copt_prob *prob,
562588 int nElemSize ,
563589 int * pReqSize );
564590
591+ int COPT_CALL COPT_GetIndicators (copt_prob * prob ,
592+ int nInd ,
593+ int * list ,
594+ int * indType ,
595+ int * binColIdx ,
596+ int * binColVal ,
597+ int * rowMatBeg ,
598+ int * rowMatCnt ,
599+ int * rowMatIdx ,
600+ double * rowMatElem ,
601+ char * cRowSense ,
602+ double * dRowBound ,
603+ int nElemSize ,
604+ int * pReqSize );
605+
565606int COPT_CALL COPT_GetElem (copt_prob * prob , int iCol , int iRow , double * p_elem );
566607int COPT_CALL COPT_SetElem (copt_prob * prob , int iCol , int iRow , double newElem );
567608int COPT_CALL COPT_SetElems (copt_prob * prob , int nelem , const int * cols , const int * rows , const double * elems );
@@ -620,6 +661,8 @@ int COPT_CALL COPT_SetPSDConstrNames(copt_prob *prob, int num, const int *list,
620661int COPT_CALL COPT_SetLMIConstrRhs (copt_prob * prob , int num , const int * list , const int * newIdx );
621662int COPT_CALL COPT_SetLMIConstrNames (copt_prob * prob , int num , const int * list , char const * const * names );
622663
664+ int COPT_CALL COPT_SetIndicatorNames (copt_prob * prob , int num , const int * list , char const * const * names );
665+
623666int COPT_CALL COPT_ReplaceColObj (copt_prob * prob , int num , const int * list , const double * obj );
624667int COPT_CALL COPT_ReplacePSDObj (copt_prob * prob , int num , const int * list , const int * idx );
625668
@@ -698,6 +741,7 @@ int COPT_CALL COPT_GetRowIdx(copt_prob *prob, const char *rowName, int *p_iRow);
698741int COPT_CALL COPT_GetQConstrIdx (copt_prob * prob , const char * qConstrName , int * p_iQConstr );
699742int COPT_CALL COPT_GetPSDConstrIdx (copt_prob * prob , const char * psdConstrName , int * p_iPSDConstr );
700743int COPT_CALL COPT_GetLMIConstrIdx (copt_prob * prob , const char * lmiConstrName , int * p_iLMIConstr );
744+ int COPT_CALL COPT_GetIndicatorIdx (copt_prob * prob , const char * indicatorName , int * p_iIndicator );
701745int COPT_CALL COPT_GetColInfo (copt_prob * prob , const char * infoName , int num , const int * list , double * info );
702746int COPT_CALL COPT_GetPSDColInfo (copt_prob * prob , const char * infoName , int iCol , double * info );
703747int COPT_CALL COPT_GetRowInfo (copt_prob * prob , const char * infoName , int num , const int * list , double * info );
@@ -725,6 +769,7 @@ int COPT_CALL COPT_GetRowName(copt_prob *prob, int iRow, char *buff, int buffSiz
725769int COPT_CALL COPT_GetQConstrName (copt_prob * prob , int iQConstr , char * buff , int buffSize , int * pReqSize );
726770int COPT_CALL COPT_GetPSDConstrName (copt_prob * prob , int iPSDConstr , char * buff , int buffSize , int * pReqSize );
727771int COPT_CALL COPT_GetLMIConstrName (copt_prob * prob , int iLMIConstr , char * buff , int buffSize , int * pReqSize );
772+ int COPT_CALL COPT_GetIndicatorName (copt_prob * prob , int iIndicator , char * buff , int buffSize , int * pReqSize );
728773
729774int COPT_CALL COPT_SetLogFile (copt_prob * prob , const char * logfilename );
730775int COPT_CALL COPT_SetLogCallback (copt_prob * prob , void (COPT_CALL * logcb )(char * msg , void * userdata ), void * userdata );
0 commit comments