Scippy

SCIP

Solving Constraint Integer Programs

event.c File Reference

Detailed Description

methods and datastructures for managing events

Author
Tobias Achterberg

Definition in file event.c.

#include <assert.h>
#include <string.h>
#include "scip/def.h"
#include "scip/set.h"
#include "scip/clock.h"
#include "scip/event.h"
#include "scip/lp.h"
#include "scip/var.h"
#include "scip/primal.h"
#include "scip/branch.h"
#include "scip/pub_message.h"

Go to the source code of this file.

Functions

SCIP_RETCODE SCIPeventhdlrCopyInclude (SCIP_EVENTHDLR *eventhdlr, SCIP_SET *set)
 
SCIP_RETCODE SCIPeventhdlrCreate (SCIP_EVENTHDLR **eventhdlr, 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)
 
SCIP_RETCODE SCIPeventhdlrFree (SCIP_EVENTHDLR **eventhdlr, SCIP_SET *set)
 
SCIP_RETCODE SCIPeventhdlrInit (SCIP_EVENTHDLR *eventhdlr, SCIP_SET *set)
 
SCIP_RETCODE SCIPeventhdlrExit (SCIP_EVENTHDLR *eventhdlr, SCIP_SET *set)
 
SCIP_RETCODE SCIPeventhdlrInitsol (SCIP_EVENTHDLR *eventhdlr, SCIP_SET *set)
 
SCIP_RETCODE SCIPeventhdlrExitsol (SCIP_EVENTHDLR *eventhdlr, SCIP_SET *set)
 
SCIP_RETCODE SCIPeventhdlrExec (SCIP_EVENTHDLR *eventhdlr, SCIP_SET *set, SCIP_EVENT *event, SCIP_EVENTDATA *eventdata)
 
const char * SCIPeventhdlrGetName (SCIP_EVENTHDLR *eventhdlr)
 
SCIP_EVENTHDLRDATASCIPeventhdlrGetData (SCIP_EVENTHDLR *eventhdlr)
 
void SCIPeventhdlrSetData (SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTHDLRDATA *eventhdlrdata)
 
void SCIPeventhdlrSetCopy (SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTCOPY((*eventcopy)))
 
void SCIPeventhdlrSetFree (SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTFREE((*eventfree)))
 
void SCIPeventhdlrSetInit (SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTINIT((*eventinit)))
 
void SCIPeventhdlrSetExit (SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTEXIT((*eventexit)))
 
void SCIPeventhdlrSetInitsol (SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTINITSOL((*eventinitsol)))
 
void SCIPeventhdlrSetExitsol (SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTEXITSOL((*eventexitsol)))
 
void SCIPeventhdlrSetDelete (SCIP_EVENTHDLR *eventhdlr, SCIP_DECL_EVENTDELETE((*eventdelete)))
 
SCIP_Bool SCIPeventhdlrIsInitialized (SCIP_EVENTHDLR *eventhdlr)
 
void SCIPeventhdlrEnableOrDisableClocks (SCIP_EVENTHDLR *eventhdlr, SCIP_Bool enable)
 
SCIP_Real SCIPeventhdlrGetSetupTime (SCIP_EVENTHDLR *eventhdlr)
 
SCIP_Real SCIPeventhdlrGetTime (SCIP_EVENTHDLR *eventhdlr)
 
SCIP_RETCODE SCIPeventCreateVarAdded (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var)
 
SCIP_RETCODE SCIPeventCreateVarDeleted (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var)
 
SCIP_RETCODE SCIPeventCreateVarFixed (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var)
 
SCIP_RETCODE SCIPeventCreateVarUnlocked (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var)
 
SCIP_RETCODE SCIPeventCreateObjChanged (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var, SCIP_Real oldobj, SCIP_Real newobj)
 
SCIP_RETCODE SCIPeventCreateGlbChanged (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var, SCIP_Real oldbound, SCIP_Real newbound)
 
SCIP_RETCODE SCIPeventCreateGubChanged (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var, SCIP_Real oldbound, SCIP_Real newbound)
 
SCIP_RETCODE SCIPeventCreateLbChanged (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var, SCIP_Real oldbound, SCIP_Real newbound)
 
SCIP_RETCODE SCIPeventCreateUbChanged (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var, SCIP_Real oldbound, SCIP_Real newbound)
 
SCIP_RETCODE SCIPeventCreateGholeAdded (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var, SCIP_Real left, SCIP_Real right)
 
SCIP_RETCODE SCIPeventCreateGholeRemoved (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var, SCIP_Real left, SCIP_Real right)
 
SCIP_RETCODE SCIPeventCreateLholeAdded (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var, SCIP_Real left, SCIP_Real right)
 
SCIP_RETCODE SCIPeventCreateLholeRemoved (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var, SCIP_Real left, SCIP_Real right)
 
SCIP_RETCODE SCIPeventCreateImplAdded (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_VAR *var)
 
SCIP_RETCODE SCIPeventCreateRowAddedSepa (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_ROW *row)
 
SCIP_RETCODE SCIPeventCreateRowDeletedSepa (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_ROW *row)
 
SCIP_RETCODE SCIPeventCreateRowAddedLP (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_ROW *row)
 
SCIP_RETCODE SCIPeventCreateRowDeletedLP (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_ROW *row)
 
SCIP_RETCODE SCIPeventCreateRowCoefChanged (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_ROW *row, SCIP_COL *col, SCIP_Real oldval, SCIP_Real newval)
 
SCIP_RETCODE SCIPeventCreateRowConstChanged (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_ROW *row, SCIP_Real oldval, SCIP_Real newval)
 
SCIP_RETCODE SCIPeventCreateRowSideChanged (SCIP_EVENT **event, BMS_BLKMEM *blkmem, SCIP_ROW *row, SCIP_SIDETYPE side, SCIP_Real oldval, SCIP_Real newval)
 
SCIP_RETCODE SCIPeventFree (SCIP_EVENT **event, BMS_BLKMEM *blkmem)
 
static void eventDisable (SCIP_EVENT *event)
 
SCIP_EVENTTYPE SCIPeventGetType (SCIP_EVENT *event)
 
SCIP_RETCODE SCIPeventChgType (SCIP_EVENT *event, SCIP_EVENTTYPE eventtype)
 
SCIP_VARSCIPeventGetVar (SCIP_EVENT *event)
 
SCIP_RETCODE SCIPeventChgVar (SCIP_EVENT *event, SCIP_VAR *var)
 
SCIP_Real SCIPeventGetOldobj (SCIP_EVENT *event)
 
SCIP_Real SCIPeventGetNewobj (SCIP_EVENT *event)
 
SCIP_Real SCIPeventGetOldbound (SCIP_EVENT *event)
 
SCIP_Real SCIPeventGetNewbound (SCIP_EVENT *event)
 
SCIP_NODESCIPeventGetNode (SCIP_EVENT *event)
 
SCIP_RETCODE SCIPeventChgNode (SCIP_EVENT *event, SCIP_NODE *node)
 
SCIP_SOLSCIPeventGetSol (SCIP_EVENT *event)
 
SCIP_RETCODE SCIPeventChgSol (SCIP_EVENT *event, SCIP_SOL *sol)
 
