Adaptive Framework  0.9.0
All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Data Structures | Macros | Typedefs | Enumerations | Functions

Header for adaptive framework environment. More...

#include "afw_interface.h"

Go to the source code of this file.

Data Structures

struct  afw_environment_default_register_additional_s
 Default register_additional object struct. More...
 
struct  afw_environment_registry_type_s
 
struct  afw_environment_conf_type_s
 Struct for afw environment conf type. More...
 

Macros

#define AFW_ENVIRONMENT_REGISTRY_TYPE_MAP(XX)
 Environment Core Registry Type Map. More...
 
#define XX(id, register_additional, allow_reregister, property_name, object_type_id, description)    afw_environemnt_registry_type_ ## id,
 
#define AFW_ENVIRONMENT_Q_EXTENSION_INSTANCE    "afw_environment_extension_instance"
 environment extension instance quoted string.
 
#define AFW_ENVIRONMENT_DEFINE_EXTENSION_IMPL()
 Macro to put in each afw_extension implementation. More...
 
#define AFW_ENVIRONMENT_CREATE(xctx, argc, argv, environment_create_error)
 Call afw_environment_create() supplying version compiled with. More...
 
#define afw_environment_register_flag(flag_id, brief, description, included_by_flag_id, xctx)
 Register a flag. More...
 

Typedefs

typedef struct afw_environment_default_register_additional_s afw_environment_default_register_additional_t
 Default register_additional object struct.
 
typedef void(* afw_environment_conf_type_create_cede_p_t) (const afw_utf8_t *type, const afw_object_t *conf, const afw_utf8_t *source_location, const afw_pool_t *p, afw_xctx_t *xctx)
 Typedef for afw conf type create functions. More...
 
typedef void *(* afw_environment_auto_register_cb_t) (const afw_utf8_t *registry_type_id, const afw_utf8_t *key, afw_xctx_t *xctx)
 Auto register callback function. More...
 
typedef void(* afw_environment_register_additional_cb_t) (const afw_utf8_t *registry_type_id, int type_number, const afw_utf8_t *key, const void *value, const void *register_additional_param, const void **register_additional_use, afw_xctx_t *xctx)
 Additional register callback function. More...
 
typedef const afw_utf8_z_t *(* afw_environment_error_rv_decoder_z_t) (int rv, afw_utf8_z_t *wa, afw_size_t wa_size)
 Typedef for error rv decoder functions. More...
 
typedef afw_boolean_t(* afw_environment_foreach_cb_t) (int type_number, void *data, const afw_utf8_octet_t *key_s, afw_size_t key_len, void *value, const afw_pool_t *p, afw_xctx_t *xctx)
 Callback function typedef for afw_environment_foreach(). More...
 

Enumerations

enum  afw_environment_registry_type_enum_t { afw_environemnt_registry_type_max_core_type }
 Enum for the core registry types.
 

Functions

afw_xctx_tafw_environment_create (unsigned int version, int argc, const char *const *argv, const afw_error_t **environment_create_error)
 Create the Adaptive Framework core environment and return base xctx. More...
 
void afw_environment_release (afw_xctx_t *xctx)
 Create the Adaptive Framework core environment and return base xctx. More...
 
 afw_environment_registry_object_get_current (afw_xctx_t *xctx)
 Get current environment registry object. More...
 
void afw_environment_configure_with_object (const afw_object_t *conf, const afw_utf8_t *source_location, afw_xctx_t *xctx)
 Configure environment with a configuration entry. More...
 
void afw_environment_configure_with_object_list (const afw_list_t *entry_list, const afw_utf8_t *source_location, afw_xctx_t *xctx)
 Configure environment with list of configuration entries. More...
 
const afw_object_tafw_environment_create_environment_variables_object (afw_boolean_t preload_variables, afw_xctx_t *xctx)
 Create a readonly object for accessing environment variables. More...
 
const afw_extension_tafw_environment_load_extension (const afw_utf8_t *extension_id, const afw_utf8_t *module_path, const afw_object_t *properties, afw_xctx_t *xctx)
 Load and initialize environment extension. More...
 
void afw_environment_foreach (int type_number, afw_environment_foreach_cb_t callback, void *data, const afw_pool_t *p, afw_xctx_t *xctx)
 Call a callback function for each entry of a registry type. More...
 
