|
Wireshark 4.7.0
The Wireshark network protocol analyzer
|
#include <wireshark.h>#include <stdio.h>#include <stdarg.h>Go to the source code of this file.
Classes | |
| struct | pbl_descriptor_pool_t |
| struct | pbl_file_descriptor_t |
| struct | pbl_node_t |
| struct | pbl_method_descriptor_t |
| struct | pbl_message_descriptor_t |
| struct | pbl_enum_value_descriptor_t |
| struct | pbl_field_descriptor_t |
Describes a field in a Protocol Buffer message, similar to google::protobuf::FieldDescriptor. More... | |
| struct | pbl_enum_descriptor_t |
| struct | pbl_option_descriptor_t |
| struct | _protobuf_lang_token_t |
| struct | _protobuf_lang_state_t |
Macros | |
| #define | PBL_DEFAULT_PACKAGE_NAME "" |
Typedefs | |
| typedef void(* | pbl_report_error_cb_t) (const char *msg_format,...) |
| typedef struct pbl_node_t | pbl_node_t |
| typedef struct _protobuf_lang_token_t | protobuf_lang_token_t |
| typedef struct _protobuf_lang_state_t | protobuf_lang_state_t |
Functions | |
| void | pbl_reinit_descriptor_pool (pbl_descriptor_pool_t **ppool, const char **directories, pbl_report_error_cb_t error_cb) |
| void | pbl_free_pool (pbl_descriptor_pool_t *pool) |
| Free a descriptor pool and its associated resources. | |
| bool | pbl_add_proto_file_to_be_parsed (pbl_descriptor_pool_t *pool, const char *filepath) |
| Adds a Protocol Buffers file to be parsed. | |
| int | run_pbl_parser (pbl_descriptor_pool_t *pool) |
| Runs the Protocol Buffers Language parser. | |
| const pbl_method_descriptor_t * | pbl_message_descriptor_pool_FindMethodByName (const pbl_descriptor_pool_t *pool, const char *name) |
| Finds a method descriptor by its name in a message descriptor pool. | |
| const char * | pbl_method_descriptor_name (const pbl_method_descriptor_t *method) |
| Retrieves the name of a method descriptor. | |
| const char * | pbl_method_descriptor_full_name (const pbl_method_descriptor_t *method) |
| Retrieves the full name of a method descriptor. | |
| const pbl_message_descriptor_t * | pbl_method_descriptor_input_type (const pbl_method_descriptor_t *method) |
| Retrieves the input message descriptor type for a method. | |
| const pbl_message_descriptor_t * | pbl_method_descriptor_output_type (const pbl_method_descriptor_t *method) |
| Retrieves the output type of a method descriptor. | |
| const pbl_message_descriptor_t * | pbl_message_descriptor_pool_FindMessageTypeByName (const pbl_descriptor_pool_t *pool, const char *name) |
| Finds a message descriptor by its name in a descriptor pool. | |
| const char * | pbl_message_descriptor_name (const pbl_message_descriptor_t *message) |
| Retrieves the name of a message descriptor. | |
| const char * | pbl_message_descriptor_full_name (const pbl_message_descriptor_t *message) |
| Retrieves the full name of a message descriptor. | |
| int | pbl_message_descriptor_field_count (const pbl_message_descriptor_t *message) |
| Get the count of fields in a message descriptor. | |
| const pbl_field_descriptor_t * | pbl_message_descriptor_field (const pbl_message_descriptor_t *message, int field_index) |
| Retrieves a field descriptor from a message descriptor by index. | |
| const pbl_field_descriptor_t * | pbl_message_descriptor_FindFieldByNumber (const pbl_message_descriptor_t *message, int number) |
| Finds a field descriptor by its number in a message descriptor. | |
| const pbl_field_descriptor_t * | pbl_message_descriptor_FindFieldByName (const pbl_message_descriptor_t *message, const char *name) |
| Finds a field descriptor by name in a message descriptor. | |
| const char * | pbl_field_descriptor_full_name (const pbl_field_descriptor_t *field) |
| Retrieves the full name of a field descriptor. | |
| const char * | pbl_field_descriptor_name (const pbl_field_descriptor_t *field) |
| Retrieves the name of a field descriptor. | |
| int | pbl_field_descriptor_number (const pbl_field_descriptor_t *field) |
| Retrieves the number associated with a field descriptor. | |
| int | pbl_field_descriptor_type (const pbl_field_descriptor_t *field) |
| Get the type of a field descriptor. | |
| int | pbl_field_descriptor_is_repeated (const pbl_field_descriptor_t *field) |
| Checks if a field descriptor is repeated. | |
| int | pbl_field_descriptor_is_packed (const pbl_field_descriptor_t *field) |
| Checks if a field descriptor is packed. | |
| const char * | pbl_field_descriptor_TypeName (wmem_allocator_t *scope, int field_type) |
| Retrieves the type name for a given field type. | |
| const pbl_message_descriptor_t * | pbl_field_descriptor_message_type (const pbl_field_descriptor_t *field) |
| Retrieves the message type descriptor for a field. | |
| const pbl_enum_descriptor_t * | pbl_field_descriptor_enum_type (const pbl_field_descriptor_t *field) |
| Get the enum descriptor for a field. | |
| bool | pbl_field_descriptor_is_required (const pbl_field_descriptor_t *field) |
| Checks if a field descriptor is required. | |
| bool | pbl_field_descriptor_has_default_value (const pbl_field_descriptor_t *field) |
| Checks if a field descriptor has a default value. | |
| int32_t | pbl_field_descriptor_default_value_int32 (const pbl_field_descriptor_t *field) |
| Retrieves the default value for an int32 field descriptor. | |
| int64_t | pbl_field_descriptor_default_value_int64 (const pbl_field_descriptor_t *field) |
| Retrieves the default value of a field descriptor as an int64. | |
| uint32_t | pbl_field_descriptor_default_value_uint32 (const pbl_field_descriptor_t *field) |
| Retrieves the default value of a field descriptor as a uint32. | |
| uint64_t | pbl_field_descriptor_default_value_uint64 (const pbl_field_descriptor_t *field) |
| Retrieves the default value of a field descriptor as a 64-bit unsigned integer. | |
| float | pbl_field_descriptor_default_value_float (const pbl_field_descriptor_t *field) |
| Retrieves the default value of a float field descriptor. | |
| double | pbl_field_descriptor_default_value_double (const pbl_field_descriptor_t *field) |
| Retrieves the default value of a double field descriptor. | |
| bool | pbl_field_descriptor_default_value_bool (const pbl_field_descriptor_t *field) |
| Retrieves the default value of a boolean field descriptor. | |
| const char * | pbl_field_descriptor_default_value_string (const pbl_field_descriptor_t *field, int *size) |
| Get the default value string of a Protocol Buffers field descriptor. | |
| const pbl_enum_value_descriptor_t * | pbl_field_descriptor_default_value_enum (const pbl_field_descriptor_t *field) |
| Retrieves the default value enum for a field descriptor. | |
| const char * | pbl_enum_descriptor_name (const pbl_enum_descriptor_t *anEnum) |
| Get the name of an enum descriptor. | |
| const char * | pbl_enum_descriptor_full_name (const pbl_enum_descriptor_t *anEnum) |
| Get the full name of an enum descriptor. | |
| int | pbl_enum_descriptor_value_count (const pbl_enum_descriptor_t *anEnum) |
| Get the count of values in an enum descriptor. | |
| const pbl_enum_value_descriptor_t * | pbl_enum_descriptor_value (const pbl_enum_descriptor_t *anEnum, int value_index) |
| Retrieves an enum value descriptor by its index. | |
| const pbl_enum_value_descriptor_t * | pbl_enum_descriptor_FindValueByNumber (const pbl_enum_descriptor_t *anEnum, int number) |
| Finds an enumeration value descriptor by its number. | |
| const pbl_enum_value_descriptor_t * | pbl_enum_descriptor_FindValueByName (const pbl_enum_descriptor_t *anEnum, const char *name) |
| Finds an enumeration value descriptor by name within a given enumeration descriptor. | |
| const char * | pbl_enum_value_descriptor_name (const pbl_enum_value_descriptor_t *enumValue) |
| Retrieves the name of an enum value descriptor. | |
| const char * | pbl_enum_value_descriptor_full_name (const pbl_enum_value_descriptor_t *enumValue) |
| Get the full name of an enum value descriptor. | |
| int | pbl_enum_value_descriptor_number (const pbl_enum_value_descriptor_t *enumValue) |
| Retrieves the number associated with an enum value descriptor. | |
| void | pbl_foreach_message (const pbl_descriptor_pool_t *pool, void(*cb)(const pbl_message_descriptor_t *, void *), void *userdata) |
| Iterates over all message descriptors in a descriptor pool. | |
| pbl_node_t * | pbl_create_node (pbl_file_descriptor_t *file, int lineno, pbl_node_type_t nodetype, const char *name) |
| Creates a new node in the Protocol Buffers language tree. | |
| pbl_node_t * | pbl_set_node_name (pbl_node_t *node, int lineno, const char *newname) |
| Set the name of a node. | |
| const char * | pbl_get_node_full_name (pbl_node_t *node) |
| Get the full name of a node. | |
| pbl_node_t * | pbl_add_child (pbl_node_t *parent, pbl_node_t *child) |
| Adds a child node to a parent node. | |
| pbl_node_t * | pbl_create_enum_value_node (pbl_file_descriptor_t *file, int lineno, const char *name, int number) |
| Create a new enum value node. | |
| pbl_node_t * | pbl_merge_children (pbl_node_t *to, pbl_node_t *from) |
| Merges children from one node to another. | |
| pbl_node_t * | pbl_create_field_node (pbl_file_descriptor_t *file, int lineno, const char *label, const char *type_name, const char *name, int number, pbl_node_t *options) |
| Create a field node for a Protocol Buffers message. | |
| pbl_node_t * | pbl_create_map_field_node (pbl_file_descriptor_t *file, int lineno, const char *name, int number, pbl_node_t *options) |
| Create a map field node in the Protocol Buffers language tree. | |
| pbl_node_t * | pbl_create_method_node (pbl_file_descriptor_t *file, int lineno, const char *name, const char *in_msg_type, bool in_is_stream, const char *out_msg_type, bool out_is_stream) |
| Create a method node for Protocol Buffers. | |
| pbl_node_t * | pbl_create_option_node (pbl_file_descriptor_t *file, int lineno, const char *name, const char *value) |
| Creates a new option node for Protocol Buffers Language Tree. | |
| void | pbl_free_node (void *anode) |
| Frees a protocol buffer language tree node. | |
Routines of building and reading Protocol Buffers Language grammar tree. Copyright 2019, Huang Qiangxiong qiang.nosp@m.xion.nosp@m.g.hua.nosp@m.ng@q.nosp@m.q.com
Wireshark - Network traffic analyzer By Gerald Combs geral.nosp@m.d@wi.nosp@m.resha.nosp@m.rk.o.nosp@m.rg Copyright 1998 Gerald Combs
SPDX-License-Identifier: GPL-2.0-or-later
| pbl_node_t * pbl_add_child | ( | pbl_node_t * | parent, |
| pbl_node_t * | child | ||
| ) |
Adds a child node to a parent node.
| parent | The parent node to which the child will be added. |
| child | The child node to add. |
| bool pbl_add_proto_file_to_be_parsed | ( | pbl_descriptor_pool_t * | pool, |
| const char * | filepath | ||
| ) |
Adds a Protocol Buffers file to be parsed.
| pool | The descriptor pool to which the file will be added. |
| filepath | The path to the Protocol Buffers file. |
| pbl_node_t * pbl_create_enum_value_node | ( | pbl_file_descriptor_t * | file, |
| int | lineno, | ||
| const char * | name, | ||
| int | number | ||
| ) |
Create a new enum value node.
| file | The file descriptor associated with this node. |
| lineno | The line number in the source code where this node is created. |
| name | The name of the enum value. |
| number | The numeric value of the enum. |
| pbl_node_t * pbl_create_field_node | ( | pbl_file_descriptor_t * | file, |
| int | lineno, | ||
| const char * | label, | ||
| const char * | type_name, | ||
| const char * | name, | ||
| int | number, | ||
| pbl_node_t * | options | ||
| ) |
Create a field node for a Protocol Buffers message.
| file | The file descriptor associated with the message. |
| lineno | The line number in the source code where this function is called. |
| label | The label of the field, indicating if it's required, repeated, or optional. |
| type_name | The name of the data type of the field. |
| name | The name of the field. |
| number | The unique identifier for the field within the message. |
| options | A node containing additional options for the field. |
| pbl_node_t * pbl_create_map_field_node | ( | pbl_file_descriptor_t * | file, |
| int | lineno, | ||
| const char * | name, | ||
| int | number, | ||
| pbl_node_t * | options | ||
| ) |
Create a map field node in the Protocol Buffers language tree.
| file | Pointer to the file descriptor. |
| lineno | Line number where this node is defined. |
| name | Name of the map field. |
| number | Field number. |
| options | Options for the map field. |
| pbl_node_t * pbl_create_method_node | ( | pbl_file_descriptor_t * | file, |
| int | lineno, | ||
| const char * | name, | ||
| const char * | in_msg_type, | ||
| bool | in_is_stream, | ||
| const char * | out_msg_type, | ||
| bool | out_is_stream | ||
| ) |
Create a method node for Protocol Buffers.
| file | Pointer to the file descriptor. |
| lineno | Line number in the source code. |
| name | Name of the method. |
| in_msg_type | Type of the input message. |
| in_is_stream | Indicates if the input is a stream. |
| out_msg_type | Type of the output message. |
| out_is_stream | Indicates if the output is a stream. |
| pbl_node_t * pbl_create_node | ( | pbl_file_descriptor_t * | file, |
| int | lineno, | ||
| pbl_node_type_t | nodetype, | ||
| const char * | name | ||
| ) |
Creates a new node in the Protocol Buffers language tree.
| file | The file descriptor associated with the node. |
| lineno | The line number where the node is defined. |
| nodetype | The type of the node to create. |
| name | The name of the node. |
| pbl_node_t * pbl_create_option_node | ( | pbl_file_descriptor_t * | file, |
| int | lineno, | ||
| const char * | name, | ||
| const char * | value | ||
| ) |
Creates a new option node for Protocol Buffers Language Tree.
| file | Pointer to the file descriptor. |
| lineno | Line number where the node is created. |
| name | Name of the option. |
| value | Value of the option, can be NULL. |
| const pbl_enum_value_descriptor_t * pbl_enum_descriptor_FindValueByName | ( | const pbl_enum_descriptor_t * | anEnum, |
| const char * | name | ||
| ) |
Finds an enumeration value descriptor by name within a given enumeration descriptor.
| anEnum | Pointer to the enumeration descriptor. |
| name | The name of the enumeration value descriptor to find. |
| const pbl_enum_value_descriptor_t * pbl_enum_descriptor_FindValueByNumber | ( | const pbl_enum_descriptor_t * | anEnum, |
| int | number | ||
| ) |
Finds an enumeration value descriptor by its number.
| anEnum | Pointer to the enumeration descriptor. |
| number | The number of the enumeration value to find. |
| const char * pbl_enum_descriptor_full_name | ( | const pbl_enum_descriptor_t * | anEnum | ) |
Get the full name of an enum descriptor.
| anEnum | Pointer to the enum descriptor. |
| const char * pbl_enum_descriptor_name | ( | const pbl_enum_descriptor_t * | anEnum | ) |
Get the name of an enum descriptor.
| anEnum | Pointer to the enum descriptor. |
| const pbl_enum_value_descriptor_t * pbl_enum_descriptor_value | ( | const pbl_enum_descriptor_t * | anEnum, |
| int | value_index | ||
| ) |
Retrieves an enum value descriptor by its index.
| anEnum | Pointer to the enum descriptor. |
| value_index | Index of the enum value descriptor to retrieve. |
| int pbl_enum_descriptor_value_count | ( | const pbl_enum_descriptor_t * | anEnum | ) |
Get the count of values in an enum descriptor.
| anEnum | Pointer to the enum descriptor. |
| const char * pbl_enum_value_descriptor_full_name | ( | const pbl_enum_value_descriptor_t * | enumValue | ) |
Get the full name of an enum value descriptor.
| enumValue | Pointer to the enum value descriptor. |
| const char * pbl_enum_value_descriptor_name | ( | const pbl_enum_value_descriptor_t * | enumValue | ) |
Retrieves the name of an enum value descriptor.
| enumValue | Pointer to the enum value descriptor. |
| int pbl_enum_value_descriptor_number | ( | const pbl_enum_value_descriptor_t * | enumValue | ) |
Retrieves the number associated with an enum value descriptor.
| enumValue | Pointer to the enum value descriptor. |
| bool pbl_field_descriptor_default_value_bool | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the default value of a boolean field descriptor.
| field | Pointer to the field descriptor. |
| double pbl_field_descriptor_default_value_double | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the default value of a double field descriptor.
| field | Pointer to the field descriptor. |
| const pbl_enum_value_descriptor_t * pbl_field_descriptor_default_value_enum | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the default value enum for a field descriptor.
| field | The field descriptor to query. |
| float pbl_field_descriptor_default_value_float | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the default value of a float field descriptor.
| field | Pointer to the pbl_field_descriptor_t structure. |
| int32_t pbl_field_descriptor_default_value_int32 | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the default value for an int32 field descriptor.
| field | Pointer to the pbl_field_descriptor_t structure. |
| int64_t pbl_field_descriptor_default_value_int64 | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the default value of a field descriptor as an int64.
| field | Pointer to the pbl_field_descriptor_t structure. |
| const char * pbl_field_descriptor_default_value_string | ( | const pbl_field_descriptor_t * | field, |
| int * | size | ||
| ) |
Get the default value string of a Protocol Buffers field descriptor.
| field | Pointer to the Protocol Buffers field descriptor. |
| size | Pointer to an integer where the length of the default value string will be stored. |
| uint32_t pbl_field_descriptor_default_value_uint32 | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the default value of a field descriptor as a uint32.
| field | The field descriptor from which to retrieve the default value. |
| uint64_t pbl_field_descriptor_default_value_uint64 | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the default value of a field descriptor as a 64-bit unsigned integer.
| field | Pointer to the field descriptor. |
| const pbl_enum_descriptor_t * pbl_field_descriptor_enum_type | ( | const pbl_field_descriptor_t * | field | ) |
Get the enum descriptor for a field.
| field | The field descriptor to query. |
| const char * pbl_field_descriptor_full_name | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the full name of a field descriptor.
| field | Pointer to the field descriptor. |
| bool pbl_field_descriptor_has_default_value | ( | const pbl_field_descriptor_t * | field | ) |
Checks if a field descriptor has a default value.
| field | The field descriptor to check. |
| int pbl_field_descriptor_is_packed | ( | const pbl_field_descriptor_t * | field | ) |
Checks if a field descriptor is packed.
| field | The field descriptor to check. |
| int pbl_field_descriptor_is_repeated | ( | const pbl_field_descriptor_t * | field | ) |
Checks if a field descriptor is repeated.
| field | Pointer to the field descriptor. |
| bool pbl_field_descriptor_is_required | ( | const pbl_field_descriptor_t * | field | ) |
Checks if a field descriptor is required.
| field | The field descriptor to check. |
| const pbl_message_descriptor_t * pbl_field_descriptor_message_type | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the message type descriptor for a field.
| field | The field descriptor to query. |
| const char * pbl_field_descriptor_name | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the name of a field descriptor.
| field | Pointer to the field descriptor. |
| int pbl_field_descriptor_number | ( | const pbl_field_descriptor_t * | field | ) |
Retrieves the number associated with a field descriptor.
| field | Pointer to the field descriptor structure. |
| int pbl_field_descriptor_type | ( | const pbl_field_descriptor_t * | field | ) |
Get the type of a field descriptor.
| field | The field descriptor to query. |
| const char * pbl_field_descriptor_TypeName | ( | wmem_allocator_t * | scope, |
| int | field_type | ||
| ) |
Retrieves the type name for a given field type.
| scope | Memory allocator scope. |
| field_type | The field type to retrieve the type name for. |
| void pbl_foreach_message | ( | const pbl_descriptor_pool_t * | pool, |
| void(*)(const pbl_message_descriptor_t *, void *) | cb, | ||
| void * | userdata | ||
| ) |
Iterates over all message descriptors in a descriptor pool.
| pool | The descriptor pool to iterate over. |
| cb | Callback function to call for each message descriptor. |
| userdata | User data to pass to the callback function. |
| void pbl_free_node | ( | void * | anode | ) |
Frees a protocol buffer language tree node.
This function releases all resources associated with a given protocol buffer language tree node and sets it to NULL.
| anode | Pointer to the node to be freed. |
| void pbl_free_pool | ( | pbl_descriptor_pool_t * | pool | ) |
Free a descriptor pool and its associated resources.
| pool | The descriptor pool to free. |
| const char * pbl_get_node_full_name | ( | pbl_node_t * | node | ) |
Get the full name of a node.
| node | The node to get the full name for. |
| pbl_node_t * pbl_merge_children | ( | pbl_node_t * | to, |
| pbl_node_t * | from | ||
| ) |
Merges children from one node to another.
This function merges all children from the 'from' node into the 'to' node. It then frees the resources associated with the 'from' node's children.
| to | The target node to which children will be added. |
| from | The source node from which children will be taken. |
| const pbl_field_descriptor_t * pbl_message_descriptor_field | ( | const pbl_message_descriptor_t * | message, |
| int | field_index | ||
| ) |
Retrieves a field descriptor from a message descriptor by index.
| message | The message descriptor to search. |
| field_index | The index of the field descriptor to retrieve. |
| int pbl_message_descriptor_field_count | ( | const pbl_message_descriptor_t * | message | ) |
Get the count of fields in a message descriptor.
| message | Pointer to the message descriptor. |
| const pbl_field_descriptor_t * pbl_message_descriptor_FindFieldByName | ( | const pbl_message_descriptor_t * | message, |
| const char * | name | ||
| ) |
Finds a field descriptor by name in a message descriptor.
| message | The message descriptor to search within. |
| name | The name of the field descriptor to find. |
| const pbl_field_descriptor_t * pbl_message_descriptor_FindFieldByNumber | ( | const pbl_message_descriptor_t * | message, |
| int | number | ||
| ) |
Finds a field descriptor by its number in a message descriptor.
| message | The message descriptor to search within. |
| number | The number of the field descriptor to find. |
| const char * pbl_message_descriptor_full_name | ( | const pbl_message_descriptor_t * | message | ) |
Retrieves the full name of a message descriptor.
| message | Pointer to the message descriptor. |
| const char * pbl_message_descriptor_name | ( | const pbl_message_descriptor_t * | message | ) |
Retrieves the name of a message descriptor.
| message | Pointer to the message descriptor. |
| const pbl_message_descriptor_t * pbl_message_descriptor_pool_FindMessageTypeByName | ( | const pbl_descriptor_pool_t * | pool, |
| const char * | name | ||
| ) |
Finds a message descriptor by its name in a descriptor pool.
| pool | The descriptor pool to search within. |
| name | The name of the message descriptor to find. |
| const pbl_method_descriptor_t * pbl_message_descriptor_pool_FindMethodByName | ( | const pbl_descriptor_pool_t * | pool, |
| const char * | name | ||
| ) |
Finds a method descriptor by its name in a message descriptor pool.
| pool | The message descriptor pool to search within. |
| name | The name of the method descriptor to find. |
| const char * pbl_method_descriptor_full_name | ( | const pbl_method_descriptor_t * | method | ) |
Retrieves the full name of a method descriptor.
| method | Pointer to the method descriptor. |
| const pbl_message_descriptor_t * pbl_method_descriptor_input_type | ( | const pbl_method_descriptor_t * | method | ) |
Retrieves the input message descriptor type for a method.
| method | Pointer to the method descriptor. |
| const char * pbl_method_descriptor_name | ( | const pbl_method_descriptor_t * | method | ) |
Retrieves the name of a method descriptor.
| method | Pointer to the method descriptor. |
| const pbl_message_descriptor_t * pbl_method_descriptor_output_type | ( | const pbl_method_descriptor_t * | method | ) |
Retrieves the output type of a method descriptor.
| method | The method descriptor to query. |
| void pbl_reinit_descriptor_pool | ( | pbl_descriptor_pool_t ** | ppool, |
| const char ** | directories, | ||
| pbl_report_error_cb_t | error_cb | ||
| ) |
Reinitialize the protocol buffers pool according to proto files directories.
| ppool | The output descriptor_pool will be created. If *pool is not NULL, it will free it first. |
| directories | The root directories containing proto files. Must end with NULL element. |
| error_cb | The error reporter callback function. |
| pbl_node_t * pbl_set_node_name | ( | pbl_node_t * | node, |
| int | lineno, | ||
| const char * | newname | ||
| ) |
Set the name of a node.
| node | Pointer to the node whose name is to be set. |
| lineno | Line number where this function was called (for debugging purposes). |
| newname | New name for the node. |
| int run_pbl_parser | ( | pbl_descriptor_pool_t * | pool | ) |
Runs the Protocol Buffers Language parser.
| pool | The descriptor pool to parse. |