46 &afw_s_stopping_adaptor_instances,
52 &afw_s_applicable_flags,
58 &afw_s_stopping_authorization_handler_instances,
64 &afw_s_adaptor_metrics,
70 &afw_s_null_terminated_array_of_internal,
76 &afw_s_null_terminated_array_of_objects,
82 &afw_s_null_terminated_array_of_utf8_z_key_value_pair_objects,
88 &afw_s_null_terminated_array_of_pointers,
94 &afw_s_null_terminated_array_of_values,
106 &afw_s_service_startup,
112 &afw_s_service_status,
124 &afw_s_adaptor_additional_metrics,
130 &afw_s_afw_components_extension_loaded,
157 if (prop->data_type->cType.s[prop->data_type->cType.len - 1] ==
'*'
158 && !*(
void **)
internal)
211 if (!
internal)
return NULL;
305 authorization_handler_id = *(
const afw_utf8_t **)
internal;
310 authorization_handler_id,
359 memcpy(&startup,
internal,
sizeof(startup));
374 memcpy(&status,
internal,
sizeof(status));
434 for (i = 0; i <
self->applicable_flags_count_allocated; i++) {
435 if (self->applicable_flags[i]) {
456 if (!
internal || !*(
void **)
internal)
464 "data type must be list for value accessor array_of_pointers.",
469 if (!prop->data_type_parameter_data_type) {
475 false, prop->data_type_parameter_data_type, -1, p, xctx);
527 for (; *s_z; s_z++) {
554 if (!
internal || !*(
void **)
internal)
562 "data type must be list for value accessor array_of_pointers.",
567 if (!prop->data_type_parameter_data_type) {
573 true, prop->data_type_parameter_data_type, -1, p, xctx);
Adaptive Framework Core Internal.
Core runtime value accessors.
#define afw_adaptor_get_additional_metrics(instance, p, xctx)
Call method get_additional_metrics of interface afw_adaptor.
afw_value_create_integer(afw_integer_t internal, const afw_pool_t *p, afw_xctx_t *xctx)
Create function for unmanaged data type integer value.
afw_data_type_integer
Data type struct for integer.
afw_value_create_list(const afw_list_t *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Create function for unmanaged data type list value.
afw_data_type_list
Data type struct for list.
afw_value_create_object(const afw_object_t *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Create function for unmanaged data type object value.
afw_value_create_string(const afw_utf8_t *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Create function for unmanaged data type string value.
#define AFW_UTF8_Z_LEN
String is NUL (0) terminate.
enum afw_service_status_e afw_service_status_t
Typedef for service status enum.
enum afw_service_startup_e afw_service_startup_t
Typedef for service startup type enum.
afw_utf8_octet_t afw_utf8_z_t
NFC normalized UTF-8 null terminated string.
apr_uint32_t afw_uint32_t
32-bit unsigned integer.
enum afw_compile_type_e afw_compile_type_t
Compile type enum.
apr_size_t afw_size_t
size_t.
unsigned char afw_octet_t
8 bits (unsigned).
apr_int64_t afw_integer_t
typedef for big signed int.
afw_compile_type_get_info(afw_compile_type_t compile_type, const afw_xctx_t *xctx)
Return info for a afw_compile_type_t.
afw_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.
const afw_authorization_handler_id_anchor_t * afw_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.
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.
const afw_adaptor_id_anchor_t * afw_environment_get_adaptor_id(const afw_utf8_t *adaptor_id, afw_xctx_t *xctx)
Get the adaptor id anchor associated with adaptor id.
#define AFW_THROW_ERROR_Z(code, message_z, xctx)
Macro used to set error and 0 rv in xctx and throw it.
afw_flag_get_by_index(afw_size_t flag_index, afw_xctx_t *xctx)
Get flag by index.
const afw_list_t * afw_list_const_create_null_terminated_array_of_objects(const afw_object_t *const *objects, const afw_pool_t *p, afw_xctx_t *xctx)
Create an immutable list from NULL terminated array of objects.
afw_list_create_wrapper_for_array(const void *array, afw_boolean_t indirect, const afw_data_type_t *data_type, afw_size_t count, const afw_pool_t *p, afw_xctx_t *xctx)
Create a immutable list wrapper for an array.
const afw_list_t * afw_list_const_create_null_terminated_array_of_values(const afw_value_t *const *values, const afw_pool_t *p, afw_xctx_t *xctx)
Create an immutable list from NULL terminated array of values.
#define afw_list_create_generic(p, xctx)
Create an value list in memory.
afw_list_add_value(const afw_list_t *instance, const afw_value_t *value, afw_xctx_t *xctx)
Call method add_value of interface afw_list_setter.
#define AFW_LOCK_BEGIN(instance)
Macro to begin a lock section.
#define AFW_LOCK_END
Macro to end a lock section.
#define AFW_LOCK_WRITE_BEGIN(instance)
Macro to begin a write lock section.
#define AFW_LOCK_WRITE_END
Macro to end a write lock section.
#define afw_object_create(p, xctx)
Create an empty unmanaged object in memory.
afw_object_set_property(const afw_object_t *instance, const afw_utf8_t *property_name, const afw_value_t *value, afw_xctx_t *xctx)
Set the value of an object's property.
#define afw_pool_malloc(instance, size, xctx)
Call method malloc of interface afw_pool.
const afw_value_t * afw_runtime_value_accessor_compile_type(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor 'compile_type'.
const afw_value_t * afw_runtime_value_accessor_service_status(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for afw_service_status_t.
const afw_value_t * afw_runtime_value_accessor_applicable_flags(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor to produce triggeredBy for a flag.
const afw_value_t * afw_runtime_value_accessor_size(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for afw_size_t as afw_integer_t.
const afw_value_t * afw_runtime_value_accessor_adaptor_additional_metrics(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor to call afw_adaptor_get_additional_metrics().
const afw_value_t * afw_runtime_value_accessor_null_terminated_array_of_internal(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for NULL terminated list of internal.
const afw_value_t * afw_runtime_value_accessor_octet(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for afw_octet_t as afw_integer_t.
const afw_value_t * afw_runtime_value_accessor_stopping_authorization_handler_instances(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for stopping authorization handler reference counts.
const afw_value_t * afw_runtime_value_accessor_uint32(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for afw_uint32_t as afw_integer_t.
const afw_value_t * afw_runtime_value_accessor_default(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor 'default' for default internal.
const afw_value_t * afw_runtime_value_accessor_ensure_afw_components_extension_loaded(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor to ensure afw_components extension is loaded.
void afw_runtime_register_core_value_accessors(afw_xctx_t *xctx)
Register core runtime value accessors.
const afw_value_t * afw_runtime_value_accessor_stopping_adaptor_instances(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for stopping adaptor instance reference counts.
const afw_value_t * afw_runtime_value_accessor_indirect(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor 'indirect' for indirect internal.
const afw_value_t * afw_runtime_value_accessor_service_startup(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for afw_service_startup_t.
const afw_value_t * afw_runtime_value_accessor_null_terminated_array_of_values(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for NULL terminated list of values.
const afw_value_t * afw_runtime_value_accessor_value(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for an afw_value_t.
const afw_value_t * afw_runtime_value_accessor_null_terminated_array_of_utf8_z_key_value_pair_objects(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for NULL terminated list of utf8_z key/value pair objects.
const afw_value_t * afw_runtime_value_accessor_null_terminated_array_of_pointers(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for NULL terminated list of internal pointers.
const afw_value_t * afw_runtime_value_accessor_null_terminated_array_of_objects(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for NULL terminated list of objects.
const afw_value_t * afw_runtime_value_accessor_adaptor_metrics(const afw_runtime_object_map_property_t *prop, const void *internal, const afw_pool_t *p, afw_xctx_t *xctx)
Runtime value accessor for /afw/_AdaptiveAdaptorMetrics_/<adaptorId>.
afw_service_status_as_utf8(afw_service_status_t status)
Convert afw_service_status_t enum to corresponding utf8.
afw_service_startup_as_utf8(afw_service_startup_t startup)
Convert afw_service_startup_t enum to corresponding utf8.
afw_boolean_t afw_utf8_equal_utf8_z(const afw_utf8_t *s1, const afw_utf8_z_t *s2_z)
Check to see if a string equals a utf8_z string.
#define afw_utf8_create(s, len, p, xctx)
Create utf-8 string without copy unless necessary in pool specified.
afw_value_clone(const afw_value_t *value, const afw_pool_t *p, afw_xctx_t *xctx)
Clone a value to specified pool.
const afw_value_t * afw_value_evaluated_create(const void *value, const afw_data_type_t *data_type, const afw_pool_t *p, afw_xctx_t *xctx)
Create function for an evaluated data type value.
afw_value_true
Adaptive value true.
afw_value_create_string_from_u8z(const afw_utf8_z_t *string_z, const afw_pool_t *p, afw_xctx_t *xctx)
afw_integer_t reference_count
Reference count for this instance of adaptor.
afw_adaptor_id_anchor_t * stopping
First/next stopping adaptor or NULL.
Internal struct used by common adaptor code for all adaptors.
const afw_object_t * metrics_object
Metrics object.
const afw_adaptor_t * adaptor
Associated adaptor instance.
Interface afw_adaptor public struct.
afw_integer_t reference_count
Reference count for this instance of authorization handler.
afw_authorization_handler_id_anchor_t * stopping
First/next stopping authorization handler or NULL.
const afw_lock_t * adaptor_id_anchor_lock
Lock for protecting changes to adaptor id anchors.
const afw_lock_rw_t * authorization_handler_id_anchor_rw_lock
Lock for protecting changes to authorization handler id anchors.
Struct used for a registered flag.
const afw_value_t * flag_id_value
sting value of objectId of this flag.
Interface afw_list public struct.
Struct for memory pointer and size.
Interface afw_object public struct.
Interface afw_pool public struct.
Struct for runtime object map property.
NFC normalized UTF-8 string.
Interface afw_value public struct.
Interface afw_xctx public struct.