Solver functions. More...
#include <gnunet_ats_plugin.h>
Data Fields | |
void * | cls |
Closure to pass to all solver functions in this struct. More... | |
GAS_solver_address_add | s_add |
Add a new address for a peer to the solver. More... | |
GAS_solver_address_property_changed | s_address_update_property |
Update the properties of an address in the solver. More... | |
GAS_solver_get_preferred_address | s_get |
Tell solver to notify ATS if the address to use changes for a specific peer using the bandwidth changed callback. More... | |
GAS_solver_stop_get_preferred_address | s_get_stop |
Tell solver stop notifying ATS about changes for this peers. More... | |
GAS_solver_address_delete | s_del |
Delete an address in the solver. More... | |
GAS_solver_address_change_preference | s_pref |
Change relative preference for quality in solver. More... | |
GAS_solver_address_feedback_preference | s_feedback |
Give feedback about the current assignment. More... | |
GAS_solver_bulk_start | s_bulk_start |
Start a bulk operation. More... | |
GAS_solver_bulk_stop | s_bulk_stop |
Bulk operation done. More... | |
Solver functions.
Each solver is required to set up and return an instance of this struct during initialization.
Definition at line 174 of file gnunet_ats_plugin.h.
void* GNUNET_ATS_SolverFunctions::cls |
Closure to pass to all solver functions in this struct.
Definition at line 179 of file gnunet_ats_plugin.h.
Referenced by enforce_add_address(), enforce_del_address(), enforce_start_request(), enforce_stop_request(), GAS_plugin_delete_address(), GAS_plugin_new_address(), GAS_plugin_notify_feedback(), GAS_plugin_notify_preference_changed(), GAS_plugin_notify_property_changed(), GAS_plugin_request_connect_start(), GAS_plugin_request_connect_stop(), GAS_plugin_solver_lock(), GAS_plugin_solver_unlock(), libgnunet_plugin_ats_proportional_done(), libgnunet_plugin_ats_proportional_init(), set_feedback_task(), set_pref_task(), and set_prop_task().
GAS_solver_address_add GNUNET_ATS_SolverFunctions::s_add |
Add a new address for a peer to the solver.
The address is already contained in the addresses hashmap!
Definition at line 186 of file gnunet_ats_plugin.h.
Referenced by enforce_add_address(), GAS_plugin_new_address(), and libgnunet_plugin_ats_proportional_init().
GAS_solver_address_property_changed GNUNET_ATS_SolverFunctions::s_address_update_property |
Update the properties of an address in the solver.
Definition at line 191 of file gnunet_ats_plugin.h.
Referenced by GAS_plugin_notify_property_changed(), libgnunet_plugin_ats_proportional_init(), and set_prop_task().
GAS_solver_get_preferred_address GNUNET_ATS_SolverFunctions::s_get |
Tell solver to notify ATS if the address to use changes for a specific peer using the bandwidth changed callback.
The solver must only notify about changes for peers with pending address requests!
Definition at line 200 of file gnunet_ats_plugin.h.
Referenced by enforce_start_request(), GAS_plugin_request_connect_start(), and libgnunet_plugin_ats_proportional_init().
GAS_solver_stop_get_preferred_address GNUNET_ATS_SolverFunctions::s_get_stop |
Tell solver stop notifying ATS about changes for this peers.
The solver must only notify about changes for peers with pending address requests!
Definition at line 208 of file gnunet_ats_plugin.h.
Referenced by enforce_stop_request(), GAS_plugin_request_connect_stop(), and libgnunet_plugin_ats_proportional_init().
GAS_solver_address_delete GNUNET_ATS_SolverFunctions::s_del |
Delete an address in the solver.
The address is not contained in the address hashmap anymore!
Definition at line 215 of file gnunet_ats_plugin.h.
Referenced by enforce_del_address(), GAS_plugin_delete_address(), and libgnunet_plugin_ats_proportional_init().
GAS_solver_address_change_preference GNUNET_ATS_SolverFunctions::s_pref |
Change relative preference for quality in solver.
Definition at line 220 of file gnunet_ats_plugin.h.
Referenced by GAS_plugin_notify_preference_changed(), libgnunet_plugin_ats_proportional_init(), and set_pref_task().
GAS_solver_address_feedback_preference GNUNET_ATS_SolverFunctions::s_feedback |
Give feedback about the current assignment.
Definition at line 225 of file gnunet_ats_plugin.h.
Referenced by GAS_plugin_notify_feedback(), libgnunet_plugin_ats_proportional_init(), and set_feedback_task().
GAS_solver_bulk_start GNUNET_ATS_SolverFunctions::s_bulk_start |
Start a bulk operation.
Used if many values have to be updated at the same time. When a bulk operation is pending the solver does not have to resolve the problem since more updates will follow anyway
For each call to bulk_start, a call to bulk_stop is required!
Definition at line 236 of file gnunet_ats_plugin.h.
Referenced by GAS_plugin_solver_lock(), libgnunet_plugin_ats_proportional_init(), and set_prop_task().
GAS_solver_bulk_stop GNUNET_ATS_SolverFunctions::s_bulk_stop |
Bulk operation done.
If no more bulk operations are pending, the solver can solve the problem with the updated values
Definition at line 244 of file gnunet_ats_plugin.h.
Referenced by GAS_plugin_solver_unlock(), libgnunet_plugin_ats_proportional_init(), and set_prop_task().