SCIP_Real SCIPeventGetHoleLeft (SCIP_EVENT *event)
 
SCIP_Real SCIPeventGetHoleRight (SCIP_EVENT *event)
 
SCIP_ROWSCIPeventGetRow (SCIP_EVENT *event)
 
SCIP_COLSCIPeventGetRowCol (SCIP_EVENT *event)
 
SCIP_Real SCIPeventGetRowOldCoefVal (SCIP_EVENT *event)
 
SCIP_Real SCIPeventGetRowNewCoefVal (SCIP_EVENT *event)
 
SCIP_Real SCIPeventGetRowOldConstVal (SCIP_EVENT *event)
 
SCIP_Real SCIPeventGetRowNewConstVal (SCIP_EVENT *event)
 
SCIP_SIDETYPE SCIPeventGetRowSide (SCIP_EVENT *event)
 
SCIP_Real SCIPeventGetRowOldSideVal (SCIP_EVENT *event)
 
SCIP_Real SCIPeventGetRowNewSideVal (SCIP_EVENT *event)
 
SCIP_RETCODE SCIPeventProcess (SCIP_EVENT *event, SCIP_SET *set, SCIP_PRIMAL *primal, SCIP_LP *lp, SCIP_BRANCHCAND *branchcand, SCIP_EVENTFILTER *eventfilter)
 
static SCIP_RETCODE eventfilterEnsureMem (SCIP_EVENTFILTER *eventfilter, BMS_BLKMEM *blkmem, SCIP_SET *set, int num)
 
SCIP_RETCODE SCIPeventfilterCreate (SCIP_EVENTFILTER **eventfilter, BMS_BLKMEM *blkmem)
 
SCIP_RETCODE SCIPeventfilterFree (SCIP_EVENTFILTER **eventfilter, BMS_BLKMEM *blkmem, SCIP_SET *set)
 
SCIP_RETCODE SCIPeventfilterAdd (SCIP_EVENTFILTER *eventfilter, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int *filterpos)
 
static int eventfilterSearch (SCIP_EVENTFILTER *const eventfilter, SCIP_EVENTTYPE const eventtype, SCIP_EVENTHDLR *const eventhdlr, SCIP_EVENTDATA *const eventdata)
 
SCIP_RETCODE SCIPeventfilterDel (SCIP_EVENTFILTER *eventfilter, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_EVENTTYPE eventtype, SCIP_EVENTHDLR *eventhdlr, SCIP_EVENTDATA *eventdata, int filterpos)
 
static void eventfilterDelayUpdates (SCIP_EVENTFILTER *eventfilter)
 
static void eventfilterProcessUpdates (SCIP_EVENTFILTER *eventfilter)
 
SCIP_RETCODE SCIPeventfilterProcess (SCIP_EVENTFILTER *eventfilter, SCIP_SET *set, SCIP_EVENT *event)
 
static SCIP_RETCODE eventqueueEnsureEventsMem (SCIP_EVENTQUEUE *eventqueue, SCIP_SET *set, int num)
 
SCIP_RETCODE SCIPeventqueueCreate (SCIP_EVENTQUEUE **eventqueue)
 
SCIP_RETCODE SCIPeventqueueFree (SCIP_EVENTQUEUE **eventqueue)
 
static SCIP_RETCODE eventqueueAppend (SCIP_EVENTQUEUE *eventqueue, SCIP_SET *set, SCIP_EVENT **event)
 
SCIP_RETCODE SCIPeventqueueAdd (SCIP_EVENTQUEUE *eventqueue, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_PRIMAL *primal, SCIP_LP *lp, SCIP_BRANCHCAND *branchcand, SCIP_EVENTFILTER *eventfilter, SCIP_EVENT **event)
 
SCIP_RETCODE SCIPeventqueueDelay (SCIP_EVENTQUEUE *eventqueue)
 
SCIP_RETCODE SCIPeventqueueProcess (SCIP_EVENTQUEUE *eventqueue, BMS_BLKMEM *blkmem, SCIP_SET *set, SCIP_PRIMAL *primal, SCIP_LP *lp, SCIP_BRANCHCAND *branchcand, SCIP_EVENTFILTER *eventfilter)
 
SCIP_Bool SCIPeventqueueIsDelayed (SCIP_EVENTQUEUE *eventqueue)
 

Function Documentation

SCIP_RETCODE SCIPeventhdlrCopyInclude ( SCIP_EVENTHDLR eventhdlr,
SCIP_SET set 
)

copies the given event handler to a new scip

Parameters
eventhdlrevent handler
setSCIP_SET of SCIP to copy to

Definition at line 45 of file event.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIPdebugMessage, and SCIPeventhdlrGetName().

Referenced by SCIPsetCopyPlugins().

SCIP_RETCODE SCIPeventhdlrCreate ( SCIP_EVENTHDLR **  eventhdlr,
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 
)

creates an event handler

Parameters
eventhdlrpointer to event handler data structure
namename of event handler
descdescription of event handler
eventhdlrdataevent handler data

Definition at line 64 of file event.c.

References BMSallocMemory, BMSduplicateMemoryArray, FALSE, NULL, SCIP_ALLOC, SCIP_CALL, SCIP_CLOCKTYPE_DEFAULT, SCIP_OKAY, and SCIPclockCreate().

Referenced by SCIPincludeEventhdlr(), SCIPincludeEventhdlrBasic(), SCIPnlpInclude(), and SCIPreoptCreate().

SCIP_RETCODE SCIPeventhdlrFree ( SCIP_EVENTHDLR **  eventhdlr,
SCIP_SET set 
)

calls destructor and frees memory of event handler

Parameters
eventhdlrpointer to event handler data structure
setglobal SCIP settings

Definition at line 106 of file event.c.

References BMSfreeMemory, BMSfreeMemoryArray, NULL, SCIP_CALL, SCIP_OKAY, and SCIPclockFree().

SCIP_RETCODE SCIPeventhdlrInit ( SCIP_EVENTHDLR eventhdlr,
SCIP_SET set 
)

initializes event handler

Parameters
eventhdlrevent handler for this event
setglobal SCIP settings

Definition at line 134 of file event.c.

References SCIP_Eventhdlr::eventtime, SCIP_Eventhdlr::initialized, SCIP_Eventhdlr::name, NULL, SCIP_CALL, SCIP_INVALIDCALL, SCIP_OKAY, SCIPclockReset(), SCIPclockStart(), SCIPclockStop(), SCIPerrorMessage, SCIP_Eventhdlr::setuptime, and TRUE.

Referenced by SCIPsetInitPlugins().

SCIP_RETCODE SCIPeventhdlrExit ( SCIP_EVENTHDLR eventhdlr,
SCIP_SET set 
)

calls exit method of event handler

Parameters
eventhdlrevent handler for this event
setglobal SCIP settings

Definition at line 170 of file event.c.

References FALSE, SCIP_Eventhdlr::initialized, SCIP_Eventhdlr::name, NULL, SCIP_CALL, SCIP_INVALIDCALL, SCIP_OKAY, SCIPclockStart(), SCIPclockStop(), SCIPerrorMessage, and SCIP_Eventhdlr::setuptime.

Referenced by SCIPsetExitPlugins().

