1    	/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
2    	/*                                                                           */
3    	/*                  This file is part of the program and library             */
4    	/*         SCIP --- Solving Constraint Integer Programs                      */
5    	/*                                                                           */
6    	/*  Copyright (c) 2002-2023 Zuse Institute Berlin (ZIB)                      */
7    	/*                                                                           */
8    	/*  Licensed under the Apache License, Version 2.0 (the "License");          */
9    	/*  you may not use this file except in compliance with the License.         */
10   	/*  You may obtain a copy of the License at                                  */
11   	/*                                                                           */
12   	/*      http://www.apache.org/licenses/LICENSE-2.0                           */
13   	/*                                                                           */
14   	/*  Unless required by applicable law or agreed to in writing, software      */
15   	/*  distributed under the License is distributed on an "AS IS" BASIS,        */
16   	/*  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
17   	/*  See the License for the specific language governing permissions and      */
18   	/*  limitations under the License.                                           */
19   	/*                                                                           */
20   	/*  You should have received a copy of the Apache-2.0 license                */
21   	/*  along with SCIP; see the file LICENSE. If not visit scipopt.org.         */
22   	/*                                                                           */
23   	/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
24   	
25   	/**@file   pub_benderscut.h
26   	 * @ingroup PUBLICCOREAPI
27   	 * @brief  public methods for Benders' decomposition cuts
28   	 * @author Stephen J. Maher
29   	 */
30   	
31   	/*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
32   	
33   	#ifndef __SCIP_PUB_BENDERSCUT_H__
34   	#define __SCIP_PUB_BENDERSCUT_H__
35   	
36   	#include "scip/def.h"
37   	#include "scip/type_benderscut.h"
38   	#include "scip/type_cons.h"
39   	#include "scip/type_lp.h"
40   	#include "scip/type_misc.h"
41   	#include "scip/type_retcode.h"
42   	
43   	#ifdef __cplusplus
44   	extern "C" {
45   	#endif
46   	
47   	/**@addtogroup PublicBenderscutsMethods
48   	 *
49   	 * @{
50   	 */
51   	
52   	/** compares two Benders' decomposition cuts w. r. to their priority */
53   	SCIP_EXPORT
54   	SCIP_DECL_SORTPTRCOMP(SCIPbenderscutComp);
55   	
56   	/** comparison method for sorting Benders' decomposition cuts w.r.t. to their name */
57   	SCIP_EXPORT
58   	SCIP_DECL_SORTPTRCOMP(SCIPbenderscutCompName);
59   	
60   	/** gets user data of the Benders' decomposition cut */
61   	SCIP_EXPORT
62   	SCIP_BENDERSCUTDATA* SCIPbenderscutGetData(
63   	   SCIP_BENDERSCUT*      benderscut          /**< Benders' decomposition cut */
64   	   );
65   	
66   	/** sets user data of the Benders' decomposition cut; user has to free old data in advance! */
67   	SCIP_EXPORT
68   	void SCIPbenderscutSetData(
69   	   SCIP_BENDERSCUT*      benderscut,         /**< Benders' decomposition cut */
70   	   SCIP_BENDERSCUTDATA*  benderscutdata      /**< new Benders' decomposition cut user data */
71   	   );
72   	
73   	/** gets name of the Benders' decomposition cut */
74   	SCIP_EXPORT
75   	const char* SCIPbenderscutGetName(
76   	   SCIP_BENDERSCUT*      benderscut          /**< Benders' decomposition cut */
77   	   );
78   	
79   	/** gets description of the Benders' decomposition cut */
80   	SCIP_EXPORT
81   	const char* SCIPbenderscutGetDesc(
82   	   SCIP_BENDERSCUT*      benderscut          /**< Benders' decomposition cut */
83   	   );
84   	
85   	/** gets priority of the Benders' decomposition cut */
86   	SCIP_EXPORT
87   	int SCIPbenderscutGetPriority(
88   	   SCIP_BENDERSCUT*      benderscut          /**< Benders' decomposition cut */
89   	   );
90   	
91   	/** gets the number of times, the Benders' decomposition cut was called and tried to find a violated cut */
92   	SCIP_EXPORT
93   	SCIP_Longint SCIPbenderscutGetNCalls(
94   	   SCIP_BENDERSCUT*      benderscut          /**< Benders' decomposition cut */
95   	   );
96   	
97   	/** gets the number of the cuts found by this Benders' decomposition cut */
98   	SCIP_EXPORT
99   	SCIP_Longint SCIPbenderscutGetNFound(
100  	   SCIP_BENDERSCUT*      benderscut          /**< Benders' decomposition cut */
101  	   );
102  	
103  	/** is the Benders' decomposition cut initialized? */
104  	SCIP_EXPORT
105  	SCIP_Bool SCIPbenderscutIsInitialized(
106  	   SCIP_BENDERSCUT*      benderscut          /**< Benders' decomposition cut */
107  	   );
108  	
109  	/** gets time in seconds used in this Benders' decomposition cut for setting up for next stages */
110  	SCIP_EXPORT
111  	SCIP_Real SCIPbenderscutGetSetupTime(
112  	   SCIP_BENDERSCUT*      benderscut          /**< Benders' decomposition cut */
113  	   );
114  	
115  	/** gets time in seconds used in this Benders' decomposition cut */
116  	SCIP_EXPORT
117  	SCIP_Real SCIPbenderscutGetTime(
118  	   SCIP_BENDERSCUT*      benderscut          /**< Benders' decomposition cut */
119  	   );
120  	
121  	/** returns whether the Benders' cut uses the LP information */
122  	SCIP_EXPORT
123  	SCIP_Bool SCIPbenderscutIsLPCut(
124  	   SCIP_BENDERSCUT*      benderscut          /**< Benders' decomposition cut */
125  	   );
126  	
127  	/** sets the enabled flag of the Benders' decomposition cut method */
128  	SCIP_EXPORT
129  	void SCIPbenderscutSetEnabled(
130  	   SCIP_BENDERSCUT*      benderscut,         /**< Benders' decomposition cut */
131  	   SCIP_Bool             enabled             /**< flag to indicate whether the Benders' decomposition cut is enabled */
132  	   );
133  	
134  	/** @} */
135  	
136  	#ifdef __cplusplus
137  	}
138  	#endif
139  	
140  	#endif
141