methods for catching the user CTRL-C interrupt
Definition in file interrupt.h.
Go to the source code of this file.
Functions | |
SCIP_RETCODE | SCIPinterruptCreate (SCIP_INTERRUPT **interrupt) |
void | SCIPinterruptFree (SCIP_INTERRUPT **interrupt) |
void | SCIPinterruptCapture (SCIP_INTERRUPT *interrupt) |
void | SCIPinterruptRelease (SCIP_INTERRUPT *interrupt) |
SCIP_Bool | SCIPinterrupted (void) |
void | SCIPresetInterrupted (void) |
SCIP_RETCODE SCIPinterruptCreate | ( | SCIP_INTERRUPT ** | interrupt | ) |
creates a CTRL-C interrupt data
interrupt | pointer to store the CTRL-C interrupt data |
Definition at line 76 of file interrupt.c.
References BMSallocMemory, NULL, SCIP_ALLOC, and SCIP_OKAY.
Referenced by SCIPcreate().
void SCIPinterruptFree | ( | SCIP_INTERRUPT ** | interrupt | ) |
frees a CTRL-C interrupt data
interrupt | pointer to the CTRL-C interrupt data |
Definition at line 89 of file interrupt.c.
References BMSfreeMemory, and NULL.
Referenced by SCIPfree().
void SCIPinterruptCapture | ( | SCIP_INTERRUPT * | interrupt | ) |
captures the CTRL-C interrupt to call the SCIP's own interrupt handler
interrupt | CTRL-C interrupt data |
Definition at line 99 of file interrupt.c.
References interruptHandler(), ninterrupts, NULL, SCIP_Interrupt::nuses, and SCIP_Interrupt::oldsigaction.
Referenced by SCIPpresolve(), and SCIPsolve().
void SCIPinterruptRelease | ( | SCIP_INTERRUPT * | interrupt | ) |
releases the CTRL-C interrupt and restores the old interrupt handler
interrupt | CTRL-C interrupt data |
Definition at line 128 of file interrupt.c.
References NULL, SCIP_Interrupt::nuses, and SCIP_Interrupt::oldsigaction.
Referenced by SCIPpresolve(), and SCIPsolve().
SCIP_Bool SCIPinterrupted | ( | void | ) |
returns whether the user interrupted by pressing CTRL-C
Definition at line 147 of file interrupt.c.
References ninterrupts.
Referenced by SCIPpressedCtrlC(), SCIPsetModifiedDefaultSettingsIpopt(), and SCIPsolveIsStopped().
void SCIPresetInterrupted | ( | void | ) |
resets the number of interrupts to 0
Definition at line 155 of file interrupt.c.
References ninterrupts.
Referenced by SCIPsolveIsStopped().