SCIP_RETCODE SCIPeventhdlrInitsol ( SCIP_EVENTHDLR eventhdlr,
SCIP_SET set 
)

informs event handler that the branch and bound process is being started

Parameters
eventhdlrevent handler
setglobal SCIP settings

Definition at line 200 of file event.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIPclockStart(), SCIPclockStop(), and SCIP_Eventhdlr::setuptime.

Referenced by SCIPsetInitsolPlugins().

SCIP_RETCODE SCIPeventhdlrExitsol ( SCIP_EVENTHDLR eventhdlr,
SCIP_SET set 
)

informs event handler that the branch and bound process data is being freed

Parameters
eventhdlrevent handler
setglobal SCIP settings

Definition at line 224 of file event.c.

References NULL, SCIP_CALL, SCIP_OKAY, SCIPclockStart(), SCIPclockStop(), and SCIP_Eventhdlr::setuptime.

Referenced by SCIPsetExitsolPlugins().

SCIP_RETCODE SCIPeventhdlrExec ( SCIP_EVENTHDLR eventhdlr,
SCIP_SET set,
SCIP_EVENT event,
SCIP_EVENTDATA eventdata 
)

calls execution method of event handler

Parameters
eventhdlrevent handler
setglobal SCIP settings
eventevent to call event handler with
eventdatauser data for the issued event

Definition at line 248 of file event.c.

References SCIP_Eventhdlr::eventtime, SCIP_Event::eventtype, SCIP_Eventhdlr::name, NULL, SCIP_CALL, SCIP_OKAY, SCIPclockStart(), SCIPclockStop(), and SCIPdebugMessage.

Referenced by SCIPeventfilterProcess().

const char* SCIPeventhdlrGetName ( SCIP_EVENTHDLR eventhdlr)
void SCIPeventhdlrSetData ( SCIP_EVENTHDLR eventhdlr,
SCIP_EVENTHDLRDATA eventhdlrdata 
)

sets user data of event handler; user has to free old data in advance!

Parameters
eventhdlrevent handler
eventhdlrdatanew event handler user data

Definition at line 298 of file event.c.

References SCIP_Eventhdlr::eventhdlrdata, and NULL.

Referenced by SCIP_DECL_EVENTFREE().

void SCIPeventhdlrSetCopy ( SCIP_EVENTHDLR eventhdlr,
SCIP_DECL_EVENTCOPY((*eventcopy))   
)

sets copy callback for all events of this event handler

Parameters
eventhdlrevent handler

Definition at line 309 of file event.c.

References NULL.

Referenced by SCIPsetEventhdlrCopy().

void SCIPeventhdlrSetFree ( SCIP_EVENTHDLR eventhdlr,
SCIP_DECL_EVENTFREE((*eventfree))   
)

sets destructor callback of this event handler

Parameters
eventhdlrevent handler

Definition at line 320 of file event.c.

References NULL.

Referenced by SCIPsetEventhdlrFree().

void SCIPeventhdlrSetInit ( SCIP_EVENTHDLR eventhdlr,
SCIP_DECL_EVENTINIT((*eventinit))   
)

sets initialization callback of this event handler

Parameters
eventhdlrevent handler

Definition at line 331 of file event.c.

References NULL.

Referenced by SCIPsetEventhdlrInit().

void SCIPeventhdlrSetExit ( SCIP_EVENTHDLR eventhdlr,
SCIP_DECL_EVENTEXIT((*eventexit))   
)

sets deinitialization callback of this event handler

Parameters
eventhdlrevent handler

Definition at line 342 of file event.c.

References NULL.

Referenced by SCIPsetEventhdlrExit().

void SCIPeventhdlrSetInitsol ( SCIP_EVENTHDLR eventhdlr,
SCIP_DECL_EVENTINITSOL((*eventinitsol))   
)

sets solving process initialization callback of this event handler

Parameters
eventhdlrevent handler

Definition at line 353 of file event.c.

References NULL.

Referenced by SCIPsetEventhdlrInitsol().

void SCIPeventhdlrSetExitsol ( SCIP_EVENTHDLR eventhdlr,
SCIP_DECL_EVENTEXITSOL((*eventexitsol))   
)

sets solving process deinitialization callback of this event handler

Parameters
eventhdlrevent handler

Definition at line 364 of file event.c.

References NULL.

Referenced by SCIPsetEventhdlrExitsol().

void SCIPeventhdlrSetDelete ( SCIP_EVENTHDLR eventhdlr,
SCIP_DECL_EVENTDELETE((*eventdelete))   
)

sets callback to free specific event data

Parameters
eventhdlrevent handler

Definition at line 375 of file event.c.

References NULL.

Referenced by SCIPsetEventhdlrDelete().

SCIP_Bool SCIPeventhdlrIsInitialized ( SCIP_EVENTHDLR eventhdlr)

is event handler initialized?

Parameters
eventhdlrevent handler

Definition at line 386 of file event.c.

References SCIP_Eventhdlr::initialized, and NULL.

Referenced by SCIPsetFindCompr().

void SCIPeventhdlrEnableOrDisableClocks ( SCIP_EVENTHDLR eventhdlr,
SCIP_Bool  enable 
)

enables or disables all clocks of eventhdlr, depending on the value of the flag

Parameters
eventhdlrthe event handler for which all clocks should be enabled or disabled
enableshould the clocks of the event handler be enabled?

Definition at line 396 of file event.c.

References SCIP_Eventhdlr::eventtime, NULL, SCIPclockEnableOrDisable(), and SCIP_Eventhdlr::setuptime.

Referenced by SCIPsetSetReoptimizationParams().

SCIP_Real SCIPeventhdlrGetSetupTime ( SCIP_EVENTHDLR eventhdlr)

gets time in seconds used in this event handler for setting up for next stages

Parameters
eventhdlrevent handler

Definition at line 408 of file event.c.

References NULL, SCIPclockGetTime(), and SCIP_Eventhdlr::setuptime.

SCIP_Real SCIPeventhdlrGetTime ( SCIP_EVENTHDLR eventhdlr)

gets time in seconds used in this event handler, this measurement is currently disabled so this method will return 0, define TIMEEVENTEXEC in the beginning of this file to enable

Parameters
eventhdlrevent handler

Definition at line 420 of file event.c.

References SCIP_Eventhdlr::eventtime, NULL, and SCIPclockGetTime().

SCIP_RETCODE SCIPeventCreateVarAdded ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var 
)

creates an event for an addition of a variable to the problem

Parameters
eventpointer to store the event
blkmemblock memory
varvariable that was added to the problem

Definition at line 436 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_VARADDED, and SCIP_OKAY.

Referenced by SCIPprobAddVar().

SCIP_RETCODE SCIPeventCreateVarDeleted ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var 
)

creates an event for a deletion of a variable from the problem

Parameters
eventpointer to store the event
blkmemblock memory
varvariable that is to be deleted from the problem

Definition at line 454 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_VARDELETED, and SCIP_OKAY.

Referenced by SCIPprobDelVar().

SCIP_RETCODE SCIPeventCreateVarFixed ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var 
)

creates an event for a fixing of a variable

Parameters
eventpointer to store the event
blkmemblock memory
varvariable that was fixed