int afw_environment_create_registry_type (const afw_utf8_t *registry_type_id, const afw_utf8_t *property_name, const afw_utf8_t *object_type_id, const afw_utf8_t *description, afw_boolean_t allow_reregister, afw_environment_auto_register_cb_t auto_register, afw_environment_register_additional_cb_t register_additional, void *register_additional_param, afw_xctx_t *xctx)
 Create a new registry type. More...
 
const afw_environment_registry_type_tafw_environment_get_registry_type_by_id (const afw_utf8_t *registry_type_id, afw_boolean_t load_extension, afw_xctx_t *xctx)
 Get the registry type associated with a registry type id. More...
 
const afw_environment_registry_type_tafw_environment_get_registry_type_by_number (int registry_type_number, afw_xctx_t *xctx)
 Get the registry type associated with a registry type number. More...
 
void afw_environment_registry_register (int type_number, const afw_utf8_t *key, const void *value, afw_xctx_t *xctx)
 Register a value by key for a registry type. More...
 
afw_boolean_t afw_environment_registry_key_exists (int type_number, const afw_utf8_t *key, afw_xctx_t *xctx)
 Check to see if a key exists. More...
 
void * afw_environment_registry_get (int type_number, const afw_utf8_t *key, afw_xctx_t *xctx)
 Get the value associated with a key for a registry type. More...
 
void * afw_environment_registry_get_without_xctx (const afw_environment_t *env, int type_number, const afw_utf8_t *key)
 Limited get the value associated with a key for a registry type. More...
 
const afw_environment_registry_type_tafw_environment_get_registry_type (const afw_utf8_t *property_name, afw_xctx_t *xctx)
 Get the registry type associated with property name. More...
 
void afw_environment_register_singleton (const afw_utf8_t *singleton_key, const void *void_ptr, afw_xctx_t *xctx)
 Register an singleton. More...
 
void * afw_environment_get_singleton (const afw_utf8_t *singleton_key, afw_xctx_t *xctx)
 Get the singleton value. More...
 
 afw_environment_register_adaptor_type (const afw_utf8_t *adaptor_type, const afw_adaptor_factory_t *adaptor_factory, afw_xctx_t *xctx)
 Register an adaptor factory. More...
 
const afw_adaptor_factory_tafw_environment_get_adaptor_type (const afw_utf8_t *adaptor_type, afw_xctx_t *xctx)
 Get the adaptor factory instance associated with adaptor type. More...
 
void afw_environment_register_adaptor_id (const afw_utf8_t *adaptor_id, const afw_adaptor_id_anchor_t *anchor, afw_xctx_t *xctx)
 Register an adaptor id anchor. More...
 
const afw_adaptor_id_anchor_tafw_environment_get_adaptor_id (const afw_utf8_t *adaptor_id, afw_xctx_t *xctx)
 Get the adaptor id anchor associated with adaptor id. More...
 
 afw_environment_register_authorization_handler_type (const afw_utf8_t *authorization_handler_type, const afw_authorization_handler_factory_t *authorization_handler_factory, afw_xctx_t *xctx)
 Register an authorization handler factory. More...
 
const afw_authorization_handler_factory_tafw_environment_get_authorization_handler_type (const afw_utf8_t *authorization_handler_type, afw_xctx_t *xctx)
 Get the authorization_handler factory instance associated with authorization handler type. More...
 
void afw_environment_register_authorization_handler_id (const afw_utf8_t *authorization_handler_id, const afw_authorization_handler_id_anchor_t *anchor, afw_xctx_t *xctx)
 Register an authorization handler id anchor. More...
 
const afw_authorization_handler_id_anchor_tafw_environment_get_authorization_handler_id (const afw_utf8_t *authorization_handler_id, afw_xctx_t *xctx)
 Get the authorization handler id anchor associated with authorization handler id. More...
 
void afw_environment_create_and_register_conf_type (const afw_utf8_t *conf_type_id, afw_environment_conf_type_create_cede_p_t create, const afw_utf8_t *title, const afw_utf8_t *description, const afw_utf8_t *id_property_name, const afw_utf8_t *id_registry_type_id, const afw_utf8_t *id_runtime_object_type_id, const afw_utf8_t *subtype_property_name, const afw_utf8_t *subtype_registry_type_id, const afw_utf8_t *subtype_runtime_object_type_id, afw_boolean_t is_unique, afw_xctx_t *xctx)
 Create and register a configuration (conf) type. More...
 
