2001-02-01 20:21:25 +00:00
|
|
|
/* ftypes.h
|
|
|
|
* Definitions for field types
|
|
|
|
*
|
2006-05-21 05:12:17 +00:00
|
|
|
* Wireshark - Network traffic analyzer
|
|
|
|
* By Gerald Combs <gerald@wireshark.org>
|
2001-02-01 20:21:25 +00:00
|
|
|
* Copyright 2001 Gerald Combs
|
2002-08-28 20:41:00 +00:00
|
|
|
*
|
2018-02-08 16:59:17 +00:00
|
|
|
* SPDX-License-Identifier: GPL-2.0-or-later
|
2001-02-01 20:21:25 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
|
2012-08-19 23:52:08 +00:00
|
|
|
#ifndef __FTYPES_H__
|
|
|
|
#define __FTYPES_H__
|
2001-02-01 20:21:25 +00:00
|
|
|
|
|
|
|
#include <glib.h>
|
2021-07-26 00:31:17 +00:00
|
|
|
#include <epan/wmem_scopes.h>
|
2013-03-01 23:53:11 +00:00
|
|
|
#include "ws_symbol_export.h"
|
2001-02-01 20:21:25 +00:00
|
|
|
|
2012-08-19 23:52:08 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif /* __cplusplus */
|
|
|
|
|
2001-02-01 20:21:25 +00:00
|
|
|
/* field types */
|
|
|
|
enum ftenum {
|
|
|
|
FT_NONE, /* used for text labels with no value */
|
|
|
|
FT_PROTOCOL,
|
|
|
|
FT_BOOLEAN, /* TRUE and FALSE come from <glib.h> */
|
2016-09-19 01:48:50 +00:00
|
|
|
FT_CHAR, /* 1-octet character as 0-255 */
|
2001-02-01 20:21:25 +00:00
|
|
|
FT_UINT8,
|
|
|
|
FT_UINT16,
|
2016-01-12 16:41:38 +00:00
|
|
|
FT_UINT24, /* really a UINT32, but displayed as 6 hex-digits if FD_HEX*/
|
2001-02-01 20:21:25 +00:00
|
|
|
FT_UINT32,
|
2014-12-17 20:19:20 +00:00
|
|
|
FT_UINT40, /* really a UINT64, but displayed as 10 hex-digits if FD_HEX*/
|
|
|
|
FT_UINT48, /* really a UINT64, but displayed as 12 hex-digits if FD_HEX*/
|
|
|
|
FT_UINT56, /* really a UINT64, but displayed as 14 hex-digits if FD_HEX*/
|
2001-10-29 21:13:13 +00:00
|
|
|
FT_UINT64,
|
2001-02-01 20:21:25 +00:00
|
|
|
FT_INT8,
|
|
|
|
FT_INT16,
|
2001-11-02 10:09:51 +00:00
|
|
|
FT_INT24, /* same as for UINT24 */
|
2001-02-01 20:21:25 +00:00
|
|
|
FT_INT32,
|
2014-12-17 20:19:20 +00:00
|
|
|
FT_INT40, /* same as for UINT40 */
|
|
|
|
FT_INT48, /* same as for UINT48 */
|
|
|
|
FT_INT56, /* same as for UINT56 */
|
2001-11-02 10:09:51 +00:00
|
|
|
FT_INT64,
|
2015-09-06 17:01:47 +00:00
|
|
|
FT_IEEE_11073_SFLOAT,
|
|
|
|
FT_IEEE_11073_FLOAT,
|
2002-08-24 19:45:28 +00:00
|
|
|
FT_FLOAT,
|
2001-02-01 20:21:25 +00:00
|
|
|
FT_DOUBLE,
|
|
|
|
FT_ABSOLUTE_TIME,
|
|
|
|
FT_RELATIVE_TIME,
|
Add FT_STRINGZTRUNC.
FT_STRINGZPAD is for null-*padded* strings, where the field is in an
area of specified length, and, if the string is shorter than that
length, all bytes past the end of the string are NULs.
FT_STRINGZTRUNC is for null-*truncated* strings, where the field is in
an area of specified length and, if the string is shorter than that
length, there's a null character (which might be more than one byte, for
UCS-2, UTF-16, or UTF-32), and anything after that is not guaranteed to
have any particular value.
Use IS_FT_STRING() in some places rather than enumerating all the string
types, so that those places get automatically changed if the set of
string types changes.
2020-09-12 21:16:12 +00:00
|
|
|
FT_STRING, /* counted string, with no null terminator */
|
|
|
|
FT_STRINGZ, /* null-terminated string */
|
|
|
|
FT_UINT_STRING, /* counted string, with count being the first part of the value */
|
2001-02-01 20:21:25 +00:00
|
|
|
FT_ETHER,
|
|
|
|
FT_BYTES,
|
2002-05-09 23:50:34 +00:00
|
|
|
FT_UINT_BYTES,
|
2001-02-01 20:21:25 +00:00
|
|
|
FT_IPv4,
|
|
|
|
FT_IPv6,
|
|
|
|
FT_IPXNET,
|
2010-05-08 16:12:29 +00:00
|
|
|
FT_FRAMENUM, /* a UINT32, but if selected lets you go to frame with that number */
|
|
|
|
FT_GUID, /* GUID, UUID */
|
|
|
|
FT_OID, /* OBJECT IDENTIFIER */
|
2011-07-11 20:32:19 +00:00
|
|
|
FT_EUI64,
|
2012-08-02 16:54:43 +00:00
|
|
|
FT_AX25,
|
2013-07-28 00:07:49 +00:00
|
|
|
FT_VINES,
|
2013-10-06 02:31:10 +00:00
|
|
|
FT_REL_OID, /* RELATIVE-OID */
|
2013-12-23 15:18:48 +00:00
|
|
|
FT_SYSTEM_ID,
|
Add FT_STRINGZTRUNC.
FT_STRINGZPAD is for null-*padded* strings, where the field is in an
area of specified length, and, if the string is shorter than that
length, all bytes past the end of the string are NULs.
FT_STRINGZTRUNC is for null-*truncated* strings, where the field is in
an area of specified length and, if the string is shorter than that
length, there's a null character (which might be more than one byte, for
UCS-2, UTF-16, or UTF-32), and anything after that is not guaranteed to
have any particular value.
Use IS_FT_STRING() in some places rather than enumerating all the string
types, so that those places get automatically changed if the set of
string types changes.
2020-09-12 21:16:12 +00:00
|
|
|
FT_STRINGZPAD, /* null-padded string */
|
2014-12-24 05:06:35 +00:00
|
|
|
FT_FCWWN,
|
Add FT_STRINGZTRUNC.
FT_STRINGZPAD is for null-*padded* strings, where the field is in an
area of specified length, and, if the string is shorter than that
length, all bytes past the end of the string are NULs.
FT_STRINGZTRUNC is for null-*truncated* strings, where the field is in
an area of specified length and, if the string is shorter than that
length, there's a null character (which might be more than one byte, for
UCS-2, UTF-16, or UTF-32), and anything after that is not guaranteed to
have any particular value.
Use IS_FT_STRING() in some places rather than enumerating all the string
types, so that those places get automatically changed if the set of
string types changes.
2020-09-12 21:16:12 +00:00
|
|
|
FT_STRINGZTRUNC, /* null-truncated string */
|
2001-02-01 20:21:25 +00:00
|
|
|
FT_NUM_TYPES /* last item number plus one */
|
|
|
|
};
|
|
|
|
|
2018-09-02 15:58:06 +00:00
|
|
|
#define IS_FT_INT32(ft) \
|
|
|
|
((ft) == FT_INT8 || \
|
|
|
|
(ft) == FT_INT16 || \
|
|
|
|
(ft) == FT_INT24 || \
|
|
|
|
(ft) == FT_INT32)
|
|
|
|
#define IS_FT_INT64(ft) \
|
|
|
|
((ft) == FT_INT40 || \
|
|
|
|
(ft) == FT_INT48 || \
|
|
|
|
(ft) == FT_INT56 || \
|
|
|
|
(ft) == FT_INT64)
|
|
|
|
#define IS_FT_INT(ft) (IS_FT_INT32(ft) || IS_FT_INT64(ft))
|
|
|
|
#define IS_FT_UINT32(ft) \
|
|
|
|
((ft) == FT_CHAR || \
|
|
|
|
(ft) == FT_UINT8 || \
|
|
|
|
(ft) == FT_UINT16 || \
|
|
|
|
(ft) == FT_UINT24 || \
|
|
|
|
(ft) == FT_UINT32 || \
|
|
|
|
(ft) == FT_FRAMENUM)
|
|
|
|
#define IS_FT_UINT64(ft) \
|
|
|
|
((ft) == FT_UINT40 || \
|
|
|
|
(ft) == FT_UINT48 || \
|
|
|
|
(ft) == FT_UINT56 || \
|
|
|
|
(ft) == FT_UINT64)
|
|
|
|
#define IS_FT_UINT(ft) (IS_FT_UINT32(ft) || IS_FT_UINT64(ft))
|
|
|
|
#define IS_FT_TIME(ft) \
|
|
|
|
((ft) == FT_ABSOLUTE_TIME || (ft) == FT_RELATIVE_TIME)
|
|
|
|
#define IS_FT_STRING(ft) \
|
Add FT_STRINGZTRUNC.
FT_STRINGZPAD is for null-*padded* strings, where the field is in an
area of specified length, and, if the string is shorter than that
length, all bytes past the end of the string are NULs.
FT_STRINGZTRUNC is for null-*truncated* strings, where the field is in
an area of specified length and, if the string is shorter than that
length, there's a null character (which might be more than one byte, for
UCS-2, UTF-16, or UTF-32), and anything after that is not guaranteed to
have any particular value.
Use IS_FT_STRING() in some places rather than enumerating all the string
types, so that those places get automatically changed if the set of
string types changes.
2020-09-12 21:16:12 +00:00
|
|
|
((ft) == FT_STRING || (ft) == FT_STRINGZ || (ft) == FT_STRINGZPAD || \
|
|
|
|
(ft) == FT_STRINGZTRUNC)
|
2004-06-24 21:50:05 +00:00
|
|
|
|
2009-09-10 18:22:33 +00:00
|
|
|
/* field types lengths */
|
2017-10-08 09:54:54 +00:00
|
|
|
#define FT_ETHER_LEN 6
|
|
|
|
#define FT_GUID_LEN 16
|
|
|
|
#define FT_IPv4_LEN 4
|
|
|
|
#define FT_IPv6_LEN 16
|
|
|
|
#define FT_IPXNET_LEN 4
|
|
|
|
#define FT_EUI64_LEN 8
|
|
|
|
#define FT_AX25_ADDR_LEN 7
|
|
|
|
#define FT_VINES_ADDR_LEN 6
|
|
|
|
#define FT_FCWWN_LEN 8
|
2017-09-23 13:05:21 +00:00
|
|
|
#define FT_VARINT_MAX_LEN 10 /* Because 64 / 7 = 9 and 64 % 7 = 1, get an uint64 varint need reads up to 10 bytes. */
|
2009-09-10 18:22:33 +00:00
|
|
|
|
2001-02-01 20:21:25 +00:00
|
|
|
typedef enum ftenum ftenum_t;
|
2013-11-10 13:14:09 +00:00
|
|
|
|
2015-02-24 01:56:14 +00:00
|
|
|
enum ft_framenum_type {
|
2017-10-08 09:54:54 +00:00
|
|
|
FT_FRAMENUM_NONE,
|
|
|
|
FT_FRAMENUM_REQUEST,
|
|
|
|
FT_FRAMENUM_RESPONSE,
|
|
|
|
FT_FRAMENUM_ACK,
|
|
|
|
FT_FRAMENUM_DUP_ACK,
|
2017-11-26 20:41:50 +00:00
|
|
|
FT_FRAMENUM_RETRANS_PREV,
|
|
|
|
FT_FRAMENUM_RETRANS_NEXT,
|
2017-10-08 09:54:54 +00:00
|
|
|
FT_FRAMENUM_NUM_TYPES /* last item number plus one */
|
2015-02-24 01:56:14 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
typedef enum ft_framenum_type ft_framenum_type_t;
|
|
|
|
|
2013-11-10 13:14:09 +00:00
|
|
|
struct _ftype_t;
|
2001-02-01 20:21:25 +00:00
|
|
|
typedef struct _ftype_t ftype_t;
|
|
|
|
|
2021-10-15 22:47:28 +00:00
|
|
|
struct _fvalue_regex_t;
|
|
|
|
typedef struct _fvalue_regex_t fvalue_regex_t;
|
|
|
|
|
2003-06-11 21:24:54 +00:00
|
|
|
/* String representation types. */
|
|
|
|
enum ftrepr {
|
2010-05-08 16:12:29 +00:00
|
|
|
FTREPR_DISPLAY,
|
|
|
|
FTREPR_DFILTER
|
2003-06-11 21:24:54 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
typedef enum ftrepr ftrepr_t;
|
|
|
|
|
2018-12-05 17:59:23 +00:00
|
|
|
/* Initialize the ftypes subsystem. Called once. */
|
2001-02-01 20:21:25 +00:00
|
|
|
void
|
|
|
|
ftypes_initialize(void);
|
|
|
|
|
|
|
|
/* ---------------- FTYPE ----------------- */
|
|
|
|
|
2014-02-21 02:12:25 +00:00
|
|
|
/* given two types, are they similar - for example can two
|
|
|
|
* duplicate fields be registered of these two types. */
|
|
|
|
gboolean
|
|
|
|
ftype_similar_types(const enum ftenum ftype_a, const enum ftenum ftype_b);
|
|
|
|
|
2001-02-01 20:21:25 +00:00
|
|
|
/* Return a string representing the name of the type */
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2001-02-01 20:21:25 +00:00
|
|
|
const char*
|
|
|
|
ftype_name(ftenum_t ftype);
|
|
|
|
|
|
|
|
/* Return a string presenting a "pretty" representation of the
|
|
|
|
* name of the type. The pretty name means more to the user than
|
|
|
|
* that "FT_*" name. */
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2001-02-01 20:21:25 +00:00
|
|
|
const char*
|
|
|
|
ftype_pretty_name(ftenum_t ftype);
|
|
|
|
|
|
|
|
/* Returns length of field in packet, or 0 if not determinable/defined. */
|
|
|
|
int
|
|
|
|
ftype_length(ftenum_t ftype);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2001-02-01 20:21:25 +00:00
|
|
|
gboolean
|
|
|
|
ftype_can_slice(enum ftenum ftype);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2001-02-01 20:21:25 +00:00
|
|
|
gboolean
|
|
|
|
ftype_can_eq(enum ftenum ftype);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2001-02-01 20:21:25 +00:00
|
|
|
gboolean
|
|
|
|
ftype_can_ne(enum ftenum ftype);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2001-02-01 20:21:25 +00:00
|
|
|
gboolean
|
|
|
|
ftype_can_gt(enum ftenum ftype);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2001-02-01 20:21:25 +00:00
|
|
|
gboolean
|
|
|
|
ftype_can_ge(enum ftenum ftype);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2001-02-01 20:21:25 +00:00
|
|
|
gboolean
|
|
|
|
ftype_can_lt(enum ftenum ftype);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2001-02-01 20:21:25 +00:00
|
|
|
gboolean
|
|
|
|
ftype_can_le(enum ftenum ftype);
|
|
|
|
|
2004-02-27 12:00:32 +00:00
|
|
|
gboolean
|
|
|
|
ftype_can_bitwise_and(enum ftenum ftype);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2003-08-27 15:23:11 +00:00
|
|
|
gboolean
|
|
|
|
ftype_can_contains(enum ftenum ftype);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2003-12-06 16:35:20 +00:00
|
|
|
gboolean
|
|
|
|
ftype_can_matches(enum ftenum ftype);
|
|
|
|
|
2001-02-01 20:21:25 +00:00
|
|
|
/* ---------------- FVALUE ----------------- */
|
|
|
|
|
2002-01-21 07:37:49 +00:00
|
|
|
#include <epan/ipv4.h>
|
2016-01-03 20:30:57 +00:00
|
|
|
#include <epan/ipv6.h>
|
2006-03-10 11:58:22 +00:00
|
|
|
#include <epan/guid-utils.h>
|
2001-02-01 20:21:25 +00:00
|
|
|
|
2002-01-21 07:37:49 +00:00
|
|
|
#include <epan/tvbuff.h>
|
2013-06-25 22:02:20 +00:00
|
|
|
#include <wsutil/nstime.h>
|
2002-01-21 07:37:49 +00:00
|
|
|
#include <epan/dfilter/drange.h>
|
2001-02-01 20:21:25 +00:00
|
|
|
|
2016-05-03 01:44:48 +00:00
|
|
|
typedef struct _protocol_value_t
|
|
|
|
{
|
|
|
|
tvbuff_t *tvb;
|
|
|
|
gchar *proto_string;
|
|
|
|
} protocol_value_t;
|
|
|
|
|
2003-11-25 08:50:38 +00:00
|
|
|
typedef struct _fvalue_t {
|
2003-12-03 09:28:26 +00:00
|
|
|
ftype_t *ftype;
|
2001-02-01 20:21:25 +00:00
|
|
|
union {
|
|
|
|
/* Put a few basic types in here */
|
2016-01-03 23:05:13 +00:00
|
|
|
guint32 uinteger;
|
|
|
|
gint32 sinteger;
|
|
|
|
guint64 integer64;
|
|
|
|
guint64 uinteger64;
|
|
|
|
gint64 sinteger64;
|
|
|
|
gdouble floating;
|
|
|
|
gchar *string;
|
|
|
|
guchar *ustring;
|
|
|
|
GByteArray *bytes;
|
|
|
|
ipv4_addr_and_mask ipv4;
|
|
|
|
ipv6_addr_and_prefix ipv6;
|
|
|
|
e_guid_t guid;
|
|
|
|
nstime_t time;
|
2016-07-30 07:43:23 +00:00
|
|
|
protocol_value_t protocol;
|
2016-01-03 23:05:13 +00:00
|
|
|
guint16 sfloat_ieee_11073;
|
|
|
|
guint32 float_ieee_11073;
|
2001-02-01 20:21:25 +00:00
|
|
|
} value;
|
2003-08-27 15:23:11 +00:00
|
|
|
|
|
|
|
/* The following is provided for private use
|
|
|
|
* by the fvalue. */
|
|
|
|
gboolean fvalue_gboolean1;
|
|
|
|
|
2001-02-01 20:21:25 +00:00
|
|
|
} fvalue_t;
|
|
|
|
|
|
|
|
fvalue_t*
|
|
|
|
fvalue_new(ftenum_t ftype);
|
|
|
|
|
2003-12-02 21:15:49 +00:00
|
|
|
void
|
|
|
|
fvalue_init(fvalue_t *fv, ftenum_t ftype);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2003-07-25 03:44:05 +00:00
|
|
|
fvalue_t*
|
2015-01-18 10:22:19 +00:00
|
|
|
fvalue_from_unparsed(ftenum_t ftype, const char *s, gboolean allow_partial_value, gchar **err_msg);
|
2003-07-25 03:44:05 +00:00
|
|
|
|
2001-02-01 20:21:25 +00:00
|
|
|
fvalue_t*
|
2015-01-18 10:22:19 +00:00
|
|
|
fvalue_from_string(ftenum_t ftype, const char *s, gchar **err_msg);
|
2001-02-01 20:21:25 +00:00
|
|
|
|
2003-06-11 21:24:54 +00:00
|
|
|
/* Returns the length of the string required to hold the
|
|
|
|
* string representation of the the field value.
|
2008-11-11 13:32:51 +00:00
|
|
|
*
|
|
|
|
* Returns -1 if the string cannot be represented in the given rtype.
|
|
|
|
*
|
2003-06-11 21:24:54 +00:00
|
|
|
* The length DOES NOT include the terminating NUL. */
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2003-02-08 04:22:37 +00:00
|
|
|
int
|
2015-01-04 02:56:16 +00:00
|
|
|
fvalue_string_repr_len(fvalue_t *fv, ftrepr_t rtype, int field_display);
|
2003-06-11 21:24:54 +00:00
|
|
|
|
|
|
|
/* Creates the string representation of the field value.
|
2016-05-10 20:04:14 +00:00
|
|
|
* Memory for the buffer is allocated based on wmem allocator
|
|
|
|
* provided.
|
2008-11-11 13:32:51 +00:00
|
|
|
*
|
2015-01-04 02:56:16 +00:00
|
|
|
* field_display parameter should be a BASE_ value (enum field_display_e)
|
|
|
|
* BASE_NONE should be used if field information isn't available.
|
|
|
|
*
|
2008-11-11 13:32:51 +00:00
|
|
|
* Returns NULL if the string cannot be represented in the given rtype.*/
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC char *
|
2016-05-10 20:04:14 +00:00
|
|
|
fvalue_to_string_repr(wmem_allocator_t *scope, fvalue_t *fv, ftrepr_t rtype, int field_display);
|
2003-02-08 04:22:37 +00:00
|
|
|
|
2013-11-12 22:06:00 +00:00
|
|
|
WS_DLL_PUBLIC ftenum_t
|
|
|
|
fvalue_type_ftenum(fvalue_t *fv);
|
2006-05-02 14:26:17 +00:00
|
|
|
|
2001-02-01 20:21:25 +00:00
|
|
|
const char*
|
|
|
|
fvalue_type_name(fvalue_t *fv);
|
|
|
|
|
|
|
|
void
|
2014-01-15 01:05:03 +00:00
|
|
|
fvalue_set_byte_array(fvalue_t *fv, GByteArray *value);
|
|
|
|
|
|
|
|
void
|
|
|
|
fvalue_set_bytes(fvalue_t *fv, const guint8 *value);
|
|
|
|
|
|
|
|
void
|
|
|
|
fvalue_set_guid(fvalue_t *fv, const e_guid_t *value);
|
|
|
|
|
|
|
|
void
|
|
|
|
fvalue_set_time(fvalue_t *fv, const nstime_t *value);
|
|
|
|
|
|
|
|
void
|
|
|
|
fvalue_set_string(fvalue_t *fv, const gchar *value);
|
|
|
|
|
|
|
|
void
|
2016-05-03 01:44:48 +00:00
|
|
|
fvalue_set_protocol(fvalue_t *fv, tvbuff_t *value, const gchar *name);
|
2001-02-01 20:21:25 +00:00
|
|
|
|
|
|
|
void
|
2007-01-18 11:02:26 +00:00
|
|
|
fvalue_set_uinteger(fvalue_t *fv, guint32 value);
|
|
|
|
|
|
|
|
void
|
|
|
|
fvalue_set_sinteger(fvalue_t *fv, gint32 value);
|
2001-02-01 20:21:25 +00:00
|
|
|
|
2004-08-22 00:31:58 +00:00
|
|
|
void
|
2014-12-17 20:19:20 +00:00
|
|
|
fvalue_set_uinteger64(fvalue_t *fv, guint64 value);
|
|
|
|
|
|
|
|
void
|
|
|
|
fvalue_set_sinteger64(fvalue_t *fv, gint64 value);
|
2004-08-22 00:31:58 +00:00
|
|
|
|
2001-02-01 20:21:25 +00:00
|
|
|
void
|
|
|
|
fvalue_set_floating(fvalue_t *fv, gdouble value);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2001-02-01 20:21:25 +00:00
|
|
|
gpointer
|
|
|
|
fvalue_get(fvalue_t *fv);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC guint32
|
2007-01-18 11:02:26 +00:00
|
|
|
fvalue_get_uinteger(fvalue_t *fv);
|
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC gint32
|
2007-01-18 11:02:26 +00:00
|
|
|
fvalue_get_sinteger(fvalue_t *fv);
|
2001-02-01 20:21:25 +00:00
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC
|
2004-08-22 00:31:58 +00:00
|
|
|
guint64
|
2014-12-17 20:19:20 +00:00
|
|
|
fvalue_get_uinteger64(fvalue_t *fv);
|
|
|
|
|
|
|
|
WS_DLL_PUBLIC
|
|
|
|
gint64
|
|
|
|
fvalue_get_sinteger64(fvalue_t *fv);
|
2004-08-22 00:31:58 +00:00
|
|
|
|
2013-03-01 23:53:11 +00:00
|
|
|
WS_DLL_PUBLIC double
|
2001-02-01 20:21:25 +00:00
|
|
|
fvalue_get_floating(fvalue_t *fv);
|
|
|
|
|
|
|
|
gboolean
|
2012-11-06 13:28:59 +00:00
|
|
|
fvalue_eq(const fvalue_t *a, const fvalue_t *b);
|
2001-02-01 20:21:25 +00:00
|
|
|
|
|
|
|
gboolean
|
2012-11-06 13:28:59 +00:00
|
|
|
fvalue_ne(const fvalue_t *a, const fvalue_t *b);
|
2001-02-01 20:21:25 +00:00
|
|
|
|
|
|
|
gboolean
|
2012-11-06 13:28:59 +00:00
|
|
|
fvalue_gt(const fvalue_t *a, const fvalue_t *b);
|
2001-02-01 20:21:25 +00:00
|
|
|
|
|
|
|
gboolean
|
2012-11-06 13:28:59 +00:00
|
|
|
fvalue_ge(const fvalue_t *a, const fvalue_t *b);
|
2001-02-01 20:21:25 +00:00
|
|
|
|
|
|
|
gboolean
|
2012-11-06 13:28:59 +00:00
|
|
|
fvalue_lt(const fvalue_t *a, const fvalue_t *b);
|
2001-02-01 20:21:25 +00:00
|
|
|
|
|
|
|
gboolean
|
2012-11-06 13:28:59 +00:00
|
|
|
fvalue_le(const fvalue_t *a, const fvalue_t *b);
|
2001-02-01 20:21:25 +00:00
|
|
|
|
2004-02-27 12:00:32 +00:00
|
|
|
gboolean
|
2012-11-06 13:28:59 +00:00
|
|
|
fvalue_bitwise_and(const fvalue_t *a, const fvalue_t *b);
|
2004-02-27 12:00:32 +00:00
|
|
|
|
2003-08-27 15:23:11 +00:00
|
|
|
gboolean
|
2012-11-06 13:28:59 +00:00
|
|
|
fvalue_contains(const fvalue_t *a, const fvalue_t *b);
|
2003-08-27 15:23:11 +00:00
|
|
|
|
2003-12-06 16:35:20 +00:00
|
|
|
gboolean
|
2021-10-15 22:47:28 +00:00
|
|
|
fvalue_matches(const fvalue_t *a, const fvalue_regex_t *re);
|
|
|
|
|
|
|
|
fvalue_regex_t *
|
|
|
|
fvalue_regex_compile(const char *patt, char **errmsg);
|
|
|
|
|
|
|
|
gboolean
|
|
|
|
fvalue_regex_matches(const fvalue_regex_t *regex, const char *subj, gssize subj_size);
|
|
|
|
|
|
|
|
void
|
|
|
|
fvalue_regex_free(fvalue_regex_t *regex);
|
|
|
|
|
|
|
|
const char *
|
|
|
|
fvalue_regex_pattern(const fvalue_regex_t *regex);
|
2003-12-06 16:35:20 +00:00
|
|
|
|
2001-02-01 20:21:25 +00:00
|
|
|
guint
|
|
|
|
fvalue_length(fvalue_t *fv);
|
|
|
|
|
|
|
|
fvalue_t*
|
2013-03-05 06:16:45 +00:00
|
|
|
fvalue_slice(fvalue_t *fv, drange_t *dr);
|
2001-02-01 20:21:25 +00:00
|
|
|
|
2012-08-19 23:52:08 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif /* __cplusplus */
|
|
|
|
|
|
|
|
#endif /* __FTYPES_H__ */
|
2015-02-15 03:31:53 +00:00
|
|
|
|
|
|
|
/*
|
2019-07-26 18:43:17 +00:00
|
|
|
* Editor modelines - https://www.wireshark.org/tools/modelines.html
|
2015-02-15 03:31:53 +00:00
|
|
|
*
|
|
|
|
* Local variables:
|
|
|
|
* c-basic-offset: 8
|
|
|
|
* tab-width: 8
|
|
|
|
* indent-tabs-mode: t
|
|
|
|
* End:
|
|
|
|
*
|
|
|
|
* vi: set shiftwidth=8 tabstop=8 noexpandtab:
|
|
|
|
* :indentSize=8:tabSize=8:noTabs=false:
|
|
|
|
*/
|