Definition at line 472 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_VARFIXED, SCIP_OKAY, SCIP_VARSTATUS_AGGREGATED, SCIP_VARSTATUS_FIXED, SCIP_VARSTATUS_MULTAGGR, SCIP_VARSTATUS_NEGATED, and SCIPvarGetStatus().

Referenced by varEventVarFixed().

SCIP_RETCODE SCIPeventCreateVarUnlocked ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var 
)

creates an event for a change in the number of locks of a variable down to zero or one

Parameters
eventpointer to store the event
blkmemblock memory
varvariable that changed the number of locks

Definition at line 494 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_VARUNLOCKED, SCIP_OKAY, SCIP_VARSTATUS_COLUMN, SCIP_VARSTATUS_FIXED, SCIP_VARSTATUS_LOOSE, and SCIPvarGetStatus().

Referenced by varEventVarUnlocked().

SCIP_RETCODE SCIPeventCreateObjChanged ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var,
SCIP_Real  oldobj,
SCIP_Real  newobj 
)

creates an event for a change in the objective value of a variable

Parameters
eventpointer to store the event
blkmemblock memory
varvariable whose objective value changed
oldobjold objective value before value changed
newobjnew objective value after value changed

Definition at line 515 of file event.c.

References BMSallocBlockMemory, SCIP_Var::data, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_OBJCHANGED, and SCIP_OKAY.

Referenced by varEventObjChanged().

SCIP_RETCODE SCIPeventCreateGlbChanged ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var,
SCIP_Real  oldbound,
SCIP_Real  newbound 
)

creates an event for a change in the global lower bound of a variable

Parameters
eventpointer to store the event
blkmemblock memory
varvariable whose bound changed
oldboundold bound before bound changed
newboundnew bound after bound changed

Definition at line 538 of file event.c.

References BMSallocBlockMemory, SCIP_Var::data, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_GLBCHANGED, and SCIP_OKAY.

Referenced by varEventGlbChanged().

SCIP_RETCODE SCIPeventCreateGubChanged ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var,
SCIP_Real  oldbound,
SCIP_Real  newbound 
)

creates an event for a change in the global upper bound of a variable

Parameters
eventpointer to store the event
blkmemblock memory
varvariable whose bound changed
oldboundold bound before bound changed
newboundnew bound after bound changed

Definition at line 561 of file event.c.

References BMSallocBlockMemory, SCIP_Var::data, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_GUBCHANGED, and SCIP_OKAY.

Referenced by varEventGubChanged().

SCIP_RETCODE SCIPeventCreateLbChanged ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var,
SCIP_Real  oldbound,
SCIP_Real  newbound 
)

creates an event for a change in the lower bound of a variable

Parameters
eventpointer to store the event
blkmemblock memory
varvariable whose bound changed
oldboundold bound before bound changed
newboundnew bound after bound changed

Definition at line 584 of file event.c.

References BMSallocBlockMemory, SCIP_Var::data, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_LBRELAXED, SCIP_EVENTTYPE_LBTIGHTENED, and SCIP_OKAY.

Referenced by varEventLbChanged().

SCIP_RETCODE SCIPeventCreateUbChanged ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var,
SCIP_Real  oldbound,
SCIP_Real  newbound 
)

creates an event for a change in the upper bound of a variable

Parameters
eventpointer to store the event
blkmemblock memory
varvariable whose bound changed
oldboundold bound before bound changed
newboundnew bound after bound changed

Definition at line 610 of file event.c.

References BMSallocBlockMemory, SCIP_Var::data, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_UBRELAXED, SCIP_EVENTTYPE_UBTIGHTENED, and SCIP_OKAY.

Referenced by varEventUbChanged().

SCIP_RETCODE SCIPeventCreateGholeAdded ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var,
SCIP_Real  left,
SCIP_Real  right 
)

creates an event for an addition of a domain hole to a variable

Parameters
eventpointer to store the event
blkmemblock memory
varvariable whose bound changed
leftleft bound of open interval in new hole
rightright bound of open interval in new hole

Definition at line 636 of file event.c.

References BMSallocBlockMemory, SCIP_Var::data, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_GHOLEADDED, and SCIP_OKAY.

Referenced by varEventGholeAdded().

SCIP_RETCODE SCIPeventCreateGholeRemoved ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var,
SCIP_Real  left,
SCIP_Real  right 
)

creates an event for removing a domain hole of a variable

Parameters
eventpointer to store the event
blkmemblock memory
varvariable whose bound changed
leftleft bound of open interval in hole
rightright bound of open interval in hole

Definition at line 658 of file event.c.

References BMSallocBlockMemory, SCIP_Var::data, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_GHOLEREMOVED, and SCIP_OKAY.

SCIP_RETCODE SCIPeventCreateLholeAdded ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var,
SCIP_Real  left,
SCIP_Real  right 
)

creates an event for an addition of a domain hole to a variable

Parameters
eventpointer to store the event
blkmemblock memory
varvariable whose bound changed
leftleft bound of open interval in new hole
rightright bound of open interval in new hole

Definition at line 680 of file event.c.

References BMSallocBlockMemory, SCIP_Var::data, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_LHOLEADDED, and SCIP_OKAY.

SCIP_RETCODE SCIPeventCreateLholeRemoved ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var,
SCIP_Real  left,
SCIP_Real  right 
)

creates an event for removing a domain hole of a variable

Parameters
eventpointer to store the event
blkmemblock memory
varvariable whose bound changed
leftleft bound of open interval in hole
rightright bound of open interval in hole

Definition at line 702 of file event.c.

References BMSallocBlockMemory, SCIP_Var::data, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_LHOLEREMOVED, and SCIP_OKAY.

SCIP_RETCODE SCIPeventCreateImplAdded ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_VAR var 
)

creates an event for an addition to the variable's implications list, clique or variable bounds information

Parameters
eventpointer to store the event
blkmemblock memory
varvariable that was fixed

Definition at line 724 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_IMPLADDED, SCIP_OKAY, SCIP_VARSTATUS_COLUMN, SCIP_VARSTATUS_LOOSE, and SCIPvarGetStatus().

Referenced by SCIPcliquetableCleanup(), and varEventImplAdded().

SCIP_RETCODE SCIPeventCreateRowAddedSepa ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_ROW row 
)

creates an event for the addition of a linear row to the separation storage

Parameters
eventpointer to store the event
blkmemblock memory
rowrow that was added to the separation storage

Definition at line 743 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_ROWADDEDSEPA, and SCIP_OKAY.

Referenced by sepastoreAddCut().

SCIP_RETCODE SCIPeventCreateRowDeletedSepa ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_ROW row 
)

creates an event for the deletion of a linear row from the separation storage

Parameters
eventpointer to store the event
blkmemblock memory
rowrow that was deleted from the separation storage

Definition at line 762 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_ROWDELETEDSEPA, and SCIP_OKAY.

Referenced by SCIPsepastoreClearCuts(), sepastoreAddCut(), and sepastoreDelCut().

SCIP_RETCODE SCIPeventCreateRowAddedLP ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_ROW row 
)

creates an event for the addition of a linear row to the LP

Parameters
eventpointer to store the event
blkmemblock memory
rowrow that was added to the LP

