Wireshark
4.5.0
The Wireshark network protocol analyzer
Loading...
Searching...
No Matches
wsutil
clopts_common.h
Go to the documentation of this file.
1
12
#ifndef __CLOPTS_COMMON_H__
13
#define __CLOPTS_COMMON_H__
14
15
#include <wireshark.h>
16
17
#ifdef __cplusplus
18
extern
"C"
{
19
#endif
/* __cplusplus */
20
21
/*
22
* Long options.
23
* For long options with no corresponding short options, we define values
24
* outside the range of ASCII graphic characters, make that the last
25
* component of the entry for the long option, and have a case for that
26
* option in the switch statement.
27
*/
28
// Base value for capture related long options
29
#define LONGOPT_BASE_CAPTURE 1000
30
// Base value for dissector related long options
31
#define LONGOPT_BASE_DISSECTOR 2000
32
// Base value for application specific long options
33
#define LONGOPT_BASE_APPLICATION 3000
34
// Base value for GUI specific long options
35
#define LONGOPT_BASE_GUI 4000
36
37
#define LONGOPT_READ_CAPTURE_COMMON \
38
{"read-file", ws_required_argument, NULL, 'r' }, \
39
40
#define OPTSTRING_READ_CAPTURE_COMMON \
41
"r:"
42
43
WS_DLL_PUBLIC
int
44
get_natural_int(
const
char
*
string
,
const
char
*name);
45
46
WS_DLL_PUBLIC
int
47
get_positive_int(
const
char
*
string
,
const
char
*name);
48
49
WS_DLL_PUBLIC uint32_t
50
get_uint32(
const
char
*
string
,
const
char
*name);
51
52
WS_DEPRECATED_X(
"Use get_uint32 instead"
)
53
static inline uint32_t
54
get_guint32(const
char
*
string
, const
char
*name) {
return
get_uint32(
string
, name); }
55
56
WS_DLL_PUBLIC uint32_t
57
get_nonzero_uint32(
const
char
*
string
,
const
char
*name);
58
59
WS_DEPRECATED_X(
"Use get_nonzero_uint32 instead"
)
60
static inline uint32_t
61
get_nonzero_guint32(const
char
*
string
, const
char
*name) {
return
get_nonzero_uint32(
string
, name); }
62
63
WS_DLL_PUBLIC uint64_t
64
get_uint64(
const
char
*
string
,
const
char
*name);
65
66
WS_DLL_PUBLIC uint64_t
67
get_nonzero_uint64(
const
char
*
string
,
const
char
*name);
68
69
WS_DLL_PUBLIC
double
70
get_positive_double(
const
char
*
string
,
const
char
*name);
71
72
#ifdef __cplusplus
73
}
74
#endif
/* __cplusplus */
75
76
#endif
/* __CLOPTS_COMMON_H__ */
Generated by
1.9.8