const afw_environment_conf_type_tafw_environment_get_conf_type (const afw_utf8_t *type, afw_xctx_t *xctx)
 Get the conf_type associated with type. More...
 
const afw_object_tafw_environment_prepare_conf_type_properties (const afw_object_t *properties, afw_xctx_t *xctx)
 Prepare properties for a conf type. More...
 
void afw_environment_register_content_type (const afw_utf8_t *type, const afw_content_type_t *content_type, afw_xctx_t *xctx)
 Register an content type. More...
 
const afw_content_type_tafw_environment_get_content_type (const afw_utf8_t *type, afw_xctx_t *xctx)
 Get the afw_content_type struct associated with a content type. More...
 
void afw_environment_register_context_type (const afw_utf8_t *context_type_id, const afw_object_t *context_type_object, afw_xctx_t *xctx)
 Register an context type. More...
 
const afw_object_tafw_environment_get_context_type (const afw_utf8_t *context_type_id, afw_xctx_t *xctx)
 Get the afw_environment_context_type struct associated with a context type. More...
 
void afw_environment_register_data_type (const afw_utf8_t *data_type_id, const afw_data_type_t *data_type, afw_xctx_t *xctx)
 Register a data type. More...
 
void afw_environment_register_data_types (const afw_data_type_t *const *data_types, afw_xctx_t *xctx)
 Register a NULL terminated list of data types. More...
 
const afw_data_type_tafw_environment_get_data_type (const afw_utf8_t *type, afw_xctx_t *xctx)
 Get the data_type associated with configuration entry type. More...
 
void afw_environment_register_error_rv_decoder (const afw_utf8_t *rv_source_id, afw_environment_error_rv_decoder_z_t rv_decoder, afw_xctx_t *xctx)
 Register an error rv decoder. More...
 
afw_environment_error_rv_decoder_z_t afw_environment_get_error_rv_decoder (const afw_utf8_t *rv_source_id, afw_xctx_t *xctx)
 Get the error rv decoder function associated with rv_source_id. More...
 
const afw_flag_tafw_environment_get_flag (const afw_utf8_t *flag_id, afw_xctx_t *xctx)
 Get the flag instance associated with flag_id. More...
 
void afw_environment_register_function (const afw_utf8_t *function_id, const afw_value_function_definition_t *function, afw_xctx_t *xctx)
 Register a function. More...
 
void afw_environment_register_functions (const afw_value_function_definition_t **functions, afw_xctx_t *xctx)
 Register a NULL terminated list of functions. More...
 
const afw_value_function_definition_tafw_environment_get_function (const afw_utf8_t *function_id, afw_xctx_t *xctx)
 Get the function instance associated with function id. More...
 
const afw_value_function_definition_tafw_environment_get_qualified_function (const afw_utf8_t *qualifier, const afw_utf8_t *name, afw_xctx_t *xctx)
 Get the qualified function instance. More...
 
const afw_value_function_definition_tafw_environment_registry_get_data_type_method (const afw_data_type_t *data_type, afw_integer_t dataTypeMethodNumber, afw_xctx_t *xctx)
 Get the function associated with a data type method. More...
 
void afw_environment_register_lock (const afw_utf8_t *lock_id, const afw_lock_t *lock, afw_xctx_t *xctx)
 Register an lock. More...
 
const afw_lock_tafw_environment_get_lock (const afw_utf8_t *log_type, afw_xctx_t *xctx)
 Get the lock instance associated a lock id. More...
 
void afw_environment_register_log_type (const afw_utf8_t *log_type, const afw_log_factory_t *log_factory, afw_xctx_t *xctx)
 Register an log factory. More...
 
const afw_log_factory_tafw_environment_get_log_type (const afw_utf8_t *log_type, afw_xctx_t *xctx)
 Get the log factory instance associated with log type. More...
 
void afw_environment_register_log (const afw_utf8_t *log_id, const afw_log_t *log, afw_xctx_t *xctx)
 Register a log. More...
 
