|
DATASRCAPI void | ds5_add_connectionlistener (ds5_connectionlistener_t *connection_listener, void *context) |
| Adds a connection listener. The listener receives status events about the state of the DataSource application's connection to other peers. More...
|
|
DATASRCAPI void | ds5_config_init (const char *configfile, int argc, char **argv) |
| Sets up the configuration of the DataSource. More...
|
|
DATASRCAPI ds5_publisher_t * | ds5_create_active_publisher (ds5_namespace_t *nspace, ds5_dataprovider_t *provider, void *context) |
| Creates a data publisher that for a given subject sends multiple subscription requests and a single subscription discard to a ds5_dataprovider_t. More...
|
|
DATASRCAPI ds5_subscription_t * | ds5_create_active_subscription (const char *subject, ds5_subscriptionlistener_t *listener, void *context) |
| Create a subscription that matches a single subject. More...
|
|
DATASRCAPI ds5_publisher_t * | ds5_create_broadcast_publisher (ds5_namespace_t *nspace) |
| Creates a data publisher that allows a DataSource application to broadcast updates to remote DataSource peers regardless of whether they have requested (subscribed to) the subject. More...
|
|
DATASRCAPI ds5_subscription_t * | ds5_create_broadcast_subscription (ds5_namespace_t *nspace, ds5_subscriptionlistener_t *listener, void *context) |
| Create a subscription that matches multiple subjects. More...
|
|
DATASRCAPI ds5_publisher_t * | ds5_create_compatibility_publisher (ds5_namespace_t *nspace, ds5_dataprovider_t *provider, void *context) |
| Creates a data publisher that, for a given subject sends multiple subscription requests and multiple subscription discards to a ds5_dataprovider_t. More...
|
|
DATASRCAPI ds5_namespace_t * | ds5_create_globbed_namespace (const char *globbed) |
| Creates a DataSource namespace which will match subject names using globbing. More...
|
|
DATASRCAPI ds5_namespace_t * | ds5_create_prefix_namespace (const char *prefix) |
| Creates a DataSource namespace which will match subject names based on their prefix. More...
|
|
DATASRCAPI ds5_namespace_t * | ds5_create_regex_namespace (const char *expr) |
| Creates a DataSource namespace which will match subject names using a regular expression. More...
|
|
DATASRCAPI int | ds5_init (int argc, char **argv) |
| Parses the DataSource configuration files and initialises the DataSource library. The configuration is that supplied in the configuration file passed to ds5_config_init() with the addition of any configureation items supplied within argv. More...
|
|
DATASRCAPI void | ds5_publish_response (ds5_publisher_t *pub, ds_data_t *dsdata) |
| Publish an initial response (for example, an image of the subject's data) following a request for a subscription request from a peer. More...
|
|
DATASRCAPI void | ds5_publish_response_no_free (ds5_publisher_t *pub, ds_data_t *dsdata) |
| Publish an initial response (for example, an image of the subject's data) following a request for a subscription request from a peer. The response will not be freed. More...
|
|
DATASRCAPI void | ds5_publish_status (ds5_publisher_t *pub, const char *subject, int status, const char *message) |
| Publishes a subscription status event for a subject. More...
|
|
DATASRCAPI void | ds5_publish_status_all (ds5_publisher_t *pub, int status, const char *message) |
| Publishes a subscription status event for all requested subjects. More...
|
|
DATASRCAPI void | ds5_publish_subject_error (ds5_publisher_t *publisher, const char *subject, int flags) |
| Publishes a subscription error event for a subject. More...
|
|
DATASRCAPI void | ds5_publish_subject_map (ds5_publisher_t *publisher, const char *subject, const char *mapped_to, int flags) |
| Publishes a subscription map event for a subject. More...
|
|
DATASRCAPI void | ds5_publish_to_peer (ds5_publisher_t *publisher, int peernum, ds_data_t *dsdata) |
| Publish an update for a subject to the specified peer. More...
|
|
DATASRCAPI void | ds5_publish_to_peer_no_free (ds5_publisher_t *publisher, int peernum, ds_data_t *dsdata) |
| Publish an update for a subject to the specified peer. The update will not be freed. More...
|
|
DATASRCAPI void | ds5_publish_to_subscribed_peers (ds5_publisher_t *pub, ds_data_t *dsdata) |
| Publish an update for a subject to all peers that have subscribed. More...
|
|
DATASRCAPI void | ds5_publish_to_subscribed_peers_no_free (ds5_publisher_t *pub, ds_data_t *dsdata) |
| Publish an update for a subject to all peers that have subscribed. The update will not be freed. More...
|
|
DATASRCAPI int | ds5_regex_namespace_add_expr (ds5_namespace_t *nspace, const char *expr, int exclude) |
| Adds a regular expression to a namespace. More...
|
|
DATASRCAPI void | ds5_unsubscribe (ds5_subscription_t *sub) |
| Unsubscribe from the DataSource subject or namespace of DataSource subjects. More...
|
|
DATASRCAPI sock_t | ds_accept_socket (sock_t fd) |
| Accepts a connection from a listen socket. More...
|
|
DATASRCAPI void | ds_add_binary (ds_data_t *data, int32_t fieldnum, char *value, int len, char type) |
| Adds a binary value to a data object. More...
|
|
DATASRCAPI void | ds_add_binary_float32 (ds_data_t *data, int32_t fieldnum, float value) |
| Add a value to a data object in the form of a floating point number. More...
|
|
DATASRCAPI void | ds_add_binary_float64 (ds_data_t *data, int32_t fieldnum, double value) |
| Add a value to a data object in the form of a floating point number. More...
|
|
DATASRCAPI void | ds_add_binary_int16 (ds_data_t *data, int32_t fieldnum, int16_t value) |
| Add a value to a data object in the form of a 16 bit integer. More...
|
|
DATASRCAPI void | ds_add_binary_int32 (ds_data_t *data, int32_t fieldnum, int32_t value) |
| Add a value to a data object in the form of a 32 bit integer. More...
|
|
DATASRCAPI void | ds_add_binary_int64 (ds_data_t *data, int32_t fieldnum, int64_t value) |
| Add a value to a data object in the form of a 64 bit integer. More...
|
|
DATASRCAPI void | ds_add_binary_int8 (ds_data_t *data, int32_t fieldnum, int8_t value) |
| Add a value to a data object in the form of an 8 bit integer. More...
|
|
DATASRCAPI void | ds_add_binary_opaque (ds_data_t *data, int32_t fieldnum, char *value, int len) |
| Add a value to a data object in the form of an opaque value. More...
|
|
DATASRCAPI void | ds_add_binary_string (ds_data_t *data, int32_t fieldnum, char *value) |
| Add a value to a data object in the form of a string. More...
|
|
DATASRCAPI void | ds_add_binary_time (ds_data_t *data, int32_t fieldnum, time_t value) |
| Add a value to a data object in the form of a timestamp. More...
|
|
DATASRCAPI void | ds_add_binary_time_millis (ds_data_t *data, int32_t fieldnum, int64_t value) |
| Add a value to a data object in the form of a timestamp. More...
|
|
DATASRCAPI void | ds_add_binary_timespec (ds_data_t *data, int32_t fieldnum, struct timespec value) |
| Add a value to a data object in the form of a timestamp. More...
|
|
DATASRCAPI void | ds_add_binary_timeval (ds_data_t *data, int32_t fieldnum, struct timeval value) |
| Add a value to a data object in the form of a timestamp. More...
|
|
DATASRCAPI void | ds_add_binary_uint16 (ds_data_t *data, int32_t fieldnum, uint16_t value) |
| Add a value to a data object in the form of an unsigned 16 bit integer. More...
|
|
DATASRCAPI void | ds_add_binary_uint32 (ds_data_t *data, int32_t fieldnum, uint32_t value) |
| Add a value to a data object in the form of an unsigned 32 bit integer. More...
|
|
DATASRCAPI void | ds_add_binary_uint64 (ds_data_t *data, int32_t fieldnum, uint64_t value) |
| Add a value to a data object in the form of an unsigned 64 bit integer. More...
|
|
DATASRCAPI void | ds_add_binary_uint8 (ds_data_t *data, int32_t fieldnum, uint8_t value) |
| Add a value to a data object in the form of an unsigned 8 bit integer. More...
|
|
DATASRCAPI void | ds_add_container_symbol (ds_data_t *data, const char *symbol) |
| Add an object to the container. More...
|
|
DATASRCAPI void | ds_add_container_symbol_and_request (ds_data_t *data, const char *symbol, const int request) |
| Add an object to the container, indicating whether it should then be requested. More...
|
|
DATASRCAPI void | ds_add_container_symbol_at_position (ds_data_t *data, int position, const char *symbol) |
| Insert an object within a container at a particular position. More...
|
|
DATASRCAPI void | ds_add_data (ds_data_t *data, int32_t fieldnum, const char *value) |
| Adds a string value to a data object. More...
|
|
DATASRCAPI void | ds_add_data_char (ds_data_t *data, int32_t fieldnum, char value) |
| Add a value to a data object in the form of a character. More...
|
|
DATASRCAPI void | ds_add_data_float32 (ds_data_t *data, int32_t fieldnum, float value) |
| Add a value to a data object in the form of a floating point number. More...
|
|
DATASRCAPI void | ds_add_data_float64 (ds_data_t *data, int32_t fieldnum, double value) |
| Add a value to a data object in the form of a floating point number. More...
|
|
DATASRCAPI void | ds_add_data_fmt (ds_data_t *data, int32_t fieldnum, const char *fmt,...) |
| Add a sprintf style format string to a data object. More...
|
|
DATASRCAPI void | ds_add_data_int16 (ds_data_t *data, int32_t fieldnum, int16_t value) |
| Add a value to a data object in the form of a 16 bit integer. More...
|
|
DATASRCAPI void | ds_add_data_int32 (ds_data_t *data, int32_t fieldnum, int32_t value) |
| Add a value to a data object in the form of a 32 bit integer. More...
|
|
DATASRCAPI void | ds_add_data_int64 (ds_data_t *data, int32_t fieldnum, int64_t value) |
| Add a value to a data object in the form of a 64 bit integer. More...
|
|
DATASRCAPI void | ds_add_data_int8 (ds_data_t *data, int32_t fieldnum, int8_t value) |
| Add a value to a data object in the form of an 8 bit integer. More...
|
|
DATASRCAPI void | ds_add_data_str (ds_data_t *data, int32_t fieldnum, const char *value) |
| Adds a string value to a data object. More...
|
|
DATASRCAPI ds_except_event_t * | ds_add_except_event (sock_t fd, ds_io_event_cb cb, int val, void *data) |
| Add a socket exception event. More...
|
|
DATASRCAPI void | ds_add_latency_chain (ds_data_t *dsdata, char suffix, struct timespec *tp) |
| function used to add a measurement point to latency chain data More...
|
|
DATASRCAPI void | ds_add_latency_chain2 (ds_data_t *dsdata, char suffix, struct timespec tp, char suffix2, struct timespec *tp2) |
| Function used to add two measurement points to latency chain data. More...
|
|
DATASRCAPI void | ds_add_latency_initial_timestamp (ds_data_t *dsdata) |
| Sets the initial time for latency chaining. More...
|
|
DATASRCAPI void | ds_add_news_authstr (ds_data_t *data, const char *authstr) |
| Add an authorisation string to the news headline message. More...
|
|
DATASRCAPI void | ds_add_news_company_code (ds_data_t *data, const char *code) |
| Add a company code to the news headline message. More...
|
|
DATASRCAPI void | ds_add_news_datetime (ds_data_t *data, const char *datestr) |
| Add a date stamp to the news headline message. More...
|
|
DATASRCAPI void | ds_add_news_field (ds_data_t *dsdata, const char *fieldname, const char *value) |
| Add a custom field to a news headline message. More...
|
|
DATASRCAPI void | ds_add_news_headline (ds_data_t *data, const char *headline) |
| Add a news headline to the news headline message. More...
|
|
DATASRCAPI void | ds_add_news_product_code (ds_data_t *data, const char *code) |
| Add a product code to the news headline message. More...
|
|
DATASRCAPI void | ds_add_news_storycode (ds_data_t *data, const char *story) |
| Add a story code to the news object. More...
|
|
DATASRCAPI void | ds_add_news_topic_code (ds_data_t *data, const char *code) |
| Add a topic code to the news headline message. More...
|
|
DATASRCAPI void | ds_add_news_user_code (ds_data_t *data, int codenum, const char *code) |
| Add a user defined code to the news headline message. More...
|
|
DATASRCAPI void | ds_add_page_field (ds_data_t *data, int32_t fieldnum, const char *value) |
| Add an arbitrary field to a page. More...
|
|
DATASRCAPI void | ds_add_page_field_by_name (ds_data_t *data, const char *field, const char *value) |
| Add an arbitrary field to a page. More...
|
|
DATASRCAPI void | ds_add_page_row (ds_data_t *data, int row, int col, const char *str) |
| Add a row of data to a page data object. More...
|
|
DATASRCAPI ds_timed_event_t * | ds_add_periodic_event (int starttime, int period, int id, ds_timed_event_cb cb, int val, void *data) |
| Add a timed event, starting at a particular time. More...
|
|
DATASRCAPI ds_timed_event_t * | ds_add_periodic_event_from_time (time_t then, int starttime, int period, int id, ds_timed_event_cb cb, int val, void *data) |
| Add a timed event, starting at a particular offset from a given time. More...
|
|
DATASRCAPI void | ds_add_permission_key (ds_data_t *data, const char *key) |
| Set the key for a permission object. Must be called either first, or immediately after inserting a seperator. More...
|
|
DATASRCAPI ds_read_event_t * | ds_add_read_event (sock_t fd, ds_io_event_cb cb, int val, void *data) |
| Add a socket read event. More...
|
|
DATASRCAPI int32_t | ds_add_record_char (ds_data_t *data, const char *field, char value) |
| Add a character value to a record object. More...
|
|
DATASRCAPI int32_t | ds_add_record_float (ds_data_t *data, const char *field, double value) |
| Add a floating point value to a record object. More...
|
|
DATASRCAPI int32_t | ds_add_record_fmt (ds_data_t *data, const char *field, const char *fmt,...) |
| Add a formatted string to a record object. More...
|
|
DATASRCAPI int32_t | ds_add_record_int (ds_data_t *data, const char *field, int value) |
| Add an integer value to a record object. More...
|
|
DATASRCAPI int32_t | ds_add_record_str (ds_data_t *data, const char *field, const char *value) |
| Add a string value to a record object. More...
|
|
DATASRCAPI ds_timed_event_t * | ds_add_timed_event (int id, double delay, ds_timed_event_cb cb, int val, void *data) |
| Add a timed event. More...
|
|
DATASRCAPI ds_udp_event_t * | ds_add_udp_event (const char *command, ds_udp_event_cb cb, int val, void *data) |
| Add a udp event. More...
|
|
DATASRCAPI ds_write_event_t * | ds_add_write_event (sock_t fd, ds_io_event_cb cb, int val, void *data) |
| Add a socket write event. More...
|
|
DATASRCAPI void | ds_and (ds_set_t *p1, ds_set_t *p2, ds_set_t *a) |
| Combine 2 peersets using bitwise and. More...
|
|
DATASRCAPI int | ds_and3_iszero (ds_set_t *p1, ds_set_t *p2, ds_set_t *p3) |
| Check if the bitwise and of 3 peer sets is 0. More...
|
|
DATASRCAPI int | ds_and_iszero (ds_set_t *p1, ds_set_t *p2) |
| Check if the bitwise and of 2 peer sets is 0. More...
|
|
DATASRCAPI void | ds_cache_add_object (char *subject) |
| Add a new object to the cache. More...
|
|
DATASRCAPI int | ds_check_periodic_event (int period, ds_timed_event_t **tev) |
| Check a periodic to ensure that it runs at the appropriate time regardless of summertime. More...
|
|
DATASRCAPI int | ds_check_subnet (const char *s_address, const char *s_network, const char *s_netmask) |
| Check whether an address falls into a given network and netmask. More...
|
|
DATASRCAPI void | ds_cleardown_container_with_prefix (ds_data_t *data, const char *prefix) |
| Remove a set of symbols from the container. More...
|
|
DATASRCAPI sock_t | ds_client_socket (const char *serv, unsigned short port) |
| Creates a client socket with which to connect to a host. More...
|
|
DATASRCAPI sock_t | ds_client_socket_nonblocking (const char *serv, unsigned short port) |
| Creates a client socket with which to connect to a host. More...
|
|
DATASRCAPI ds_data_t * | ds_clone_data (ds_data_t *data) |
| Create a clone of a data object. More...
|
|
DATASRCAPI void | ds_config_add_array_option (const char *longopt, const char *help, int type, void *value, int *num) |
| Adds a configuration option to the current configuration context. More...
|
|
DATASRCAPI void | ds_config_add_array_option_enum (const char *longopt, const char *help, int type, void *value, int *num, ds_config_enum_t *enums) |
| Add an enumerated option to the configuration context. More...
|
|
DATASRCAPI void | ds_config_add_bounded_array_option (const char *longopt, const char *help, int type, void *value, int *num, void *min, void *max) |
| Adds a configuration option to the current configuration context. More...
|
|
DATASRCAPI void | ds_config_add_bounded_array_option_enum (const char *longopt, const char *help, int type, void *value, int *num, ds_config_enum_t *enums, void *min, void *max) |
| Add an enumerated option to the configuration context. More...
|
|
DATASRCAPI void | ds_config_add_bounded_option (char sopt, const char *longopt, const char *help, int type, void *value, void *min, void *max) |
| Add a bounded configuration option to the current configuration context. More...
|
|
DATASRCAPI void | ds_config_add_bounded_option_enum (char sopt, const char *longopt, const char *help, int type, void *value, ds_config_enum_t *enums, void *min, void *max) |
| Add an enumerated option to the configuration context. More...
|
|
DATASRCAPI void DATASRCAPI void DATASRCAPI void | ds_config_add_error_message (const char *msg) |
| Add a configuration error to the logfile. More...
|
|
DATASRCAPI void | ds_config_add_file (const char *file) |
| Add a mandatory configuration file to the current configuration context. More...
|
|
DATASRCAPI void | ds_config_add_group (const char *longopt, const char *help, void *base, void *def, size_t size, int *num) |
| Add a configuration group to the current configuration context. More...
|
|
DATASRCAPI void | ds_config_add_group_with_info (const char *longopt, const char *help, void *base, void *def, size_t size, int *num, int file_offset, int line_offset) |
| Add a configuration group to the current configuration context. More...
|
|
DATASRCAPI void | ds_config_add_option (char opt, const char *longopt, const char *help, int type, void *value) |
| Add a configuration option to the current configuration context. More...
|
|
DATASRCAPI void | ds_config_add_option_enum (char opt, const char *longopt, const char *help, int type, void *value, ds_config_enum_t *enums) |
| Add an enumerated option to the configuration context. More...
|
|
DATASRCAPI void | ds_config_add_optional_file (const char *file) |
| Add an optional configuration file to the current configuration context. More...
|
|
DATASRCAPI void | ds_config_add_search (const char *path) |
| Add a directory in which to search for configuration files. More...
|
|
DATASRCAPI void | ds_config_add_section (const char *longopt, const char *help) |
| Adds a new configuration section to the current configuration context. More...
|
|
DATASRCAPI void | ds_config_del_option (const char *longopt) |
| Remove an option from the current configuration context. More...
|
|
DATASRCAPI void | ds_config_del_test (const char *tag) |
| Delete a conditional test. More...
|
|
DATASRCAPI void | ds_config_end_group (const char *longopt, const char *help) |
| Ends a configuration group. More...
|
|
DATASRCAPI void | ds_config_end_section (const char *longopt, const char *help) |
| Ends a configuration section. More...
|
|
DATASRCAPI void | ds_config_free_ctx (ds_config_ctx_t *ctx) |
| Free a configuration context. More...
|
|
DATASRCAPI int | ds_config_get_enum (const char *value, ds_config_enum_t *enums) |
| Get the value of an enumerated member. More...
|
|
DATASRCAPI char * | ds_config_get_filename (void) |
| Return the current line number being parsed in the configuration file. More...
|
|
DATASRCAPI int | ds_config_get_linenumber (void) |
| Return the name of current configuration file being parsed. More...
|
|
DATASRCAPI void | ds_config_init (const char *file, int argc, char **argv) |
| Set up the configuration of the DataSource. More...
|
|
DATASRCAPI void | ds_config_list_options (void) |
| Print the options in the current configuration context to standard output. More...
|
|
DATASRCAPI void | ds_config_list_values (void) |
| Print the options and values in the current configuration context to standard output. More...
|
|
DATASRCAPI ds_config_ctx_t * | ds_config_new_ctx (void) |
| Create a new configuration context. More...
|
|
DATASRCAPI void | ds_config_parse_args (int argc, char **argv, int *retargc) |
| Parse the configuration options from the command line arguments given. More...
|
|
DATASRCAPI int | ds_config_parse_file (const char *unresolved_filename) |
| Parse a single configuration file within the configuration context. More...
|
|
DATASRCAPI void | ds_config_parse_files (void) |
| Parse all configuration files within the current configuration context. More...
|
|
DATASRCAPI ds_config_ctx_t * | ds_config_set_ctx (ds_config_ctx_t *ctx) |
| Sets a configuration context as the current one. More...
|
|
DATASRCAPI void | ds_config_set_option (const char *name, const char *value) |
| Set a particular configuration option. More...
|
|
DATASRCAPI void | ds_config_set_test (const char *tag, char **value) |
| Adds a conditional test to the configuration file. More...
|
|
DATASRCAPI void DATASRCAPI void | ds_cycle_all_logs (const char *suffix, long maxsize) |
| Cycle all log files in the application. More...
|
|
DATASRCAPI int | ds_cycle_log (ds_log_t *log, const char *suffix, long maxsize) |
| Cycle a specific log file. More...
|
|
DATASRCAPI int | ds_daemon_disabled (void) |
| Check whether the application is running in daemon mode. More...
|
|
DATASRCAPI void | ds_daemon_redirect (void) |
| Redirects the std* streams. More...
|
|
DATASRCAPI char * | ds_debug_config_string (int level) |
| This function will convert a debug level into an appropriate string. More...
|
|
DATASRCAPI int | ds_debug_level (const char *text) |
| This function will convert a string into an appropriate debug level. More...
|
|
DATASRCAPI char * | ds_debug_string (int level) |
| This function will convert a debug level into an appropriate string. More...
|
|
DATASRCAPI int | ds_del_except_event (ds_except_event_t *ev) |
| Remove a socket except event. More...
|
|
DATASRCAPI int | ds_del_except_event_free_data (ds_except_event_t *ev, void(*free_data)(int, void *)) |
| Remove a socket except event. More...
|
|
DATASRCAPI int | ds_del_read_event (ds_read_event_t *ev) |
| Remove a socket read event. More...
|
|
DATASRCAPI int | ds_del_read_event_free_data (ds_read_event_t *ev, void(*free_data)(int, void *)) |
| Remove a socket read event. More...
|
|
DATASRCAPI int | ds_del_timed_event (ds_timed_event_t *ev) |
| Remove a timed event. More...
|
|
DATASRCAPI int | ds_del_timed_event_free_data (ds_timed_event_t *ev, void(*free_data)(int, void *)) |
| Remove a timed event. More...
|
|
DATASRCAPI void | ds_del_udp_event (ds_udp_event_t *event) |
| Remove a timed event. More...
|
|
DATASRCAPI int | ds_del_write_event (ds_write_event_t *ev) |
| Remove a socket write event. More...
|
|
DATASRCAPI int | ds_del_write_event_free_data (ds_write_event_t *ev, void(*free_data)(int, void *)) |
| Remove a socket write event. More...
|
|
DATASRCAPI void | ds_delay_data (ds_delay_t *delay, ds_data_t *dsdata) |
| Add a data object to a delay channel. More...
|
|
DATASRCAPI void | ds_discard_object (const char *name) |
| Discard an object. More...
|
|
DATASRCAPI void | ds_discard_objects (int count, char **obs) |
| Discard a number of objects. More...
|
|
DATASRCAPI int | ds_fields_add (int num, const char *name, int flags, int dp, const char *fmt) |
| Add a new field to the field list. More...
|
|
DATASRCAPI int | ds_fields_getdp (int index) |
| Return the decimal precision of this index. More...
|
|
DATASRCAPI int | ds_fields_getflags (int index) |
| Return the field flags of this index. More...
|
|
DATASRCAPI int | ds_fields_indexbyname (const char *name) |
| Return the index of this field. More...
|
|
DATASRCAPI int | ds_fields_indexbynum (int num) |
| Return the index of this field. More...
|
|
DATASRCAPI int | ds_fields_max (void) |
| Return the number of fields that have been defined. More...
|
|
DATASRCAPI char * | ds_fields_namebyindex (int index) |
| Return the field name of this index. More...
|
|
DATASRCAPI char * | ds_fields_namebynum (int num) |
| Return the field name of this field number. More...
|
|
DATASRCAPI int | ds_fields_numbyindex (int index) |
| Return the field number of this index. More...
|
|
DATASRCAPI int | ds_fields_numbyname (const char *name) |
| Return the field number of this field. More...
|
|
DATASRCAPI char * | ds_filename_expand (const char *format, char *buffer, size_t bufsize) |
| Expand a filename pattern into a fully qualified filename. More...
|
|
DATASRCAPI void | ds_free_data (ds_data_t *data) |
| Deallocates the memory used by a data object. More...
|
|
DATASRCAPI void | ds_free_log (ds_log_t *log) |
| Destroy a log object. More...
|
|
DATASRCAPI ds_log_t * | ds_get_event_log (void) |
| Returns a handle to the event log used by Datasource for C. More...
|
|
DATASRCAPI int | ds_get_gmt_offset (time_t t) |
| Calculate offset between local time and gmt. More...
|
|
DATASRCAPI int | ds_get_is_contrib_source (const char *name, int peer) |
| Check if the given peer is a contribution source for the symbol. More...
|
|
DATASRCAPI int | ds_get_num_services (void) |
| Return the number of services. More...
|
|
DATASRCAPI void * | ds_get_object_data (const char *name) |
| Get an objects user data. More...
|
|
DATASRCAPI char ** | ds_get_request_hints (const char *name, int *ret) |
| Return an objects request hints. More...
|
|
DATASRCAPI char * | ds_get_service (const char *name) |
| Return the service for an object. More...
|
|
DATASRCAPI int | ds_get_service_by_index (int index, char **name_ptr) |
| Return the name/state of a service by index. More...
|
|
DATASRCAPI time_t | ds_get_time (void) |
| Gets the current time in seconds. More...
|
|
DATASRCAPI struct sockaddr_storage * | ds_gethostsockaddr (const char *name, struct sockaddr_storage *populate) |
| Return the socket address for a given hostname. More...
|
|
DATASRCAPI char * | ds_getnameinfo (const struct sockaddr_storage *addr, char *buf, size_t buflen) |
| return the string representation of the address passed in More...
|
|
DATASRCAPI struct tm * | ds_gmtime (void) |
| Get the current time in GMT. More...
|
|
DATASRCAPI int | ds_init (ds_init_t *init, int argc, char **argv) |
| Parse the configuration files and initialise the DataSource library. More...
|
|
DATASRCAPI ds_data_t * | ds_init_container (const char *subject, const unsigned short flags) |
| Initialise a container object. More...
|
|
DATASRCAPI ds_data_t * | ds_init_data (const char *subject, unsigned short type, unsigned short flags) |
| Initialise a data object for use. More...
|
|
DATASRCAPI ds_data_t * | ds_init_news (const char *subject, unsigned short flags) |
| Create a news headline message. More...
|
|
DATASRCAPI ds_data_t * | ds_init_page (const char *subject, int rows, int cols, const char *type, unsigned short flags) |
| Initialise a data object as a page. More...
|
|
DATASRCAPI ds_data_t * | ds_init_permission (const char *subject, const char *key, unsigned short flags) |
| Initialise a data object as a permission object. More...
|
|
DATASRCAPI int | ds_isequal (ds_set_t *p1, ds_set_t *p2) |
| Check 2 peersets are equal. More...
|
|
DATASRCAPI int | ds_iszero (ds_set_t *p) |
| Check if any peer is set. More...
|
|
DATASRCAPI sock_t | ds_listen_socket (const char *addr, int port, int backlog) |
| Creates a listen socket on the specified local address and TCP port. More...
|
|
DATASRCAPI struct tm * | ds_localtime (void) |
| Get the current time in the local timezone. More...
|
|
DATASRCAPI void | ds_log_change_level_callback (ds_log_t *log, ds_loglevelchange_t change_cb) |
| Set the level change callback for a given logfile. More...
|
|
DATASRCAPI ds_logcycled_t | ds_log_cycled_callback (ds_log_t *log, ds_logcycled_t cycle_cb) |
| Set the cycle callback for a given logfile. More...
|
|
DATASRCAPI int | ds_log_flush (ds_log_t *log) |
| flush log buffers to disk More...
|
|
DATASRCAPI int | ds_log_get_level (ds_log_t *log) |
| Get the current loglevel for the given logfile. More...
|
|
DATASRCAPI char * | ds_log_getfilename (ds_log_t *log) |
| Get the filename of a log object. More...
|
|
DATASRCAPI void DATASRCAPI int | ds_log_set_log_level (ds_log_t *log, const char *level) |
| Set the log level for a particular logfile. More...
|
|
DATASRCAPI void | ds_loop (void) |
| Start the DataSource event loop. More...
|
|
DATASRCAPI void | ds_monitor_add_data (ds_monitor_t *data, const void *datum) |
| Add an element to an array within a ds_monitor_t. More...
|
|
DATASRCAPI void | ds_monitor_add_relation (const char *templatename, const char *key, const char *propertyname, const char *targetkey) |
| Add a relationship between two groups. More...
|
|
DATASRCAPI void | ds_monitor_add_server_type (const char *type, const char *root) |
| Define The Server Type. More...
|
|
DATASRCAPI void | ds_monitor_add_subscription (const char *templatename, const char *key, const char *propertyname, const char *value) |
| Add a subscription between two groups. More...
|
|
DATASRCAPI void | ds_monitor_add_template_member (const char *templatename, const char *propertyname, const char *description, int typeflags, ds_arguments_t *args, void *ptr) |
| Add a memeber to a template. More...
|
|
DATASRCAPI void | ds_monitor_add_template_relation (const char *templatename, const char *propertyname, const char *targettemplate, const char *description, int thisend_multiple, int thatend_multiple) |
| Add a relationship to a template. More...
|
|
DATASRCAPI void | ds_monitor_add_template_subscription (const char *templatename, const char *propertyname, const char *targettemplate, const char *description, const char *singleton, ds_monitor_active_cb callback_fn) |
| Add a subscription info into the template. More...
|
|
DATASRCAPI void | ds_monitor_create_group (const char *templatename, const char *key, const char *brief, const char *description) |
| Create a new monitoring group. More...
|
|
DATASRCAPI void | ds_monitor_del_relation (const char *templatename, const char *key, const char *propertyname, const char *targetkey) |
| Delete a relationship between two groups. More...
|
|
DATASRCAPI void | ds_monitor_del_subscription (const char *templatename, const char *key, const char *propertyname, const char *value) |
| Delete a subscription between two groups. More...
|
|
DATASRCAPI void | ds_monitor_delete_group (const char *templatename, const char *key) |
| Delete a group from the monitoring system. More...
|
|
DATASRCAPI void | ds_monitor_end_template (const char *templatename) |
| End the definition of a template. More...
|
|
DATASRCAPI void | ds_monitor_free (ds_monitor_t *data) |
| Deallocate memory used by a ds_monitor_t object. More...
|
|
DATASRCAPI void | ds_monitor_free_data (ds_monitor_t *data) |
| Deallocate memory used by the contents of a ds_monitor_t object. More...
|
|
DATASRCAPI ds_monitor_t * | ds_monitor_new (const char *propertyname, int type, int datasize, const void *datum) |
| Create a new ds_monitor_t object from input parameters. More...
|
|
DATASRCAPI ds_monitor_t * | ds_monitor_new_array (const char *propertyname, int type) |
| Create a new ds_monitor_t of an array type. More...
|
|
DATASRCAPI ds_monitor_t * | ds_monitor_new_double (const char *templatename, const char *key, const char *propertyname, double value) |
| Create a new ds_monitor_t object from an input double. More...
|
|
DATASRCAPI ds_monitor_t * | ds_monitor_new_llong (const char *templatename, const char *key, const char *propertyname, int64_t value) |
| Create a new ds_monitor_t object from an input long long. More...
|
|
DATASRCAPI ds_monitor_t * | ds_monitor_new_long (const char *templatename, const char *key, const char *propertyname, int32_t value) |
| Create a new ds_monitor_t object from an input long. More...
|
|
DATASRCAPI ds_monitor_t * | ds_monitor_new_short (const char *templatename, const char *key, const char *propertyname, int16_t value) |
| Create a new ds_monitor_t object from an input short. More...
|
|
DATASRCAPI ds_monitor_t * | ds_monitor_new_string (const char *templatename, const char *key, const char *propertyname, const char *value) |
| Create a new ds_monitor_t object from an input string. More...
|
|
DATASRCAPI ds_monitor_t * | ds_monitor_new_timestamp (const char *templatename, const char *key, const char *propertyname, int64_t value) |
| Create a new ds_monitor_t object from an input timestamp. More...
|
|
DATASRCAPI ds_monitor_t * | ds_monitor_new_ullong (const char *templatename, const char *key, const char *propertyname, uint64_t value) |
| Create a new ds_monitor_t object from an input unsigned long long. More...
|
|
DATASRCAPI ds_monitor_t * | ds_monitor_new_ulong (const char *templatename, const char *key, const char *propertyname, uint32_t value) |
| Create a new ds_monitor_t object from an input unsigned long. More...
|
|
DATASRCAPI ds_monitor_t * | ds_monitor_new_ushort (const char *templatename, const char *key, const char *propertyname, uint16_t value) |
| Create a new ds_monitor_t object from an input unsigned short. More...
|
|
DATASRCAPI ds_monitor_authenticator_t | ds_monitor_set_auth (ds_monitor_authenticator_t authenticator) |
| Register a new authentication handler. More...
|
|
DATASRCAPI void | ds_monitor_start_template (const char *templatename, const char *description) |
| Start the defintion of a template. More...
|
|
DATASRCAPI void | ds_monitor_update (const char *templatename, const char *key, ds_monitor_t *mondata) |
| Post an update to the monitoring system for a string value. More...
|
|
DATASRCAPI void | ds_monitor_update_double (const char *templatename, const char *key, const char *propertyname, double value) |
| Post an update to the monitoring system for a double value. More...
|
|
DATASRCAPI void | ds_monitor_update_llong (const char *templatename, const char *key, const char *propertyname, int64_t value) |
| Post an update to the monitoring system for a long long value. More...
|
|
DATASRCAPI void | ds_monitor_update_long (const char *templatename, const char *key, const char *propertyname, int32_t value) |
| Post an update to the monitoring system for a long value. More...
|
|
DATASRCAPI void | ds_monitor_update_short (const char *templatename, const char *key, const char *propertyname, int16_t value) |
| Post an update to the monitoring system for a short value. More...
|
|
DATASRCAPI void | ds_monitor_update_string (const char *templatename, const char *key, const char *propertyname, const char *value) |
| Post an update to the monitoring system for a string value. More...
|
|
DATASRCAPI void | ds_monitor_update_timestamp (const char *templatename, const char *key, const char *propertyname, int64_t value) |
| Post an update to the monitoring system for a timestamp value. More...
|
|
DATASRCAPI void | ds_monitor_update_ullong (const char *templatename, const char *key, const char *propertyname, uint64_t value) |
| Post an update to the monitoring system for an unsigned long long value. More...
|
|
DATASRCAPI void | ds_monitor_update_ulong (const char *templatename, const char *key, const char *propertyname, uint32_t value) |
| Post an update to the monitoring system for an unsigned long value. More...
|
|
DATASRCAPI void | ds_monitor_update_ushort (const char *templatename, const char *key, const char *propertyname, uint16_t) |
| Post an update to the monitoring system for an unsigned short value. More...
|
|
DATASRCAPI sock_t | ds_multicast_listen_socket (const char *p_interface, const char *addr, int port) |
| Creates a multicast listen socket. More...
|
|
DATASRCAPI ds_delay_t * | ds_new_delay (double delay_time, char *prefix, double batch_time) |
| Create a new delay channel. More...
|
|
DATASRCAPI ds_delay_t * | ds_new_delay_with_callback (double delay_time, char *prefix, double batch_time, void *callback_param, ds_delay_send_cb callback_func) |
| Create a new delay channel. More...
|
|
DATASRCAPI ds_log_t * | ds_new_headed_log (const char *name, const char *logname, const char *header) |
| Create a new log object with a header. More...
|
|
DATASRCAPI ds_log_t * | ds_new_level_log (const char *name, const char *logname, ds_loglevelchange_t change_cb) |
| Create a new log object. More...
|
|
DATASRCAPI ds_log_t * | ds_new_log (const char *name, const char *logname) |
| Create a new log object. More...
|
|
DATASRCAPI int | ds_object_available (const char *name) |
| Determine whether this object can theoretically be requested. More...
|
|
DATASRCAPI int | ds_object_can_contrib (const char *name) |
| Determine whether contributions can be sent for this object. More...
|
|
DATASRCAPI void | ds_or (ds_set_t *p1, ds_set_t *p2, ds_set_t *o) |
| Combine 2 peersets using bitwise or. More...
|
|
DATASRCAPI int | ds_peer_all_type (int flag) |
| Checks if a DataSource peer of the given type is in your configuration file. More...
|
|
DATASRCAPI int | ds_peer_by_label (const char *label) |
| Return the peer index for a label. More...
|
|
DATASRCAPI int | ds_peer_by_local_label (const char *label) |
| Return the peer index for a local label. More...
|
|
DATASRCAPI int | ds_peer_details (int peer, char **name) |
| Gets the ID and name of a peer. More...
|
|
DATASRCAPI int | ds_peer_enabled_state (int peer) |
| Gets the enabled/disabled state of a DataSource peer. More...
|
|
DATASRCAPI int | ds_peer_flags (int peer) |
| Gets the flags of a peer. More...
|
|
DATASRCAPI int | ds_peer_host_details (int peer, char **addr) |
| Gets details of the remote side of a peer. More...
|
|
DATASRCAPI int | ds_peer_id (int peer) |
| Gets the ID of a peer. More...
|
|
DATASRCAPI char * | ds_peer_label_byindex (int index) |
| Return the peer label for a peer index. More...
|
|
DATASRCAPI int | ds_peer_local_type (int peer) |
| Gets the local type of a DataSource peer. More...
|
|
DATASRCAPI char * | ds_peer_name (int peer) |
| Gets the name of a peer. More...
|
|
DATASRCAPI int | ds_peer_type (int peer) |
| Gets the type of a DataSource peer. More...
|
|
DATASRCAPI int | ds_peer_up (int peer) |
| Check to see if a peer is up. More...
|
|
DATASRCAPI int | ds_pipe (sock_t fds[2]) |
| Creates a UNIX-style pipe. More...
|
|
DATASRCAPI void DATASRCAPI void DATASRCAPI void | ds_printf_time_ap (ds_log_t *log, const char *extra, const char *fmt, va_list ap) |
| Write a formatted string prefixed with a timestamp string to a log object. More...
|
|
DATASRCAPI void | ds_purge_object (const char *name) |
| Purge an object from our cache. More...
|
|
DATASRCAPI void | ds_read_event_set_callback (ds_read_event_t *ev, ds_io_event_cb cb, int val, void *data) |
| Change the callback and callback values for a socket read event. More...
|
|
DATASRCAPI void | ds_remove_container_symbol (ds_data_t *data, const char *symbol) |
| Remove an object from the container. More...
|
|
DATASRCAPI void | ds_replay (recv_replay_t callback) |
| Replays all data in the current packet log file. More...
|
|
DATASRCAPI void | ds_replay_by_field (int fieldnum, char *value, recv_replay_t callback) |
| Replays all data in the current packet log file that arrived after an update with the specified value for the specified field. More...
|
|
DATASRCAPI int | ds_replay_by_field_from_file (int fieldnum, char *value, recv_replay_t callback, char *filename) |
| Replays all data in a file that arrived after an update with the specified value for the specified field. More...
|
|
DATASRCAPI void | ds_replay_by_field_from_log (int fieldnum, char *value, recv_replay_t callback, ds_log_t *log) |
| Replays all data in the log object that arrived after an update with the specified value for the specified field. More...
|
|
DATASRCAPI void | ds_replay_by_time (time_t t, recv_replay_t callback) |
| Replays all data in the current packet log file that arrived after a specified time. More...
|
|
DATASRCAPI int | ds_replay_by_time_from_file (time_t t, recv_replay_t callback, char *filename) |
| Replays all data in a file that arrived after a specified time. More...
|
|
DATASRCAPI void | ds_replay_by_time_from_log (time_t t, recv_replay_t callback, ds_log_t *log) |
| Replays all data in a log object that arrived after a specified time. More...
|
|
DATASRCAPI int | ds_replay_from_file (recv_replay_t callback, char *filename) |
| Replays all data in a file. More...
|
|
DATASRCAPI void | ds_replay_from_log (recv_replay_t callback, ds_log_t *log) |
| Replays all data in a packet log file. More...
|
|
DATASRCAPI char * | ds_request_object (const char *name) |
| Request an object. More...
|
|
DATASRCAPI char * | ds_request_object_with_flags (const char *name, int flags) |
| Request an object. More...
|
|
DATASRCAPI int | ds_request_objects (int count, char **obs, char ***services) |
| Request a number of objects in one go. More...
|
|
DATASRCAPI int | ds_request_objects_with_flags (int count, char **obs, int flags, char ***services) |
| Request a number of objects in one go. More...
|
|
DATASRCAPI int | ds_required_services_status (char *buf, size_t buflen) |
| Return whether all required services are ready. More...
|
|
DATASRCAPI void | ds_reserve_std_fds (void) |
| Reserves the standard sockets for the std streams. More...
|
|
DATASRCAPI int | ds_send_contribution (ds_data_t *dsdata) |
| Contribute an object back to the peers that supplied it and support it. More...
|
|
DATASRCAPI void | ds_send_data (ds_data_t *data) |
| Send the data object to all connected DataSource peers. More...
|
|
DATASRCAPI void | ds_send_data_direct (ds_data_t *data) |
| Send the data object to all connected DataSource peers. More...
|
|
DATASRCAPI void | ds_send_data_no_free (ds_data_t *data) |
| Send the data object to all connected DataSource peers. More...
|
|
DATASRCAPI void | ds_send_data_to_peer (int peer, ds_data_t *data) |
| Send the data object to a specific peer. More...
|
|
DATASRCAPI void | ds_send_data_to_peer_no_free (int peer, ds_data_t *data) |
| Send the data object to a specific peer. More...
|
|
DATASRCAPI void | ds_send_nodata (const char *subject, unsigned short flags) |
| Send a "no data" message to all connected DataSource peers. More...
|
|
DATASRCAPI void | ds_send_nodata_direct (const char *subject, unsigned short flags) |
| Send a "no data" message to all connected DataSource peers. More...
|
|
DATASRCAPI void | ds_send_nodata_to_peer (int peer, const char *subject, unsigned short flags) |
| Send a "no data" message to a specific DataSource pper. More...
|
|
DATASRCAPI void | ds_send_status (const char *subject, unsigned short flags, unsigned short code, const char *msgstr) |
| Sends a user defined status message about a particular object. More...
|
|
DATASRCAPI void | ds_send_status_direct (const char *subject, unsigned short flags, unsigned short code, const char *msgstr) |
| Sends a user defined status message about a particular object. More...
|
|
DATASRCAPI void | ds_send_status_to_peer (int peer, const char *subject, unsigned short flags, unsigned short code, const char *msgstr) |
| Sends a user defined status message about a particular object. More...
|
|
DATASRCAPI void | ds_set_object_data (const char *name, void *data) |
| Set an objects user data. More...
|
|
DATASRCAPI int | ds_set_request_hint (const char *name, int num, char **hints) |
| Set the objects hint peers. More...
|
|
DATASRCAPI void | ds_set_status_down (void) |
| Causes the DataSource to disconnect and stop listening for connections. More...
|
|
DATASRCAPI void | ds_set_status_down_to_peer (int peer) |
| Causes the DataSource to disconnect and not accept connections for this peer. More...
|
|
DATASRCAPI void | ds_set_status_msg (unsigned short msgid, const char *msgstr) |
| Send a user-defined status message to all connected peers. More...
|
|
DATASRCAPI void | ds_set_status_msg_to_peer (int peer, unsigned short msgid, const char *msgstr) |
| Send a user-defined status message to peer. More...
|
|
DATASRCAPI void | ds_set_status_up (void) |
| Causes the DataSource to connect and listen for connections. More...
|
|
DATASRCAPI void | ds_set_status_up_to_peer (int peer) |
| Causes the DataSource to connect and accept connections. More...
|
|
DATASRCAPI void | ds_set_subject (ds_data_t *data, const char *subject) |
| Sets a new name for the data object. More...
|
|
DATASRCAPI void | ds_set_timed_delay (ds_timed_event_t *ev, double delay) |
| Alter the delay for an existing timed event. More...
|
|
DATASRCAPI void | ds_set_timed_delay_next (ds_timed_event_t *ev, double delay) |
| Alter the next fire time for an existing timed event. More...
|
|
DATASRCAPI void | ds_setnonblocking (sock_t fd) |
| Set a socket to be non-blocking. More...
|
|
DATASRCAPI int | ds_signature_check (char *key_id, char *token) |
| Provides a mechanism for validating a KeyMaster-generated encrypted single-use token. More...
|
|
DATASRCAPI int | ds_signature_verify_username (char *expected_username, char *token) |
| Verify that the supplied token is for the expected username. More...
|
|
DATASRCAPI void | ds_stop (void) |
|
DATASRCAPI void | ds_thread_init (int event_module, int flags) |
| Initialise the event loop for this thread. More...
|
|
DATASRCAPI double | ds_timed_event_get_fire_time (ds_timed_event_t *ev) |
| Return the time the event is due to fire. More...
|
|
DATASRCAPI void | ds_timed_event_set_callback (ds_timed_event_t *ev, ds_timed_event_cb cb, int val, void *data) |
| Change the callback and callback values for a timed eent. More...
|
|
DATASRCAPI int | ds_udp_bind_client_socket (sock_t sock, const char *addr, int port) |
| Binds a UDP socket to a local address. More...
|
|
DATASRCAPI sock_t | ds_udp_client_socket (const char *addr, int port, struct sockaddr_storage *serv_addr) |
| Creates a UDP client socket. More...
|
|
DATASRCAPI sock_t | ds_udp_listen_socket (const char *p_interface, int port) |
| Creates a UDP listen socket. More...
|
|
DATASRCAPI int | ds_udp_send (const char *data, int len, const char *addr, int port) |
| Sends data to a UDP address. More...
|
|
DATASRCAPI int | ds_udp_sendto (const char *data, int len, struct sockaddr_storage *serv_addr) |
| Sends data to a UDP address. More...
|
|
DATASRCAPI void | ds_udpsignal_send (const char *message) |
| Send a udp message. More...
|
|
DATASRCAPI void | ds_udpsignal_send_argv (const char *message, char *argv[]) |
| Send a UDP message. More...
|
|
DATASRCAPI void | ds_write (ds_log_t *log, void *data, size_t len) |
| Write binary data to a log object. More...
|
|
DATASRCAPI void | ds_write_event_set_callback (ds_write_event_t *ev, ds_io_event_cb cb, int val, void *data) |
| Change the callback and callback values for a socket write event. More...
|
|
DATASRCAPI void | ds_writev (ds_log_t *log, struct iovec *vector, int count) |
| Write binary data to a log object. More...
|
|