Definition at line 781 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_ROWADDEDLP, and SCIP_OKAY.

Referenced by SCIPlpAddRow().

SCIP_RETCODE SCIPeventCreateRowDeletedLP ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_ROW row 
)

creates an event for the deletion of a linear row from the LP

Parameters
eventpointer to store the event
blkmemblock memory
rowrow that was deleted from the LP

Definition at line 800 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_ROWDELETEDLP, and SCIP_OKAY.

Referenced by lpDelRowset(), and SCIPlpShrinkRows().

SCIP_RETCODE SCIPeventCreateRowCoefChanged ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_ROW row,
SCIP_COL col,
SCIP_Real  oldval,
SCIP_Real  newval 
)

creates an event for the change of a coefficient in a linear row

Parameters
eventpointer to store the event
blkmemblock memory
rowrow in which a coefficient changed
colcolumn which coefficient changed
oldvalold value of coefficient
newvalnew value of coefficient

Definition at line 819 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_ROWCOEFCHANGED, and SCIP_OKAY.

Referenced by rowEventCoefChanged().

SCIP_RETCODE SCIPeventCreateRowConstChanged ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_ROW row,
SCIP_Real  oldval,
SCIP_Real  newval 
)

creates an event for the change of a constant in a linear row

Parameters
eventpointer to store the event
blkmemblock memory
rowrow in which the constant changed
oldvalold value of constant
newvalnew value of constant

Definition at line 844 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_ROWCONSTCHANGED, and SCIP_OKAY.

Referenced by rowEventConstantChanged().

SCIP_RETCODE SCIPeventCreateRowSideChanged ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem,
SCIP_ROW row,
SCIP_SIDETYPE  side,
SCIP_Real  oldval,
SCIP_Real  newval 
)

creates an event for the change of a side of a linear row

Parameters
eventpointer to store the event
blkmemblock memory
rowrow which side has changed
sidewhich side has changed
oldvalold value of side
newvalnew value of side

Definition at line 867 of file event.c.

References BMSallocBlockMemory, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_ROWSIDECHANGED, and SCIP_OKAY.

Referenced by rowEventSideChanged().

SCIP_RETCODE SCIPeventFree ( SCIP_EVENT **  event,
BMS_BLKMEM blkmem 
)

frees an event

Parameters
eventevent to free
blkmemblock memory buffer

Definition at line 892 of file event.c.

References BMSfreeBlockMemory, NULL, and SCIP_OKAY.

Referenced by SCIPeventqueueAdd(), and SCIPeventqueueProcess().

static void eventDisable ( SCIP_EVENT event)
static

disables an event

Parameters
eventevent to disable

Definition at line 907 of file event.c.

References NULL, and SCIP_EVENTTYPE_DISABLED.

Referenced by SCIPeventqueueAdd().

SCIP_EVENTTYPE SCIPeventGetType ( SCIP_EVENT event)

gets type of event

Parameters
eventevent

Definition at line 917 of file event.c.

References NULL.

Referenced by SCIP_DECL_CONSGETNVARS(), and SCIP_DECL_EVENTEXEC().

SCIP_RETCODE SCIPeventChgType ( SCIP_EVENT event,
SCIP_EVENTTYPE  eventtype 
)

sets type of event

Parameters
eventevent
eventtypenew event type

Definition at line 927 of file event.c.

References NULL, and SCIP_OKAY.

Referenced by presolveRound(), priceAndCutLoop(), primalAddSol(), SCIPsolveCIP(), and solveNodeInitialLP().

SCIP_Real SCIPeventGetOldobj ( SCIP_EVENT event)

gets old objective value for an objective value change event

Parameters
eventevent

Definition at line 1062 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_OBJCHANGED, SCIP_INVALID, SCIPABORT, and SCIPerrorMessage.

Referenced by SCIP_DECL_EVENTEXEC().

SCIP_Real SCIPeventGetNewobj ( SCIP_EVENT event)

gets new objective value for an objective value change event

Parameters
eventevent

Definition at line 1079 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_OBJCHANGED, SCIP_INVALID, SCIPABORT, and SCIPerrorMessage.

Referenced by SCIP_DECL_EVENTEXEC().

SCIP_Real SCIPeventGetOldbound ( SCIP_EVENT event)
SCIP_Real SCIPeventGetNewbound ( SCIP_EVENT event)
SCIP_NODE* SCIPeventGetNode ( SCIP_EVENT event)

gets node for a node or LP event

Parameters
eventevent

Definition at line 1144 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_LPEVENT, SCIP_EVENTTYPE_NODEEVENT, SCIPABORT, and SCIPerrorMessage.

SCIP_RETCODE SCIPeventChgNode ( SCIP_EVENT event,
SCIP_NODE node 
)

sets node for a node or LP event

Parameters
eventevent
nodenew node

Definition at line 1161 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_LPEVENT, SCIP_EVENTTYPE_NODEEVENT, SCIP_INVALIDDATA, SCIP_OKAY, SCIPABORT, and SCIPerrorMessage.

Referenced by priceAndCutLoop(), SCIPsolveCIP(), and solveNodeInitialLP().

SCIP_SOL* SCIPeventGetSol ( SCIP_EVENT event)

gets solution for a primal solution event

Parameters
eventevent

Definition at line 1181 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_SOLEVENT, SCIPABORT, and SCIPerrorMessage.

Referenced by SCIP_DECL_EVENTEXEC().

SCIP_RETCODE SCIPeventChgSol ( SCIP_EVENT event,
SCIP_SOL sol 
)

sets solution for a primal solution event

Parameters
eventevent
solnew primal solution

Definition at line 1198 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_SOLEVENT, SCIP_INVALIDDATA, SCIP_OKAY, SCIPABORT, and SCIPerrorMessage.

Referenced by primalAddSol().

SCIP_Real SCIPeventGetHoleLeft ( SCIP_EVENT event)

gets the left bound of open interval in the hole

Parameters
eventevent

Definition at line 1218 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_HOLECHANGED, SCIP_INVALID, SCIPABORT, and SCIPerrorMessage.

SCIP_Real SCIPeventGetHoleRight ( SCIP_EVENT event)

gets the right bound of open interval in the hole

Parameters
eventevent

Definition at line 1235 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_HOLECHANGED, SCIP_INVALID, SCIPABORT, and SCIPerrorMessage.

SCIP_COL* SCIPeventGetRowCol ( SCIP_EVENT event)

gets column for a row change coefficient event

Parameters
eventevent

Definition at line 1282 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_ROWCOEFCHANGED, SCIPABORT, and SCIPerrorMessage.

SCIP_Real SCIPeventGetRowOldCoefVal ( SCIP_EVENT event)

gets old coefficient value for a row change coefficient event

Parameters
eventevent

Definition at line 1299 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_ROWCOEFCHANGED, SCIP_INVALID, SCIPABORT, and SCIPerrorMessage.

SCIP_Real SCIPeventGetRowNewCoefVal ( SCIP_EVENT event)

gets new coefficient value for a row change coefficient event

Parameters
eventevent

Definition at line 1316 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_ROWCOEFCHANGED, SCIP_INVALID, SCIPABORT, and SCIPerrorMessage.

