2 * Defines for packet timestamps
4 * Wireshark - Network traffic analyzer
5 * By Gerald Combs <gerald@wireshark.org>
6 * Copyright 1998 Gerald Combs
8 * SPDX-License-Identifier: GPL-2.0-or-later
11 #ifndef __TIMESTAMP_H__
12 #define __TIMESTAMP_H__
14 #include "ws_symbol_export.h"
18 #endif /* __cplusplus */
21 * Type of time-stamp shown in the summary display.
24 TS_RELATIVE, /* Since start of capture */
25 TS_ABSOLUTE, /* Local absolute time, without date */
26 TS_ABSOLUTE_WITH_YMD, /* Local absolute time, with date in YYYY-MM-DD form */
27 TS_ABSOLUTE_WITH_YDOY, /* Local absolute time, with date in YYYY DOY form */
28 TS_DELTA, /* Since previous captured packet */
29 TS_DELTA_DIS, /* Since previous displayed packet */
30 TS_EPOCH, /* Seconds (and fractions) since epoch */
31 TS_UTC, /* UTC absolute time, without date */
32 TS_UTC_WITH_YMD, /* UTC absolute time, with date in YYYY-MM-DD form */
33 TS_UTC_WITH_YDOY, /* UTC absolute time, with date in YYYY DOY form */
36 * Special value used for the command-line setting in Wireshark, to indicate
37 * that no value has been set from the command line.
53 TS_SECONDS_DEFAULT, /* recent */
54 TS_SECONDS_HOUR_MIN_SEC,/* recent */
57 * Special value used for the command-line setting in Wireshark, to indicate
58 * that no value has been set from the command line.
63 WS_DLL_PUBLIC ts_type timestamp_get_type(void);
64 WS_DLL_PUBLIC void timestamp_set_type(ts_type);
66 WS_DLL_PUBLIC int timestamp_get_precision(void);
67 WS_DLL_PUBLIC void timestamp_set_precision(int tsp);
69 WS_DLL_PUBLIC ts_seconds_type timestamp_get_seconds_type(void);
70 WS_DLL_PUBLIC void timestamp_set_seconds_type(ts_seconds_type);
74 #endif /* __cplusplus */
76 #endif /* timestamp.h */