const afw_log_tafw_environment_get_log (const afw_utf8_t *log_id, afw_xctx_t *xctx)
 Get the log instance associated with log id. More...
 
void afw_environment_register_policy_combining_algorithm (const afw_utf8_t *policy_combining_algorithm_id, const afw_value_function_definition_t *function, afw_xctx_t *xctx)
 Register a policy combining algorithm function. More...
 
const afw_value_function_definition_tafw_environment_get_policy_combining_algorithm (const afw_utf8_t *policy_combining_algorithm_id, afw_xctx_t *xctx)
 Get the function instance associated with a policy combining algorithm id. More...
 
void afw_environment_register_request_handler_type (const afw_utf8_t *handler_type, const afw_request_handler_factory_t *request_handler_factory, afw_xctx_t *xctx)
 Register a request_handler factory. More...
 
const afw_request_handler_factory_tafw_environment_get_request_handler_type (const afw_utf8_t *handler_type, afw_xctx_t *xctx)
 Get the request_handler factory instance associated with handler type. More...
 
void afw_environment_register_rule_combining_algorithm (const afw_utf8_t *rule_combining_algorithm_id, const afw_value_function_definition_t *function, afw_xctx_t *xctx)
 Register a rule combining algorithm function. More...
 
const afw_value_function_definition_tafw_environment_get_rule_combining_algorithm (const afw_utf8_t *rule_combining_algorithm_id, afw_xctx_t *xctx)
 Get the function instance associated with a rule combining algorithm id. More...
 
void afw_environment_register_runtime_custom (const afw_utf8_t *object_type_id, const afw_runtime_custom_t *custom, afw_xctx_t *xctx)
 Register afw_runtime_custom_t for a custom handled runtime object type. More...
 
const afw_runtime_custom_tafw_environment_get_runtime_custom (const afw_utf8_t *object_type_id, afw_xctx_t *xctx)
 Get afw_runtime_custom_t for a custom handled runtime object type. More...
 
void afw_environment_register_runtime_object_map_inf (const afw_utf8_t *object_type_id, const afw_object_inf_t *inf, afw_xctx_t *xctx)
 Register a runtime object map interface. More...
 
const afw_object_inf_tafw_environment_get_runtime_object_map_inf (const afw_utf8_t *object_type_id, afw_xctx_t *xctx)
 Get the interface associated with a runtime object map. More...
 
void afw_environment_register_runtime_value_accessor (const afw_utf8_t *accessor_name, afw_runtime_value_accessor_t function, afw_xctx_t *xctx)
 Register a runtime value accessor function. More...
 
afw_runtime_value_accessor_t afw_environment_get_runtime_value_accessor (const afw_utf8_t *accessor_name, afw_xctx_t *xctx)
 Get the interface associated with a runtime object map. More...
 
void afw_environment_register_service (const afw_utf8_t *service_id, afw_service_t *service, afw_xctx_t *xctx)
 Register a service. More...
 
afw_service_tafw_environment_get_service (const afw_utf8_t *service_id, afw_xctx_t *xctx)
 Get the service instance associated with service_id. More...
 
void afw_environment_register_service_type (const afw_utf8_t *service_type_id, const afw_service_type_t *service_type, afw_xctx_t *xctx)
 Register a service type. More...
 
const afw_service_type_tafw_environment_get_service_type (const afw_utf8_t *service_type_id, afw_xctx_t *xctx)
 Get the service type instance associated with service_type_id. More...
 
void afw_environment_register_value_inf (const afw_utf8_t *value_inf_id, const afw_value_inf_t *value_inf, afw_xctx_t *xctx)
 Register a value inf. More...
 
const afw_value_inf_tafw_environment_get_value_inf (const afw_utf8_t *value_inf_id, afw_xctx_t *xctx)
 Get the value inf associated with a value inf id. More...
 
void afw_environment_set_debug_fd (FILE *fd, afw_xctx_t *xctx)
 Override fd used for debug. More...
 
void afw_environment_set_stderr_fd (FILE *fd, afw_xctx_t *xctx)
 Override fd used for stderr. More...
 
void afw_environment_set_stdout_fd (FILE *fd, afw_xctx_t *xctx)
 Override fd used for stdout. More...
 

Detailed Description

Header for adaptive framework environment.

Internal header for AFW environment.

Definition in file afw_environment.h.