Commit | Line | Data |
---|---|---|
d44e3c4f | 1 | /****************************************************************************** |
2 | * Copyright (c) 2000-2016 Ericsson Telecom AB | |
3 | * All rights reserved. This program and the accompanying materials | |
4 | * are made available under the terms of the Eclipse Public License v1.0 | |
5 | * which accompanies this distribution, and is available at | |
6 | * http://www.eclipse.org/legal/epl-v10.html | |
7 | * | |
8 | * Contributors: | |
9 | * Baji, Laszlo | |
10 | * Balasko, Jeno | |
11 | * Feher, Csaba | |
12 | * Raduly, Csaba | |
13 | * Szabo, Janos Zoltan – initial implementation | |
14 | * | |
15 | ******************************************************************************/ | |
970ed795 EL |
16 | #ifndef SNAPSHOT_HH |
17 | #define SNAPSHOT_HH | |
18 | ||
19 | #include <sys/types.h> | |
20 | ||
21 | #include "Types.h" | |
22 | ||
23 | class Fd_Event_Handler; | |
24 | ||
25 | class TTCN_Snapshot { | |
26 | static boolean else_branch_found; ///< [else] branch of \c alt was reached | |
27 | static double alt_begin; ///< The time when the snapshot was taken. | |
28 | ||
29 | public: | |
30 | static void initialize(); | |
31 | static void check_fd_setsize(); | |
32 | static void terminate(); | |
33 | static void else_branch_reached(); | |
34 | static double time_now(); | |
35 | static inline double get_alt_begin() { return alt_begin; } | |
36 | static void take_new(boolean block_execution); | |
37 | static void block_for_sending(int send_fd, Fd_Event_Handler * handler = 0); | |
38 | }; | |
39 | ||
40 | #endif |