14#include "ws_symbol_export.h"
20#define SUBTREE_UNDEFINED_LENGTH -1
231ptvcursor_add_with_subtree(
ptvcursor_t* ptvc,
int hfindex,
int length,
232 const unsigned encoding,
int ett_subtree);
251 int ett_subtree,
const char* format, ...)
WS_DLL_PUBLIC proto_item * ptvcursor_add(ptvcursor_t *ptvc, int hf, int length, const unsigned encoding)
Adds data from tvbuff to proto_tree and increments offset.
Definition proto.c:4398
WS_DLL_PUBLIC proto_item * ptvcursor_add_ret_boolean(ptvcursor_t *ptvc, int hf, unsigned length, const unsigned encoding, bool *retval)
Adds a boolean value to the protocol tree and returns it.
Definition proto.c:3637
WS_DLL_PUBLIC tvbuff_t * ptvcursor_tvbuff(ptvcursor_t *ptvc)
Retrieves the tvbuff associated with the protocol tree cursor.
Definition proto.c:1322
WS_DLL_PUBLIC proto_tree * ptvcursor_tree(ptvcursor_t *ptvc)
Returns the current proto_tree associated with the ptvcursor.
Definition proto.c:1335
WS_DLL_PUBLIC proto_tree * ptvcursor_set_subtree(ptvcursor_t *ptvc, proto_item *it, int ett_subtree)
Sets a new subtree for the protocol tree cursor.
Definition proto.c:1397
WS_DLL_PUBLIC proto_item * ptvcursor_add_ret_int(ptvcursor_t *ptvc, int hf, unsigned length, const unsigned encoding, int32_t *retval)
Adds an integer value to the protocol tree and returns it.
Definition proto.c:3527
WS_DLL_PUBLIC void ptvcursor_advance(ptvcursor_t *ptvc, unsigned length)
Advances the ptvcursor's offset within its tvbuff without adding anything to the proto_tree.
Definition proto.c:4785
WS_DLL_PUBLIC proto_tree * ptvcursor_add_text_with_subtree(ptvcursor_t *ptvc, int length, int ett_subtree, const char *format,...)
Adds text with a subtree to the cursor.
Definition proto.c:1436
WS_DLL_PUBLIC proto_item * ptvcursor_add_no_advance(ptvcursor_t *ptvc, int hf, int length, const unsigned encoding)
Adds a new item to the protocol tree without advancing the cursor.
Definition proto.c:4771
WS_DLL_PUBLIC void ptvcursor_pop_subtree(ptvcursor_t *ptvc)
Pops a subtree from the protocol tree cursor.
Definition proto.c:1366
WS_DLL_PUBLIC ptvcursor_t * ptvcursor_new(wmem_allocator_t *scope, proto_tree *tree, tvbuff_t *tvb, unsigned offset)
Creates a new protocol tree cursor.
Definition proto.c:1296
WS_DLL_PUBLIC unsigned ptvcursor_current_offset(ptvcursor_t *ptvc)
Returns the current offset in the protocol tree cursor.
Definition proto.c:1329
WS_DLL_PUBLIC proto_item * ptvcursor_add_ret_uint(ptvcursor_t *ptvc, int hf, unsigned length, const unsigned encoding, uint32_t *retval)
Adds a uint32_t value to the protocol tree and returns it.
Definition proto.c:3470
WS_DLL_PUBLIC proto_tree * ptvcursor_push_subtree(ptvcursor_t *ptvc, proto_item *it, int ett_subtree)
Pushes a subtree onto the tree stack of the cursor.
Definition proto.c:1351
WS_DLL_PUBLIC proto_item * ptvcursor_add_ret_string(ptvcursor_t *ptvc, int hf, int length, const unsigned encoding, wmem_allocator_t *scope, const uint8_t **retval)
Adds a string to the protocol tree and returns the proto_item* and the retrieved string value.
Definition proto.c:3586
WS_DLL_PUBLIC void ptvcursor_free(ptvcursor_t *ptvc)
Frees a ptvcursor_t structure.
Definition proto.c:1314
WS_DLL_PUBLIC void ptvcursor_set_tree(ptvcursor_t *ptvc, proto_tree *tree)
Sets a new proto_tree* for the ptvcursor_t.
Definition proto.c:1344
Internal memory allocator interface used by the wmem subsystem.
Definition wmem_allocator.h:34
Definition tvbuff-int.h:33