Scippy

SCIP

Solving Constraint Integer Programs

scip_event.c
Go to the documentation of this file.
1/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
2/* */
3/* This file is part of the program and library */
4/* SCIP --- Solving Constraint Integer Programs */
5/* */
6/* Copyright (c) 2002-2025 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 scip_event.c
26 * @ingroup OTHER_CFILES
27 * @brief public methods for event handler plugins and event handlers
28 * @author Tobias Achterberg
29 * @author Timo Berthold
30 * @author Gerald Gamrath
31 * @author Leona Gottwald
32 * @author Stefan Heinz
33 * @author Gregor Hendel
34 * @author Thorsten Koch
35 * @author Alexander Martin
36 * @author Marc Pfetsch
37 * @author Michael Winkler
38 * @author Kati Wolter
39 *
40 * @todo check all SCIP_STAGE_* switches, and include the new stages TRANSFORMED and INITSOLVE
41 */
42
43/*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
44
45#include "scip/debug.h"
46#include "scip/event.h"
47#include "scip/lp.h"
48#include "scip/pub_message.h"
49#include "scip/pub_var.h"
50#include "scip/scip_event.h"
51#include "scip/set.h"
52#include "scip/struct_mem.h"
53#include "scip/struct_scip.h"
54#include "scip/struct_set.h"
55#include "scip/var.h"
56
57/** creates an event handler and includes it in SCIP
58 * @pre This method can be called if SCIP is in one of the following stages:
59 * - \ref SCIP_STAGE_INIT
60 * - \ref SCIP_STAGE_PROBLEM
61 *
62 * @note method has all event handler callbacks as arguments and is thus changed every time a new
63 * callback is added in future releases; consider using SCIPincludeEventhdlrBasic() and setter functions
64 * if you seek for a method which is less likely to change in future releases
65 */
67 SCIP* scip, /**< SCIP data structure */
68 const char* name, /**< name of event handler */
69 const char* desc, /**< description of event handler */
70 SCIP_DECL_EVENTCOPY ((*eventcopy)), /**< copy method of event handler or NULL if you don't want to copy your plugin into sub-SCIPs */
71 SCIP_DECL_EVENTFREE ((*eventfree)), /**< destructor of event handler */
72 SCIP_DECL_EVENTINIT ((*eventinit)), /**< initialize event handler */
73 SCIP_DECL_EVENTEXIT ((*eventexit)), /**< deinitialize event handler */
74 SCIP_DECL_EVENTINITSOL((*eventinitsol)), /**< solving process initialization method of event handler */
75 SCIP_DECL_EVENTEXITSOL((*eventexitsol)), /**< solving process deinitialization method of event handler */
76 SCIP_DECL_EVENTDELETE ((*eventdelete)), /**< free specific event data */
77 SCIP_DECL_EVENTEXEC ((*eventexec)), /**< execute event handler */
78 SCIP_EVENTHDLRDATA* eventhdlrdata /**< event handler data */
79 )
80{
81 SCIP_EVENTHDLR* eventhdlr;
82
84
85 /* check whether event handler is already present */
86 if( SCIPfindEventhdlr(scip, name) != NULL )
87 {
88 SCIPerrorMessage("event handler <%s> already included.\n", name);
89 return SCIP_INVALIDDATA;
90 }
91
92 SCIP_CALL( SCIPeventhdlrCreate(&eventhdlr, scip->set, name, desc,
93 eventcopy, eventfree, eventinit, eventexit, eventinitsol, eventexitsol, eventdelete, eventexec,
94 eventhdlrdata) );
95 SCIP_CALL( SCIPsetIncludeEventhdlr(scip->set, eventhdlr) );
96
97 return SCIP_OKAY;
98}
99
100/** creates an event handler and includes it in SCIP with all its non-fundamental callbacks set
101 * to NULL; if needed, non-fundamental callbacks can be set afterwards via setter functions
102 * SCIPsetEventhdlrCopy(), SCIPsetEventhdlrFree(), SCIPsetEventhdlrInit(), SCIPsetEventhdlrExit(),
103 * SCIPsetEventhdlrInitsol(), SCIPsetEventhdlrExitsol(), and SCIPsetEventhdlrDelete()
104 *
105 * @pre This method can be called if SCIP is in one of the following stages:
106 * - \ref SCIP_STAGE_INIT
107 * - \ref SCIP_STAGE_PROBLEM
108 *
109 * @note if you want to set all callbacks with a single method call, consider using SCIPincludeEventhdlr() instead
110 */
112 SCIP* scip, /**< SCIP data structure */
113 SCIP_EVENTHDLR** eventhdlrptr, /**< reference to an event handler, or NULL */
114 const char* name, /**< name of event handler */
115 const char* desc, /**< description of event handler */
116 SCIP_DECL_EVENTEXEC ((*eventexec)), /**< execute event handler */
117 SCIP_EVENTHDLRDATA* eventhdlrdata /**< event handler data */
118 )
119{
120 SCIP_EVENTHDLR* eventhdlr;
121
122 SCIP_CALL( SCIPcheckStage(scip, "SCIPincludeEventhdlrBasic", TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE) );
123
124 /* check whether event handler is already present */
125 if( SCIPfindEventhdlr(scip, name) != NULL )
126 {
127 SCIPerrorMessage("event handler <%s> already included.\n", name);
128 return SCIP_INVALIDDATA;
129 }
130
131 SCIP_CALL( SCIPeventhdlrCreate(&eventhdlr, scip->set, name, desc,
132 NULL, NULL, NULL, NULL, NULL, NULL, NULL, eventexec,
133 eventhdlrdata) );
134 SCIP_CALL( SCIPsetIncludeEventhdlr(scip->set, eventhdlr) );
135
136 if( eventhdlrptr != NULL )
137 *eventhdlrptr = eventhdlr;
138
139 return SCIP_OKAY;
140}
141
142/** sets copy callback of the event handler */
144 SCIP* scip, /**< scip instance */
145 SCIP_EVENTHDLR* eventhdlr, /**< event handler */
146 SCIP_DECL_EVENTCOPY ((*eventcopy)) /**< copy callback of the event handler */
147 )
148{
149 assert(scip != NULL);
150 SCIP_CALL( SCIPcheckStage(scip, "SCIPsetEventhdlrCopy", TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE) );
151
152 SCIPeventhdlrSetCopy(eventhdlr, eventcopy);
153 return SCIP_OKAY;
154}
155
156/** sets deinitialization callback of the event handler */
158 SCIP* scip, /**< scip instance */
159 SCIP_EVENTHDLR* eventhdlr, /**< event handler */
160 SCIP_DECL_EVENTFREE ((*eventfree)) /**< deinitialization callback of the event handler */
161 )
162{
163 assert(scip != NULL);
164 SCIP_CALL( SCIPcheckStage(scip, "SCIPsetEventhdlrFree", TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE) );
165
166 SCIPeventhdlrSetFree(eventhdlr, eventfree);
167 return SCIP_OKAY;
168}
169
170/** sets initialization callback of the event handler */
172 SCIP* scip, /**< scip instance */
173 SCIP_EVENTHDLR* eventhdlr, /**< event handler */
174 SCIP_DECL_EVENTINIT ((*eventinit)) /**< initialize event handler */
175 )
176{
177 assert(scip != NULL);
178 SCIP_CALL( SCIPcheckStage(scip, "SCIPsetEventhdlrInit", TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE) );
179
180 SCIPeventhdlrSetInit(eventhdlr, eventinit);
181 return SCIP_OKAY;
182}
183
184/** sets deinitialization callback of the event handler */
186 SCIP* scip, /**< scip instance */
187 SCIP_EVENTHDLR* eventhdlr, /**< event handler */
188 SCIP_DECL_EVENTEXIT ((*eventexit)) /**< deinitialize event handler */
189 )
190{
191 assert(scip != NULL);
192 SCIP_CALL( SCIPcheckStage(scip, "SCIPsetEventhdlrExit", TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE) );
193
194 SCIPeventhdlrSetExit(eventhdlr, eventexit);
195 return SCIP_OKAY;
196}
197
198/** sets solving process initialization callback of the event handler */
200 SCIP* scip, /**< scip instance */
201 SCIP_EVENTHDLR* eventhdlr, /**< event handler */
202 SCIP_DECL_EVENTINITSOL((*eventinitsol)) /**< solving process initialization callback of event handler */
203 )
204{
205 assert(scip != NULL);
206 SCIP_CALL( SCIPcheckStage(scip, "SCIPsetEventhdlrInitsol", TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE) );
207
208 SCIPeventhdlrSetInitsol(eventhdlr, eventinitsol);
209 return SCIP_OKAY;
210}
211
212/** sets solving process deinitialization callback of the event handler */
214 SCIP* scip, /**< scip instance */
215 SCIP_EVENTHDLR* eventhdlr, /**< event handler */
216 SCIP_DECL_EVENTEXITSOL((*eventexitsol)) /**< solving process deinitialization callback of event handler */
217 )
218{
219 assert(scip != NULL);
220 SCIP_CALL( SCIPcheckStage(scip, "SCIPsetEventhdlrExitsol", TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE) );
221
222 SCIPeventhdlrSetExitsol(eventhdlr, eventexitsol);
223 return SCIP_OKAY;
224}
225
226/** sets callback of the event handler to free specific event data */
228 SCIP* scip, /**< scip instance */
229 SCIP_EVENTHDLR* eventhdlr, /**< event handler */
230 SCIP_DECL_EVENTDELETE ((*eventdelete)) /**< free specific event data */
231 )
232{
233 assert(scip != NULL);
234 SCIP_CALL( SCIPcheckStage(scip, "SCIPsetEventhdlrDelete", TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE) );
235
236 SCIPeventhdlrSetDelete(eventhdlr, eventdelete);
237 return SCIP_OKAY;
238}
239
240/** returns the event handler of the given name, or NULL if not existing */
242 SCIP* scip, /**< SCIP data structure */
243 const char* name /**< name of event handler */
244 )
245{
246 assert(scip != NULL);
247 assert(scip->set != NULL);
248 assert(name != NULL);
249
250 return SCIPsetFindEventhdlr(scip->set, name);
251}
252
253/** returns the array of currently available event handlers */
255 SCIP* scip /**< SCIP data structure */
256 )
257{
258 assert(scip != NULL);
259 assert(scip->set != NULL);
260
261 return scip->set->eventhdlrs;
262}
263
264/** returns the number of currently available event handlers */
266 SCIP* scip /**< SCIP data structure */
267 )
268{
269 assert(scip != NULL);
270 assert(scip->set != NULL);
271
272 return scip->set->neventhdlrs;
273}
274
275/** catches a global (not variable or row dependent) event
276 *
277 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
278 * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
279 *
280 * @pre This method can be called if @p scip is in one of the following stages:
281 * - \ref SCIP_STAGE_TRANSFORMING
282 * - \ref SCIP_STAGE_TRANSFORMED
283 * - \ref SCIP_STAGE_INITPRESOLVE
284 * - \ref SCIP_STAGE_PRESOLVING
285 * - \ref SCIP_STAGE_EXITPRESOLVE
286 * - \ref SCIP_STAGE_PRESOLVED
287 * - \ref SCIP_STAGE_INITSOLVE
288 * - \ref SCIP_STAGE_SOLVING
289 * - \ref SCIP_STAGE_SOLVED
290 * - \ref SCIP_STAGE_EXITSOLVE
291 * - \ref SCIP_STAGE_FREETRANS
292 */
294 SCIP* scip, /**< SCIP data structure */
295 SCIP_EVENTTYPE eventtype, /**< event type mask to select events to catch */
296 SCIP_EVENTHDLR* eventhdlr, /**< event handler to process events with */
297 SCIP_EVENTDATA* eventdata, /**< event data to pass to the event handler when processing this event */
298 int* filterpos /**< pointer to store position of event filter entry, or NULL */
299 )
300{
301 SCIP_CALL( SCIPcheckStage(scip, "SCIPcatchEvent", FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
302
303 SCIP_CALL( SCIPeventfilterAdd(scip->eventfilter, scip->mem->probmem, scip->set,
304 eventtype, eventhdlr, eventdata, filterpos) );
305
306 return SCIP_OKAY;
307}
308
309/** drops a global event (stops to track event)
310 *
311 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
312 * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
313 *
314 * @pre This method can be called if @p scip is in one of the following stages:
315 * - \ref SCIP_STAGE_TRANSFORMING
316 * - \ref SCIP_STAGE_TRANSFORMED
317 * - \ref SCIP_STAGE_INITPRESOLVE
318 * - \ref SCIP_STAGE_PRESOLVING
319 * - \ref SCIP_STAGE_EXITPRESOLVE
320 * - \ref SCIP_STAGE_PRESOLVED
321 * - \ref SCIP_STAGE_INITSOLVE
322 * - \ref SCIP_STAGE_SOLVING
323 * - \ref SCIP_STAGE_SOLVED
324 * - \ref SCIP_STAGE_EXITSOLVE
325 * - \ref SCIP_STAGE_FREETRANS
326 */
328 SCIP* scip, /**< SCIP data structure */
329 SCIP_EVENTTYPE eventtype, /**< event type mask of dropped event */
330 SCIP_EVENTHDLR* eventhdlr, /**< event handler to process events with */
331 SCIP_EVENTDATA* eventdata, /**< event data to pass to the event handler when processing this event */
332 int filterpos /**< position of event filter entry returned by SCIPcatchEvent(), or -1 */
333 )
334{
336
337 SCIP_CALL( SCIPeventfilterDel(scip->eventfilter, scip->mem->probmem, scip->set,
338 eventtype, eventhdlr, eventdata, filterpos) );
339
340 return SCIP_OKAY;
341}
342
343/** catches an objective value or domain change event on the given transformed variable
344 *
345 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
346 * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
347 *
348 * @pre This method can be called if @p scip is in one of the following stages:
349 * - \ref SCIP_STAGE_TRANSFORMING
350 * - \ref SCIP_STAGE_TRANSFORMED
351 * - \ref SCIP_STAGE_INITPRESOLVE
352 * - \ref SCIP_STAGE_PRESOLVING
353 * - \ref SCIP_STAGE_EXITPRESOLVE
354 * - \ref SCIP_STAGE_PRESOLVED
355 * - \ref SCIP_STAGE_INITSOLVE
356 * - \ref SCIP_STAGE_SOLVING
357 * - \ref SCIP_STAGE_SOLVED
358 * - \ref SCIP_STAGE_EXITSOLVE
359 * - \ref SCIP_STAGE_FREETRANS
360 */
362 SCIP* scip, /**< SCIP data structure */
363 SCIP_VAR* var, /**< transformed variable to catch event for */
364 SCIP_EVENTTYPE eventtype, /**< event type mask to select events to catch */
365 SCIP_EVENTHDLR* eventhdlr, /**< event handler to process events with */
366 SCIP_EVENTDATA* eventdata, /**< event data to pass to the event handler when processing this event */
367 int* filterpos /**< pointer to store position of event filter entry, or NULL */
368 )
369{
370 SCIP_CALL( SCIPcheckStage(scip, "SCIPcatchVarEvent", FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
371
372 if( (eventtype & SCIP_EVENTTYPE_VARCHANGED) == 0 )
373 {
374 SCIPerrorMessage("event does not operate on a single variable\n");
375 return SCIP_INVALIDDATA;
376 }
377
378 if( SCIPvarIsOriginal(var) )
379 {
380 SCIPerrorMessage("cannot catch events on original variable <%s>\n", SCIPvarGetName(var));
381 return SCIP_INVALIDDATA;
382 }
383
384 SCIP_CALL( SCIPvarCatchEvent(var, scip->mem->probmem, scip->set, eventtype, eventhdlr, eventdata, filterpos) );
385
386 return SCIP_OKAY;
387}
388
389/** drops an objective value or domain change event (stops to track event) on the given transformed variable
390 *
391 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
392 * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
393 *
394 * @pre This method can be called if @p scip is in one of the following stages:
395 * - \ref SCIP_STAGE_TRANSFORMING
396 * - \ref SCIP_STAGE_TRANSFORMED
397 * - \ref SCIP_STAGE_INITPRESOLVE
398 * - \ref SCIP_STAGE_PRESOLVING
399 * - \ref SCIP_STAGE_EXITPRESOLVE
400 * - \ref SCIP_STAGE_PRESOLVED
401 * - \ref SCIP_STAGE_INITSOLVE
402 * - \ref SCIP_STAGE_SOLVING
403 * - \ref SCIP_STAGE_SOLVED
404 * - \ref SCIP_STAGE_EXITSOLVE
405 * - \ref SCIP_STAGE_FREETRANS
406 */
408 SCIP* scip, /**< SCIP data structure */
409 SCIP_VAR* var, /**< transformed variable to drop event for */
410 SCIP_EVENTTYPE eventtype, /**< event type mask of dropped event */
411 SCIP_EVENTHDLR* eventhdlr, /**< event handler to process events with */
412 SCIP_EVENTDATA* eventdata, /**< event data to pass to the event handler when processing this event */
413 int filterpos /**< position of event filter entry returned by SCIPcatchVarEvent(), or -1 */
414 )
415{
416 SCIP_CALL( SCIPcheckStage(scip, "SCIPdropVarEvent", FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
417
418 if( SCIPvarIsOriginal(var) )
419 {
420 SCIPerrorMessage("cannot drop events on original variable <%s>\n", SCIPvarGetName(var));
421 return SCIP_INVALIDDATA;
422 }
423
424 SCIP_CALL( SCIPvarDropEvent(var, scip->mem->probmem, scip->set, eventtype, eventhdlr, eventdata, filterpos) );
425
426 return SCIP_OKAY;
427}
428
429/** catches a row coefficient, constant, or side change event on the given row
430 *
431 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
432 * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
433 *
434 * @pre This method can be called if @p scip is in one of the following stages:
435 * - \ref SCIP_STAGE_TRANSFORMING
436 * - \ref SCIP_STAGE_TRANSFORMED
437 * - \ref SCIP_STAGE_INITPRESOLVE
438 * - \ref SCIP_STAGE_PRESOLVING
439 * - \ref SCIP_STAGE_EXITPRESOLVE
440 * - \ref SCIP_STAGE_PRESOLVED
441 * - \ref SCIP_STAGE_INITSOLVE
442 * - \ref SCIP_STAGE_SOLVING
443 * - \ref SCIP_STAGE_SOLVED
444 * - \ref SCIP_STAGE_EXITSOLVE
445 * - \ref SCIP_STAGE_FREETRANS
446 */
448 SCIP* scip, /**< SCIP data structure */
449 SCIP_ROW* row, /**< linear row to catch event for */
450 SCIP_EVENTTYPE eventtype, /**< event type mask to select events to catch */
451 SCIP_EVENTHDLR* eventhdlr, /**< event handler to process events with */
452 SCIP_EVENTDATA* eventdata, /**< event data to pass to the event handler when processing this event */
453 int* filterpos /**< pointer to store position of event filter entry, or NULL */
454 )
455{
456 SCIP_CALL( SCIPcheckStage(scip, "SCIPcatchRowEvent", FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
457
458 if( (eventtype & SCIP_EVENTTYPE_ROWCHANGED) == 0 )
459 {
460 SCIPerrorMessage("event does not operate on a single row\n");
461 return SCIP_INVALIDDATA;
462 }
463
464 SCIP_CALL( SCIProwCatchEvent(row, scip->mem->probmem, scip->set, eventtype, eventhdlr, eventdata, filterpos) );
465
466 return SCIP_OKAY;
467}
468
469/** drops a row coefficient, constant, or side change event (stops to track event) on the given row
470 *
471 * @return \ref SCIP_OKAY is returned if everything worked. Otherwise a suitable error code is passed. See \ref
472 * SCIP_Retcode "SCIP_RETCODE" for a complete list of error codes.
473 *
474 * @pre This method can be called if @p scip is in one of the following stages:
475 * - \ref SCIP_STAGE_TRANSFORMING
476 * - \ref SCIP_STAGE_TRANSFORMED
477 * - \ref SCIP_STAGE_INITPRESOLVE
478 * - \ref SCIP_STAGE_PRESOLVING
479 * - \ref SCIP_STAGE_EXITPRESOLVE
480 * - \ref SCIP_STAGE_PRESOLVED
481 * - \ref SCIP_STAGE_INITSOLVE
482 * - \ref SCIP_STAGE_SOLVING
483 * - \ref SCIP_STAGE_SOLVED
484 * - \ref SCIP_STAGE_EXITSOLVE
485 * - \ref SCIP_STAGE_FREETRANS
486 */
488 SCIP* scip, /**< SCIP data structure */
489 SCIP_ROW* row, /**< linear row to drop event for */
490 SCIP_EVENTTYPE eventtype, /**< event type mask of dropped event */
491 SCIP_EVENTHDLR* eventhdlr, /**< event handler to process events with */
492 SCIP_EVENTDATA* eventdata, /**< event data to pass to the event handler when processing this event */
493 int filterpos /**< position of event filter entry returned by SCIPcatchVarEvent(), or -1 */
494 )
495{
496 SCIP_CALL( SCIPcheckStage(scip, "SCIPdropRowEvent", FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE) );
497
498 SCIP_CALL( SCIProwDropEvent(row, scip->mem->probmem, scip->set, eventtype, eventhdlr, eventdata, filterpos) );
499
500 return SCIP_OKAY;
501}
SCIP_DECL_EVENTDELETE(EventhdlrNewSol::scip_delete)
SCIP_DECL_EVENTEXEC(EventhdlrNewSol::scip_exec)
SCIP_DECL_EVENTINIT(EventhdlrNewSol::scip_init)
SCIP_DECL_EVENTINITSOL(EventhdlrNewSol::scip_initsol)
SCIP_DECL_EVENTEXIT(EventhdlrNewSol::scip_exit)
SCIP_DECL_EVENTEXITSOL(EventhdlrNewSol::scip_exitsol)
SCIP_DECL_EVENTFREE(EventhdlrNewSol::scip_free)
SCIP_RETCODE SCIPcheckStage(SCIP *scip, const char *method, SCIP_Bool init, SCIP_Bool problem, SCIP_Bool transforming, SCIP_Bool transformed, SCIP_Bool initpresolve, SCIP_Bool presolving, SCIP_Bool exitpresolve, SCIP_Bool presolved, SCIP_Bool initsolve, SCIP_Bool solving, SCIP_Bool solved, SCIP_Bool exitsolve, SCIP_Bool freetrans, SCIP_Bool freescip)
Definition: debug.c:2203
methods for debugging
#define NULL
Definition: def.h:266
#define TRUE
Definition: def.h:93
#define FALSE
Definition: def.h:94
#define SCIP_CALL(x)
Definition: def.h:373
SCIP_RETCODE SCIPeventhdlrCreate(SCIP_EVENTHDLR **eventhdlr, SCIP_SET *set, const char *name, const char *desc, SCIP_DECL_EVENTCOPY((*eventcopy)), SCIP_DECL_EVENTFREE((*eventfree)), SCIP_DECL_EVENTINIT((*eventinit)), SCIP_DECL_EVENTEXIT((*eventexit)), SCIP_DECL_EVENTINITSOL((*eventinitsol)), SCIP_DECL_EVENTEXITSOL((*eventexitsol)), SCIP_DECL_EVENTDELETE((*eventdelete)), SCIP_DECL_EVENTEXEC((*eventexec)), SCIP_EVENTHDLRDATA *eventhdlrdata)
Definition: event.c:123
void SCIPeventhdlrSetFree(SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTFREE((*eventfree)))
Definition: event.c:366
void SCIPeventhdlrSetExitsol(SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTEXITSOL((*eventexitsol)))
Definition: event.c:410
void SCIPeventhdlrSetInitsol(SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTINITSOL((*eventinitsol)))
Definition: event.c:399
void SCIPeventhdlrSetCopy(SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTCOPY((*eventcopy)))
Definition: event.c:355
void SCIPeventhdlrSetInit(SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTINIT((*eventinit)))
Definition: event.c:377
SCIP_RETCODE SCIPeventfilterDel(SCIP_EVENTFILTER *eventfilter, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int filterpos)
Definition: event.c:1979
void SCIPeventhdlrSetDelete(SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTDELETE((*eventdelete)))
Definition: event.c:421
void SCIPeventhdlrSetExit(SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTEXIT((*eventexit)))
Definition: event.c:388
SCIP_RETCODE SCIPeventfilterAdd(SCIP_EVENTFILTER *eventfilter, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int *filterpos)
Definition: event.c:1886
internal methods for managing events
SCIP_EVENTHDLR ** SCIPgetEventhdlrs(SCIP *scip)
Definition: scip_event.c:254
SCIP_RETCODE SCIPsetEventhdlrInitsol(SCIP *scip, SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTINITSOL((*eventinitsol)))
Definition: scip_event.c:199
SCIP_RETCODE SCIPincludeEventhdlr(SCIP *scip, const char *name, const char *desc, SCIP_DECL_EVENTCOPY((*eventcopy)), SCIP_DECL_EVENTFREE((*eventfree)), SCIP_DECL_EVENTINIT((*eventinit)), SCIP_DECL_EVENTEXIT((*eventexit)), SCIP_DECL_EVENTINITSOL((*eventinitsol)), SCIP_DECL_EVENTEXITSOL((*eventexitsol)), SCIP_DECL_EVENTDELETE((*eventdelete)), SCIP_DECL_EVENTEXEC((*eventexec)), SCIP_EVENTHDLRDATA *eventhdlrdata)
Definition: scip_event.c:66
SCIP_RETCODE SCIPsetEventhdlrDelete(SCIP *scip, SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTDELETE((*eventdelete)))
Definition: scip_event.c:227
SCIP_RETCODE SCIPsetEventhdlrCopy(SCIP *scip, SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTCOPY((*eventcopy)))
Definition: scip_event.c:143
SCIP_RETCODE SCIPincludeEventhdlrBasic(SCIP *scip, SCIP_EVENTHDLR **eventhdlrptr, const char *name, const char *desc, SCIP_DECL_EVENTEXEC((*eventexec)), SCIP_EVENTHDLRDATA *eventhdlrdata)
Definition: scip_event.c:111
SCIP_EVENTHDLR * SCIPfindEventhdlr(SCIP *scip, const char *name)
Definition: scip_event.c:241
SCIP_RETCODE SCIPsetEventhdlrExitsol(SCIP *scip, SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTEXITSOL((*eventexitsol)))
Definition: scip_event.c:213
int SCIPgetNEventhdlrs(SCIP *scip)
Definition: scip_event.c:265
SCIP_RETCODE SCIPsetEventhdlrFree(SCIP *scip, SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTFREE((*eventfree)))
Definition: scip_event.c:157
SCIP_RETCODE SCIPsetEventhdlrExit(SCIP *scip, SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTEXIT((*eventexit)))
Definition: scip_event.c:185
SCIP_RETCODE SCIPsetEventhdlrInit(SCIP *scip, SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTINIT((*eventinit)))
Definition: scip_event.c:171
SCIP_RETCODE SCIPcatchVarEvent(SCIP *scip, SCIP_VAR *var, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int *filterpos)
Definition: scip_event.c:361
SCIP_RETCODE SCIPdropVarEvent(SCIP *scip, SCIP_VAR *var, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int filterpos)
Definition: scip_event.c:407
SCIP_RETCODE SCIPdropRowEvent(SCIP *scip, SCIP_ROW *row, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int filterpos)
Definition: scip_event.c:487
SCIP_RETCODE SCIPcatchEvent(SCIP *scip, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int *filterpos)
Definition: scip_event.c:293
SCIP_RETCODE SCIPcatchRowEvent(SCIP *scip, SCIP_ROW *row, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int *filterpos)
Definition: scip_event.c:447
SCIP_RETCODE SCIPdropEvent(SCIP *scip, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int filterpos)
Definition: scip_event.c:327
const char * SCIPvarGetName(SCIP_VAR *var)
Definition: var.c:17446
SCIP_Bool SCIPvarIsOriginal(SCIP_VAR *var)
Definition: var.c:17575
SCIP_RETCODE SCIProwCatchEvent(SCIP_ROW *row, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int *filterpos)
Definition: lp.c:7831
SCIP_RETCODE SCIProwDropEvent(SCIP_ROW *row, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int filterpos)
Definition: lp.c:7855
internal methods for LP management
public methods for message output
#define SCIPerrorMessage
Definition: pub_message.h:64
public methods for problem variables
public methods for event handler plugins and event handlers
SCIP_RETCODE SCIPsetIncludeEventhdlr(SCIP_SET *set, SCIP_EVENTHDLR *eventhdlr)
Definition: set.c:4729
SCIP_EVENTHDLR * SCIPsetFindEventhdlr(SCIP_SET *set, const char *name)
Definition: set.c:4752
internal methods for global SCIP settings
datastructures for block memory pools and memory buffers
SCIP main data structure.
datastructures for global SCIP settings
struct SCIP_EventData SCIP_EVENTDATA
Definition: type_event.h:173
#define SCIP_EVENTTYPE_ROWCHANGED
Definition: type_event.h:148
struct SCIP_EventhdlrData SCIP_EVENTHDLRDATA
Definition: type_event.h:155
#define SCIP_DECL_EVENTCOPY(x)
Definition: type_event.h:183
#define SCIP_EVENTTYPE_VARCHANGED
Definition: type_event.h:130
uint64_t SCIP_EVENTTYPE
Definition: type_event.h:151
@ SCIP_INVALIDDATA
Definition: type_retcode.h:52
@ SCIP_OKAY
Definition: type_retcode.h:42
enum SCIP_Retcode SCIP_RETCODE
Definition: type_retcode.h:63
SCIP_RETCODE SCIPvarDropEvent(SCIP_VAR *var, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int filterpos)
Definition: var.c:18612
SCIP_RETCODE SCIPvarCatchEvent(SCIP_VAR *var, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int *filterpos)
Definition: var.c:18585
internal methods for problem variables