(Temporarily) Allow DCE/RPC dissector table to have duplicates.
[metze/wireshark/wip.git] / epan / timestamp.h
1 /* timestamp.h
2  * Defines for packet timestamps
3  *
4  * Wireshark - Network traffic analyzer
5  * By Gerald Combs <gerald@wireshark.org>
6  * Copyright 1998 Gerald Combs
7  *
8  * This program is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU General Public License
10  * as published by the Free Software Foundation; either version 2
11  * of the License, or (at your option) any later version.
12  *
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with this program; if not, write to the Free Software
20  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
21  */
22
23 #ifndef __TIMESTAMP_H__
24 #define __TIMESTAMP_H__
25
26 #include "ws_symbol_export.h"
27
28 #ifdef __cplusplus
29 extern "C" {
30 #endif /* __cplusplus */
31
32 /*
33  * Type of time-stamp shown in the summary display.
34  */
35 typedef enum {
36         TS_RELATIVE,            /* Since start of capture */
37         TS_ABSOLUTE,            /* Local absolute time, without date */
38         TS_ABSOLUTE_WITH_YMD,   /* Local absolute time, with date in YYYY-MM-DD form */
39         TS_ABSOLUTE_WITH_YDOY,  /* Local absolute time, with date in YYYY DOY form */
40         TS_DELTA,               /* Since previous captured packet */
41         TS_DELTA_DIS,           /* Since previous displayed packet */
42         TS_EPOCH,               /* Seconds (and fractions) since epoch */
43         TS_UTC,                 /* UTC absolute time, without date */
44         TS_UTC_WITH_YMD,        /* UTC absolute time, with date in YYYY-MM-DD form */
45         TS_UTC_WITH_YDOY,       /* UTC absolute time, with date in YYYY DOY form */
46
47 /*
48  * Special value used for the command-line setting in Wireshark, to indicate
49  * that no value has been set from the command line.
50  */
51         TS_NOT_SET
52 } ts_type;
53
54 typedef enum {
55         TS_PREC_AUTO,
56         TS_PREC_FIXED_SEC,
57         TS_PREC_FIXED_DSEC,
58         TS_PREC_FIXED_CSEC,
59         TS_PREC_FIXED_MSEC,
60         TS_PREC_FIXED_USEC,
61         TS_PREC_FIXED_NSEC
62 } ts_precision;
63
64 typedef enum {
65         TS_SECONDS_DEFAULT,     /* recent */
66         TS_SECONDS_HOUR_MIN_SEC,/* recent */
67
68 /*
69  * Special value used for the command-line setting in Wireshark, to indicate
70  * that no value has been set from the command line.
71  */
72         TS_SECONDS_NOT_SET
73 } ts_seconds_type;
74
75 WS_DLL_PUBLIC ts_type timestamp_get_type(void);
76 WS_DLL_PUBLIC void timestamp_set_type(ts_type);
77
78 WS_DLL_PUBLIC int timestamp_get_precision(void);
79 WS_DLL_PUBLIC void timestamp_set_precision(int tsp);
80
81 WS_DLL_PUBLIC ts_seconds_type timestamp_get_seconds_type(void);
82 WS_DLL_PUBLIC void timestamp_set_seconds_type(ts_seconds_type);
83
84 #ifdef __cplusplus
85 }
86 #endif /* __cplusplus */
87
88 #endif /* timestamp.h */