Scippy

SCIP

Solving Constraint Integer Programs

interrupt.h
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-2014 Konrad-Zuse-Zentrum */
7 /* fuer Informationstechnik Berlin */
8 /* */
9 /* SCIP is distributed under the terms of the ZIB Academic License. */
10 /* */
11 /* You should have received a copy of the ZIB Academic License */
12 /* along with SCIP; see the file COPYING. If not email to scip@zib.de. */
13 /* */
14 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
15 
16 /**@file interrupt.h
17  * @brief methods for catching the user CTRL-C interrupt
18  * @author Tobias Achterberg
19  */
20 
21 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
22 
23 #ifndef __SCIP_INTERRUPT_H__
24 #define __SCIP_INTERRUPT_H__
25 
26 
27 #include "scip/def.h"
28 #include "scip/type_retcode.h"
29 #include "scip/type_interrupt.h"
30 
31 #ifdef __cplusplus
32 extern "C" {
33 #endif
34 
35 /** creates a CTRL-C interrupt data */
36 extern
38  SCIP_INTERRUPT** interrupt /**< pointer to store the CTRL-C interrupt data */
39  );
40 
41 /** frees a CTRL-C interrupt data */
42 extern
44  SCIP_INTERRUPT** interrupt /**< pointer to the CTRL-C interrupt data */
45  );
46 
47 /** captures the CTRL-C interrupt to call the SCIP's own interrupt handler */
48 extern
50  SCIP_INTERRUPT* interrupt /**< CTRL-C interrupt data */
51  );
52 
53 /** releases the CTRL-C interrupt and restores the old interrupt handler */
54 extern
56  SCIP_INTERRUPT* interrupt /**< CTRL-C interrupt data */
57  );
58 
59 /** returns whether the user interrupted by pressing CTRL-C */
60 extern
62  void
63  );
64 
65 #ifdef __cplusplus
66 }
67 #endif
68 
69 #endif
70