SCIP_Real SCIPeventGetRowOldConstVal ( SCIP_EVENT event)

gets old constant value for a row change constant event

Parameters
eventevent

Definition at line 1333 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_ROWCONSTCHANGED, SCIP_INVALID, SCIPABORT, and SCIPerrorMessage.

SCIP_Real SCIPeventGetRowNewConstVal ( SCIP_EVENT event)

gets new constant value for a row change constant event

Parameters
eventevent

Definition at line 1350 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_ROWCONSTCHANGED, SCIP_INVALID, SCIPABORT, and SCIPerrorMessage.

SCIP_SIDETYPE SCIPeventGetRowSide ( SCIP_EVENT event)

gets side for a row change side event

Parameters
eventevent

Definition at line 1367 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_ROWSIDECHANGED, SCIP_SIDETYPE_LEFT, SCIPABORT, and SCIPerrorMessage.

SCIP_Real SCIPeventGetRowOldSideVal ( SCIP_EVENT event)

gets old side value for a row change side event

Parameters
eventevent

Definition at line 1384 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_ROWSIDECHANGED, SCIP_INVALID, SCIPABORT, and SCIPerrorMessage.

SCIP_Real SCIPeventGetRowNewSideVal ( SCIP_EVENT event)

gets new side value for a row change side event

Parameters
eventevent

Definition at line 1401 of file event.c.

References SCIP_Event::eventtype, NULL, SCIP_EVENTTYPE_ROWSIDECHANGED, SCIP_INVALID, SCIPABORT, and SCIPerrorMessage.

SCIP_RETCODE SCIPeventProcess ( SCIP_EVENT event,
SCIP_SET set,
SCIP_PRIMAL primal,
SCIP_LP lp,
SCIP_BRANCHCAND branchcand,
SCIP_EVENTFILTER eventfilter 
)

processes event by calling the appropriate event handlers

Parameters
eventevent
setglobal SCIP settings
primalprimal data; only needed for objchanged events, or NULL
lpcurrent LP data; only needed for obj/boundchanged events, or NULL
branchcandbranching candidate storage; only needed for bound change events, or NULL
eventfilterevent filter for global events; not needed for variable specific events

Definition at line 1418 of file event.c.

References SCIP_Event::data, SCIP_Var::data, SCIP_Event::eventbdchg, SCIP_Var::eventfilter, SCIP_Event::eventobjchg, SCIP_Var::eventqueueimpl, SCIP_Var::eventqueueindexlb, SCIP_Var::eventqueueindexobj, SCIP_Var::eventqueueindexub, SCIP_Event::eventtype, SCIP_EventBdChg::newbound, SCIP_EventObjChg::newobj, NULL, SCIP_EventBdChg::oldbound, SCIP_EventObjChg::oldobj, SCIP_CALL, SCIP_EVENTTYPE_BESTSOLFOUND, SCIP_EVENTTYPE_BOUNDCHANGED, SCIP_EVENTTYPE_DISABLED, SCIP_EVENTTYPE_FIRSTLPSOLVED, SCIP_EVENTTYPE_GHOLEADDED, SCIP_EVENTTYPE_GHOLEREMOVED, SCIP_EVENTTYPE_GLBCHANGED, SCIP_EVENTTYPE_GUBCHANGED, SCIP_EVENTTYPE_IMPLADDED, SCIP_EVENTTYPE_LBRELAXED, SCIP_EVENTTYPE_LBTIGHTENED, SCIP_EVENTTYPE_LHOLEADDED, SCIP_EVENTTYPE_LHOLEREMOVED, SCIP_EVENTTYPE_LPSOLVED, SCIP_EVENTTYPE_NODEBRANCHED, SCIP_EVENTTYPE_NODEFEASIBLE, SCIP_EVENTTYPE_NODEFOCUSED, SCIP_EVENTTYPE_NODEINFEASIBLE, SCIP_EVENTTYPE_OBJCHANGED, SCIP_EVENTTYPE_POORSOLFOUND, SCIP_EVENTTYPE_PRESOLVEROUND, SCIP_EVENTTYPE_ROWADDEDLP, SCIP_EVENTTYPE_ROWADDEDSEPA, SCIP_EVENTTYPE_ROWCOEFCHANGED, SCIP_EVENTTYPE_ROWCONSTCHANGED, SCIP_EVENTTYPE_ROWDELETEDLP, SCIP_EVENTTYPE_ROWDELETEDSEPA, SCIP_EVENTTYPE_ROWSIDECHANGED, SCIP_EVENTTYPE_UBRELAXED, SCIP_EVENTTYPE_UBTIGHTENED, SCIP_EVENTTYPE_VARADDED, SCIP_EVENTTYPE_VARDELETED, SCIP_EVENTTYPE_VARFIXED, SCIP_EVENTTYPE_VARUNLOCKED, SCIP_INVALIDDATA, SCIP_OKAY, SCIP_VARSTATUS_COLUMN, SCIP_VARSTATUS_LOOSE, SCIPbranchcandUpdateVar(), SCIPcolChgLb(), SCIPcolChgObj(), SCIPcolChgUb(), SCIPdebugMessage, SCIPerrorMessage, SCIPeventfilterProcess(), SCIPlpUpdateVarLb(), SCIPlpUpdateVarLbGlobal(), SCIPlpUpdateVarObj(), SCIPlpUpdateVarUb(), SCIPlpUpdateVarUbGlobal(), SCIPprimalUpdateVarObj(), SCIPvarGetCol(), SCIPvarGetProbindex(), and SCIPvarGetStatus().

Referenced by presolveRound(), priceAndCutLoop(), primalAddSol(), SCIPeventqueueAdd(), SCIPeventqueueProcess(), SCIPsolveCIP(), and solveNodeInitialLP().

static SCIP_RETCODE eventfilterEnsureMem ( SCIP_EVENTFILTER eventfilter,
BMS_BLKMEM blkmem,
SCIP_SET set,
int  num 
)
static

resizes eventfilter arrays to be able to store at least num entries

Parameters
eventfilterevent filter
blkmemblock memory buffer
setglobal SCIP settings
numminimal number of node slots in array

Definition at line 1622 of file event.c.

References BMSreallocBlockMemoryArray, SCIP_EventFilter::eventdata, SCIP_EventFilter::eventhdlrs, SCIP_EventFilter::eventtypes, SCIP_EventFilter::nextpos, NULL, SCIP_ALLOC, SCIP_OKAY, SCIPsetCalcMemGrowSize(), and SCIP_EventFilter::size.

Referenced by SCIPeventfilterAdd().

SCIP_RETCODE SCIPeventfilterCreate ( SCIP_EVENTFILTER **  eventfilter,
BMS_BLKMEM blkmem 
)

creates an event filter

Parameters
eventfilterpointer to store the event filter
blkmemblock memory buffer

Definition at line 1650 of file event.c.

References BMSallocBlockMemory, FALSE, NULL, SCIP_ALLOC, SCIP_EVENTTYPE_DISABLED, and SCIP_OKAY.

Referenced by SCIProwCreate(), SCIPtransformProb(), SCIPvarCreateTransformed(), SCIPvarNegate(), and SCIPvarParseTransformed().

