attr_dissector_fn_t
[wireshark-sm.git] / epan / tfs.h
blobea5ecd6219df4882d37c55e4626580ac7960a36d
1 /* tfs.h
2 * true_false strings
3 * Copyright 2007, Jaap Keuter <jaap.keuter@xs4all.nl>
5 * Wireshark - Network traffic analyzer
6 * By Gerald Combs <gerald@wireshark.org>
7 * Copyright 1998 Gerald Combs
9 * SPDX-License-Identifier: GPL-2.0-or-later
12 #ifndef __TFS_H__
13 #define __TFS_H__
15 #include <stdbool.h>
16 #include "ws_symbol_export.h"
18 #ifdef __cplusplus
19 extern "C" {
20 #endif /* __cplusplus */
22 /** @file
23 * true_false strings
26 /** Struct for boolean representation */
27 typedef struct true_false_string {
28 const char *true_string; /**< The string presented when true */
29 const char *false_string; /**< The string presented when false */
30 } true_false_string;
32 /** Returns the string representing the true or false value.
34 * From the given true_false_string return the appropriate string pointer
35 * @param[in] value The boolean value for which the string representation is sought
36 * @param[in] tfs The true_false_string containing the relevant strings
37 * @return Pointer to the appropriate string
39 WS_DLL_PUBLIC const char *tfs_get_string(bool value, const true_false_string *tfs);
41 #define tfs_get_true_false(value) tfs_get_string(value, NULL)
44 * A default set of true/false strings that dissectors can use for
45 * FT_BOOLEAN header fields. By default { "True", "False" } is used.
47 WS_DLL_PUBLIC const true_false_string tfs_yes_no;
48 WS_DLL_PUBLIC const true_false_string tfs_no_yes;
49 WS_DLL_PUBLIC const true_false_string tfs_set_notset;
50 WS_DLL_PUBLIC const true_false_string tfs_enabled_disabled;
51 WS_DLL_PUBLIC const true_false_string tfs_disabled_enabled;
52 WS_DLL_PUBLIC const true_false_string tfs_ok_error;
53 WS_DLL_PUBLIC const true_false_string tfs_error_ok;
54 WS_DLL_PUBLIC const true_false_string tfs_success_fail;
55 WS_DLL_PUBLIC const true_false_string tfs_fail_success;
56 WS_DLL_PUBLIC const true_false_string tfs_on_off;
57 WS_DLL_PUBLIC const true_false_string tfs_off_on;
58 WS_DLL_PUBLIC const true_false_string tfs_ack_nack;
59 WS_DLL_PUBLIC const true_false_string tfs_odd_even;
60 WS_DLL_PUBLIC const true_false_string tfs_allow_block;
61 WS_DLL_PUBLIC const true_false_string tfs_restricted_not_restricted;
62 WS_DLL_PUBLIC const true_false_string tfs_not_restricted_restricted;
63 WS_DLL_PUBLIC const true_false_string tfs_accept_reject;
64 WS_DLL_PUBLIC const true_false_string tfs_more_nomore;
65 WS_DLL_PUBLIC const true_false_string tfs_present_absent;
66 WS_DLL_PUBLIC const true_false_string tfs_present_not_present;
67 WS_DLL_PUBLIC const true_false_string tfs_active_inactive;
68 WS_DLL_PUBLIC const true_false_string tfs_activated_deactivated;
69 WS_DLL_PUBLIC const true_false_string tfs_found_not_found;
70 WS_DLL_PUBLIC const true_false_string tfs_command_response;
71 WS_DLL_PUBLIC const true_false_string tfs_response_command;
72 WS_DLL_PUBLIC const true_false_string tfs_capable_not_capable;
73 WS_DLL_PUBLIC const true_false_string tfs_supported_not_supported;
74 WS_DLL_PUBLIC const true_false_string tfs_not_supported_supported;
75 WS_DLL_PUBLIC const true_false_string tfs_used_notused;
76 WS_DLL_PUBLIC const true_false_string tfs_high_low;
77 WS_DLL_PUBLIC const true_false_string tfs_high_normal;
78 WS_DLL_PUBLIC const true_false_string tfs_low_normal;
79 WS_DLL_PUBLIC const true_false_string tfs_pressed_not_pressed;
80 WS_DLL_PUBLIC const true_false_string tfs_implemented_not_implemented;
81 WS_DLL_PUBLIC const true_false_string tfs_requested_not_requested;
82 WS_DLL_PUBLIC const true_false_string tfs_reliable_not_reliable;
83 WS_DLL_PUBLIC const true_false_string tfs_allowed_not_allowed;
84 WS_DLL_PUBLIC const true_false_string tfs_not_allowed_allowed;
85 WS_DLL_PUBLIC const true_false_string tfs_accepted_not_accepted;
86 WS_DLL_PUBLIC const true_false_string tfs_detected_not_detected;
87 WS_DLL_PUBLIC const true_false_string tfs_available_not_available;
88 WS_DLL_PUBLIC const true_false_string tfs_shared_independent;
89 WS_DLL_PUBLIC const true_false_string tfs_valid_invalid;
90 WS_DLL_PUBLIC const true_false_string tfs_invalid_valid;
91 WS_DLL_PUBLIC const true_false_string tfs_group_unique_name;
92 WS_DLL_PUBLIC const true_false_string tfs_inuse_not_inuse;
93 WS_DLL_PUBLIC const true_false_string tfs_critical_not_critical;
94 WS_DLL_PUBLIC const true_false_string tfs_complete_incomplete;
95 WS_DLL_PUBLIC const true_false_string tfs_valid_not_valid;
96 WS_DLL_PUBLIC const true_false_string tfs_do_not_clear_clear;
97 WS_DLL_PUBLIC const true_false_string tfs_confirmed_unconfirmed;
98 WS_DLL_PUBLIC const true_false_string tfs_enforced_not_enforced;
99 WS_DLL_PUBLIC const true_false_string tfs_possible_not_possible;
100 WS_DLL_PUBLIC const true_false_string tfs_required_not_required;
101 WS_DLL_PUBLIC const true_false_string tfs_registered_not_registered;
102 WS_DLL_PUBLIC const true_false_string tfs_provisioned_not_provisioned;
103 WS_DLL_PUBLIC const true_false_string tfs_included_not_included;
104 WS_DLL_PUBLIC const true_false_string tfs_allocated_by_receiver_sender;
105 WS_DLL_PUBLIC const true_false_string tfs_asynchronous_synchronous;
106 WS_DLL_PUBLIC const true_false_string tfs_protocol_sensative_bit_transparent;
107 WS_DLL_PUBLIC const true_false_string tfs_full_half;
108 WS_DLL_PUBLIC const true_false_string tfs_acknowledged_not_acknowledged;
109 WS_DLL_PUBLIC const true_false_string tfs_segmentation_no_segmentation;
110 WS_DLL_PUBLIC const true_false_string tfs_response_request;
111 WS_DLL_PUBLIC const true_false_string tfs_defined_not_defined;
112 WS_DLL_PUBLIC const true_false_string tfs_constructed_primitive;
113 WS_DLL_PUBLIC const true_false_string tfs_client_server;
114 WS_DLL_PUBLIC const true_false_string tfs_server_client;
115 WS_DLL_PUBLIC const true_false_string tfs_preferred_no_preference;
116 WS_DLL_PUBLIC const true_false_string tfs_encrypt_do_not_encrypt;
117 WS_DLL_PUBLIC const true_false_string tfs_down_up;
118 WS_DLL_PUBLIC const true_false_string tfs_up_down;
119 WS_DLL_PUBLIC const true_false_string tfs_uplink_downlink;
120 WS_DLL_PUBLIC const true_false_string tfs_s2c_c2s;
121 WS_DLL_PUBLIC const true_false_string tfs_open_closed;
122 WS_DLL_PUBLIC const true_false_string tfs_external_internal;
123 WS_DLL_PUBLIC const true_false_string tfs_changed_not_changed;
124 WS_DLL_PUBLIC const true_false_string tfs_needed_not_needed;
125 WS_DLL_PUBLIC const true_false_string tfs_selected_not_selected;
126 WS_DLL_PUBLIC const true_false_string tfs_add_drop;
127 WS_DLL_PUBLIC const true_false_string tfs_no_extension_extension;
128 WS_DLL_PUBLIC const true_false_string tfs_user_provider;
129 WS_DLL_PUBLIC const true_false_string tfs_applicable_not_applicable;
130 WS_DLL_PUBLIC const true_false_string tfs_current_not_yet;
131 WS_DLL_PUBLIC const true_false_string tfs_should_be_traced_should_not_be_traced;
132 WS_DLL_PUBLIC const true_false_string tfs_activate_do_not_activate;
133 WS_DLL_PUBLIC const true_false_string tfs_data_pdu_control_pdu;
135 #ifdef __cplusplus
137 #endif /* __cplusplus */
139 #endif /* __TFS_H__ */
142 * Editor modelines - https://www.wireshark.org/tools/modelines.html
144 * Local variables:
145 * c-basic-offset: 4
146 * tab-width: 8
147 * indent-tabs-mode: nil
148 * End:
150 * vi: set shiftwidth=4 tabstop=8 expandtab:
151 * :indentSize=4:tabSize=8:noTabs=true: