35#ifndef ATTRIBUTE_RESOLVER_H
36#define ATTRIBUTE_RESOLVER_H
61 void (*send_init)(void);
63 const uint8_t *frame_data,
64 uint16_t frame_data_len,
77#define MAX_FRAME_LEN 255
uint32_t attribute_store_type_t
Definition: attribute_store.h:50
sl_status_t(* attribute_resolver_function_t)(attribute_store_node_t node, uint8_t *frame, uint16_t *frame_len)
Generator function for building PAN frames.
Definition: attribute_resolver.h:111
bool attribute_resolver_node_or_child_needs_resolution(attribute_store_node_t node)
Verifies if the provided node, or any of its child needs resolution.
void attribute_resolver_pause_node_resolution(attribute_store_node_t node)
Pause the resolution on a given node.
sl_status_t attribute_resolver_set_attribute_depth(attribute_store_type_t node_type, int depth)
Set the relative depth of an attribute in the attribute tree.
void attribute_resolver_resume_node_resolution(attribute_store_node_t node)
Resume the resolution on a given node.
void attribute_resolver_set_resolution_listener(attribute_store_node_t node, attribute_resolver_callback_t callback)
Register a listener to be called when a node and all its children has been resolved.
attribute_resolver_config_t attribute_resolver_get_config()
returns the current configuration for the attribute resolver
void attribute_resolver_clear_resolution_listener(attribute_store_node_t node, attribute_resolver_callback_t callback)
Clear a node resolve listener.
void attribute_resolver_set_resolution_resumption_listener(attribute_store_node_t node, attribute_resolver_callback_t callback)
Sets a listener for unpausing nodes.
void attribute_resolver_clear_resolution_resumption_listener(attribute_store_node_t node, attribute_resolver_callback_t callback)
Sets a listener for unpausing nodes.
sl_status_t attribute_resolver_restart_set_resolution(attribute_store_node_t node)
Instructs the resolver to try to resolve a set rule that was pending.
sl_status_t attribute_resolver_init(attribute_resolver_config_t resolver_config)
Initialize the attribute resolver. This function will clear the rulebook and reset the resolver state...
void attribute_resolver_state_log()
Log the state of the Attribute Resolver using Unify Logging system.
sl_status_t attribute_resolver_restart_get_resolution(attribute_store_node_t node)
Instructs the resolver to try to resolve a get rule that was pending.
int attribute_resolver_teardown()
Teardown the attribute resolver.
void(* attribute_resolver_callback_t)(attribute_store_node_t node)
A callback type for notifying about resolver events.
Definition: attribute_resolver.h:48
void attribute_resolver_set_resolution_give_up_listener(attribute_store_type_t node_type, attribute_resolver_callback_t callback)
Registers a listener that will be informed if we give up trying to perform a Get resolution on a node...
bool is_node_or_parent_paused(attribute_store_node_t node)
This function traverses attribute store to check if any parent of the attribute node is paused or not...
bool is_node_pending_set_resolution(attribute_store_node_t node)
Returns true if a node is pending a set resolution. i.e. command has been sent and we are waiting for...
sl_status_t attribute_resolver_register_rule(attribute_store_type_t node_type, attribute_resolver_function_t set_func, attribute_resolver_function_t get_func)
Register an attribute rule.
datastore_attribute_id_t attribute_store_node_t
Handle to identify attribute store nodes.
Definition: attribute_store.h:101
uint32_t sl_status_t
Definition: sl_status.h:139
Definition: attribute_resolver.h:60
uint8_t get_retry_count
Definition: attribute_resolver.h:70
clock_time_t get_retry_timeout
Definition: attribute_resolver.h:68