SCIP_RETCODE SCIPeventfilterFree ( SCIP_EVENTFILTER **  eventfilter,
BMS_BLKMEM blkmem,
SCIP_SET set 
)

frees an event filter and the associated event data entries

Parameters
eventfilterpointer to store the event filter
blkmemblock memory buffer
setglobal SCIP settings

Definition at line 1675 of file event.c.

References BMSfreeBlockMemory, BMSfreeBlockMemoryArrayNull, NULL, SCIP_CALL, SCIP_EVENTTYPE_DISABLED, and SCIP_OKAY.

Referenced by freeTransform(), SCIProwFree(), and varFree().

SCIP_RETCODE SCIPeventfilterAdd ( SCIP_EVENTFILTER eventfilter,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_EVENTTYPE  eventtype,
SCIP_EVENTHDLR eventhdlr,
SCIP_EVENTDATA eventdata,
int *  filterpos 
)

adds element to event filter

Parameters
eventfilterevent filter
blkmemblock memory buffer
setglobal SCIP settings
eventtypeevent type to catch
eventhdlrevent handler to call for the event processing
eventdataevent data to pass to the event handler for the event processing
filterpospointer to store position of event filter entry, or NULL

Definition at line 1715 of file event.c.

References SCIP_EventFilter::delayedeventmask, SCIP_EventFilter::delayupdates, SCIP_EventFilter::eventdata, eventfilterEnsureMem(), SCIP_EventFilter::eventhdlrs, SCIP_EventFilter::eventmask, SCIP_EventFilter::eventtypes, SCIP_EventFilter::firstfreepos, SCIP_EventFilter::len, SCIP_EventFilter::nextpos, NULL, SCIP_CALL, SCIP_EVENTTYPE_DISABLED, and SCIP_OKAY.

Referenced by SCIPcatchEvent(), SCIPnlpCreate(), SCIProwCatchEvent(), and SCIPvarCatchEvent().

static int eventfilterSearch ( SCIP_EVENTFILTER *const  eventfilter,
SCIP_EVENTTYPE const  eventtype,
SCIP_EVENTHDLR *const  eventhdlr,
SCIP_EVENTDATA *const  eventdata 
)
static

linear search for the given entry in event filter

Parameters
eventfilterevent filter
eventtypeevent type
eventhdlrevent handler to call for the event processing
eventdataevent data to pass to the event handler for the event processing

Definition at line 1782 of file event.c.

References SCIP_EventFilter::eventdata, SCIP_EventFilter::eventhdlrs, SCIP_EventFilter::eventtypes, SCIP_EventFilter::len, SCIP_EventFilter::nextpos, NULL, and SCIP_EVENTTYPE_DISABLED.

Referenced by SCIPeventfilterDel().

SCIP_RETCODE SCIPeventfilterDel ( SCIP_EVENTFILTER eventfilter,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_EVENTTYPE  eventtype,
SCIP_EVENTHDLR eventhdlr,
SCIP_EVENTDATA eventdata,
int  filterpos 
)

deletes element from event filter

Parameters
eventfilterevent filter
blkmemblock memory buffer
setglobal SCIP settings
eventtypeevent type
eventhdlrevent handler to call for the event processing
eventdataevent data to pass to the event handler for the event processing
filterposposition of event filter entry, or -1 if unknown

Definition at line 1808 of file event.c.

References SCIP_EventFilter::delayupdates, SCIP_EventFilter::eventdata, eventfilterSearch(), SCIP_EventFilter::eventhdlrs, SCIP_EventFilter::eventtypes, SCIP_EventFilter::firstdeletedpos, SCIP_EventFilter::firstfreepos, SCIP_EventFilter::nextpos, NULL, SCIP_EVENTTYPE_DISABLED, SCIP_INVALIDDATA, SCIP_OKAY, and SCIPerrorMessage.

Referenced by SCIPdropEvent(), SCIPnlpFree(), SCIProwDropEvent(), and SCIPvarDropEvent().

static void eventfilterDelayUpdates ( SCIP_EVENTFILTER eventfilter)
static

makes the event filter to delay and buffer all updates until eventfilterProcessUpdates() is called

Parameters
eventfilterevent filter

Definition at line 1863 of file event.c.

References SCIP_EventFilter::delayedeventmask, SCIP_EventFilter::delayupdates, NULL, SCIP_EVENTTYPE_DISABLED, and TRUE.

Referenced by SCIPeventfilterProcess().

static void eventfilterProcessUpdates ( SCIP_EVENTFILTER eventfilter)
static
SCIP_RETCODE SCIPeventfilterProcess ( SCIP_EVENTFILTER eventfilter,
SCIP_SET set,
SCIP_EVENT event 
)

processes the event with all event handlers with matching filter setting

Parameters
eventfilterevent filter
setglobal SCIP settings
eventevent to process

Definition at line 1911 of file event.c.

References SCIP_EventFilter::eventdata, eventfilterDelayUpdates(), eventfilterProcessUpdates(), SCIP_EventFilter::eventhdlrs, SCIP_EventFilter::eventmask, SCIP_Event::eventtype, SCIP_EventFilter::eventtypes, FALSE, SCIP_EventFilter::len, NULL, SCIP_Bool, SCIP_CALL, SCIP_OKAY, SCIPdebugMessage, SCIPeventhdlrExec(), and TRUE.

Referenced by SCIPeventProcess().

static SCIP_RETCODE eventqueueEnsureEventsMem ( SCIP_EVENTQUEUE eventqueue,
SCIP_SET set,
int  num 
)
static

resizes events array to be able to store at least num entries

Parameters
eventqueueevent queue
setglobal SCIP settings
numminimal number of node slots in array

Definition at line 1978 of file event.c.

References BMSreallocMemoryArray, SCIP_EventQueue::events, SCIP_EventQueue::eventssize, NULL, SCIP_ALLOC, SCIP_OKAY, and SCIPsetCalcMemGrowSize().

Referenced by eventqueueAppend().

SCIP_RETCODE SCIPeventqueueCreate ( SCIP_EVENTQUEUE **  eventqueue)

creates an event queue

Parameters
eventqueuepointer to store the event queue

Definition at line 2001 of file event.c.

References BMSallocMemory, FALSE, NULL, SCIP_ALLOC, and SCIP_OKAY.

Referenced by SCIPtransformProb().

SCIP_RETCODE SCIPeventqueueFree ( SCIP_EVENTQUEUE **  eventqueue)

frees event queue; there must not be any unprocessed events in the queue!

Parameters
eventqueuepointer to the event queue

Definition at line 2017 of file event.c.

References BMSfreeMemory, BMSfreeMemoryArrayNull, NULL, and SCIP_OKAY.

Referenced by freeTransform().

static SCIP_RETCODE eventqueueAppend ( SCIP_EVENTQUEUE eventqueue,
SCIP_SET set,
SCIP_EVENT **  event 
)
static

appends event to the event queue; sets event to NULL afterwards

Parameters
eventqueueevent queue
setglobal SCIP settings
eventpointer to event to append to the queue

Definition at line 2033 of file event.c.

References SCIP_EventQueue::delayevents, eventqueueEnsureEventsMem(), SCIP_EventQueue::events, SCIP_Event::eventtype, SCIP_EventQueue::nevents, NULL, SCIP_CALL, SCIP_OKAY, and SCIPdebugMessage.

Referenced by SCIPeventqueueAdd().

SCIP_RETCODE SCIPeventqueueAdd ( SCIP_EVENTQUEUE eventqueue,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_PRIMAL primal,
SCIP_LP lp,
SCIP_BRANCHCAND branchcand,
SCIP_EVENTFILTER eventfilter,
SCIP_EVENT **  event 
)

processes event or adds event to the event queue

Parameters
eventqueueevent queue
blkmemblock memory buffer
setglobal SCIP settings
primalprimal data; only needed for objchanged events, or NULL
lpcurrent LP data; only needed for obj/boundchanged events, or NULL
branchcandbranching candidate storage; only needed for bound change events, or NULL
eventfilterevent filter for global events; not needed for variable specific events
eventpointer to event to add to the queue; will be NULL after queue addition

Definition at line 2057 of file event.c.

References SCIP_Event::data, SCIP_Var::data, SCIP_EventQueue::delayevents, SCIP_Event::eventbdchg, eventDisable(), SCIP_Event::eventobjchg, eventqueueAppend(), SCIP_Var::eventqueueimpl, SCIP_Var::eventqueueindexlb, SCIP_Var::eventqueueindexobj, SCIP_Var::eventqueueindexub, SCIP_EventQueue::events, SCIP_Event::eventtype, SCIP_EventQueue::nevents, SCIP_EventBdChg::newbound, SCIP_EventObjChg::newobj, NULL, SCIP_EventBdChg::oldbound, SCIP_EventObjChg::oldobj, SCIP_CALL, SCIP_EVENTTYPE_BESTSOLFOUND, SCIP_EVENTTYPE_BOUNDCHANGED, SCIP_EVENTTYPE_DISABLED, SCIP_EVENTTYPE_FIRSTLPSOLVED, SCIP_EVENTTYPE_GHOLEADDED, SCIP_EVENTTYPE_GHOLEREMOVED, SCIP_EVENTTYPE_GLBCHANGED, SCIP_EVENTTYPE_GUBCHANGED, SCIP_EVENTTYPE_IMPLADDED, SCIP_EVENTTYPE_LBRELAXED, SCIP_EVENTTYPE_LBTIGHTENED, SCIP_EVENTTYPE_LHOLEADDED, SCIP_EVENTTYPE_LHOLEREMOVED, SCIP_EVENTTYPE_LPSOLVED, SCIP_EVENTTYPE_NODEBRANCHED, SCIP_EVENTTYPE_NODEFEASIBLE, SCIP_EVENTTYPE_NODEFOCUSED, SCIP_EVENTTYPE_NODEINFEASIBLE, SCIP_EVENTTYPE_OBJCHANGED, SCIP_EVENTTYPE_POORSOLFOUND, SCIP_EVENTTYPE_PRESOLVEROUND, SCIP_EVENTTYPE_ROWADDEDLP, SCIP_EVENTTYPE_ROWADDEDSEPA, SCIP_EVENTTYPE_ROWCOEFCHANGED, SCIP_EVENTTYPE_ROWCONSTCHANGED, SCIP_EVENTTYPE_ROWDELETEDLP, SCIP_EVENTTYPE_ROWDELETEDSEPA, SCIP_EVENTTYPE_ROWSIDECHANGED, SCIP_EVENTTYPE_UBRELAXED, SCIP_EVENTTYPE_UBTIGHTENED, SCIP_EVENTTYPE_VARADDED, SCIP_EVENTTYPE_VARDELETED, SCIP_EVENTTYPE_VARFIXED, SCIP_EVENTTYPE_VARUNLOCKED, SCIP_INVALIDDATA, SCIP_OKAY, SCIPdebugMessage, SCIPerrorMessage, SCIPeventFree(), SCIPeventProcess(), SCIPsetIsEQ(), SCIPvarGetName(), TRUE, SCIP_EventObjChg::var, and SCIP_EventBdChg::var.

Referenced by lpDelRowset(), rowEventCoefChanged(), rowEventConstantChanged(), rowEventSideChanged(), SCIPcliquetableCleanup(), SCIPlpAddRow(), SCIPlpShrinkRows(), SCIPprobAddVar(), SCIPprobDelVar(), SCIPsepastoreClearCuts(), sepastoreAddCut(), sepastoreDelCut(), varEventGholeAdded(), varEventGlbChanged(), varEventGubChanged(), varEventImplAdded(), varEventLbChanged(), varEventObjChanged(), varEventUbChanged(), varEventVarFixed(), and varEventVarUnlocked().

SCIP_RETCODE SCIPeventqueueDelay ( SCIP_EVENTQUEUE eventqueue)

marks queue to delay incoming events until a call to SCIPeventqueueProcess()

Parameters
eventqueueevent queue

Definition at line 2292 of file event.c.

References SCIP_EventQueue::delayevents, NULL, SCIP_OKAY, SCIPdebugMessage, and TRUE.

Referenced by nodeRepropagate(), SCIPcliquetableCleanup(), and treeSwitchPath().

SCIP_RETCODE SCIPeventqueueProcess ( SCIP_EVENTQUEUE eventqueue,
BMS_BLKMEM blkmem,
SCIP_SET set,
SCIP_PRIMAL primal,
SCIP_LP lp,
SCIP_BRANCHCAND branchcand,
SCIP_EVENTFILTER eventfilter 
)

processes all delayed events, marks queue to process events immediately

Parameters
eventqueueevent queue
blkmemblock memory buffer
setglobal SCIP settings
primalprimal data
lpcurrent LP data
branchcandbranching candidate storage
eventfilterevent filter for global (not variable dependent) events

Definition at line 2307 of file event.c.

References SCIP_Event::data, SCIP_EventQueue::delayevents, SCIP_Event::eventbdchg, SCIP_Event::eventimpladd, SCIP_Event::eventobjchg, SCIP_Var::eventqueueimpl, SCIP_Var::eventqueueindexlb, SCIP_Var::eventqueueindexobj, SCIP_Var::eventqueueindexub, SCIP_EventQueue::events, SCIP_Event::eventtype, FALSE, SCIP_EventQueue::nevents, NULL, SCIP_CALL, SCIP_EVENTTYPE_IMPLADDED, SCIP_EVENTTYPE_LBCHANGED, SCIP_EVENTTYPE_OBJCHANGED, SCIP_EVENTTYPE_UBCHANGED, SCIP_OKAY, SCIPdebugMessage, SCIPeventFree(), SCIPeventProcess(), SCIP_EventObjChg::var, SCIP_EventBdChg::var, and SCIP_EventImplAdd::var.

Referenced by nodeRepropagate(), SCIPcliquetableCleanup(), and treeSwitchPath().

SCIP_Bool SCIPeventqueueIsDelayed ( SCIP_EVENTQUEUE eventqueue)

returns TRUE iff events of the queue are delayed until the next SCIPeventqueueProcess() call

Parameters
eventqueueevent queue

Definition at line 2379 of file event.c.

References SCIP_EventQueue::delayevents, and NULL.

Referenced by nodeRepropagate(), SCIPvarAggregate(), SCIPvarFix(), and SCIPvarMultiaggregate().