18 impl_create_property_type(
29 self->property_type_object = property_type_object;
32 property_type_object, &afw_s_contextType, xctx);
35 &afw_s_defaultValue, xctx);
38 property_type_object, &afw_s_dataTypeParameter, xctx);
41 &afw_s_dataType, xctx);
47 property_type_object, &afw_s_allowWrite, &found, xctx) || !found;
50 &afw_s_allowQuery, xctx);
53 &afw_s_required, xctx);
75 self->adaptor_id = &adaptor->adaptor_id;
76 self->object_type_object = object_type_object;
77 self->object_type_id = object_type_object->meta.
id;
80 object_type_object, &afw_s_propertyTypes, xctx);
81 if (self->property_types_object) {
83 while ((property_type_object =
85 &iterator, &property_name, xctx)))
87 property_type = impl_create_property_type(
88 self->property_types_object, property_type_object, p, xctx);
89 property_type->property_name = property_name;
90 property_type->next =
self->first_property_type;
91 self->first_property_type = property_type;
96 object_type_object, &afw_s_otherProperties, xctx);
97 if (self->other_properties_object) {
98 self->other_properties =
99 impl_create_property_type(
100 self->property_types_object, self->other_properties_object,
118 for (result = object_type->first_property_type;
120 result = result->next);
123 result = object_type->other_properties;
141 if (!object_type->first_property_type) {
144 *property_name = NULL;
150 result = object_type->first_property_type;
156 if (result && property_name) {
157 *property_name = result->property_name;
181 normalization_needed =
false;
186 if (pt->data_type && pt->data_type != data_type) {
187 normalization_needed =
true;
188 data_type = pt->data_type;
193 if (normalization_needed) {
197 "Normalize not supported for object",
207 embedded_object_type_id =
209 pt->property_type_object, &afw_s_dataTypeParameter, xctx);
210 if (embedded_object_type_id) {
212 object, embedded_object_type_id, xctx);
234 property_name, xctx);
AFW_DEFINE(const afw_object_t *)
Adaptive Framework Core Internal.
#define afw_object_old_get_property_as_boolean(object, property_name, found, xctx)
Get property function for data type boolean value.
#define afw_value_is_object(A_VALUE)
Macro to determine if value is evaluated object.
#define afw_object_old_get_property_as_object(object, property_name, xctx)
Get property function for data type object value.
afw_data_type_object
Data type struct for object.
#define afw_object_old_get_next_property_as_object(object, iterator, property_name, xctx)
Get next property function for data type object value.
#define afw_object_old_get_property_as_string(object, property_name, xctx)
Get property function for data type string value.
struct afw_iterator_s afw_iterator_t
const afw_data_type_t * afw_environment_get_data_type(const afw_utf8_t *type, afw_xctx_t *xctx)
Get the data_type associated with configuration entry type.
#define AFW_THROW_ERROR_Z(code, message_z, xctx)
Macro used to set error and 0 rv in xctx and throw it.
#define afw_object_get_property(instance, property_name, xctx)
Call method get_property of interface afw_object.
afw_object_type_property_type_get(const afw_object_type_t *object_type, const afw_utf8_t *property_name, afw_xctx_t *xctx)
Get property type object for property.
afw_object_type_property_type_get_next(const afw_object_type_t *object_type, const afw_iterator_t **iterator, const afw_utf8_t **property_name, afw_xctx_t *xctx)
Get next property type for object type.
afw_object_type_property_type_normalize(const afw_object_type_property_type_t *pt, const afw_value_t *value, const afw_pool_t *p, afw_xctx_t *xctx)
Normalize a value based on property type.
const afw_object_type_t * afw_object_type_internal_create(const afw_adaptor_t *adaptor, const afw_object_t *object_type_object, const afw_pool_t *p, afw_xctx_t *xctx)
Create an object type.
afw_object_type_property_normalize(const afw_object_type_t *object_type, const afw_utf8_t *property_name, const afw_value_t *value, const afw_pool_t *p, afw_xctx_t *xctx)
Normalize a value based an object type and property name.
afw_object_old_get_property_as_boolean_deprecated(const afw_object_t *instance, const afw_utf8_t *property_name, afw_xctx_t *xctx)
Get an object's property value as a boolean.
#define afw_pool_calloc_type(instance, type, xctx)
Macro to allocate cleared memory to hold type in pool.
afw_boolean_t afw_utf8_equal(const afw_utf8_t *s1, const afw_utf8_t *s2)
Check to see if a string equals another string.
#define afw_value_get_data_type(instance, xctx)
Call method get_data_type of interface afw_value.
#define afw_value_evaluate(value, p, xctx)
Evaluate value if needed using specific pool.
afw_value_convert(const afw_value_t *value, const afw_data_type_t *to_data_type, afw_boolean_t required, const afw_pool_t *p, afw_xctx_t *xctx)
Convert a value to a value/data type.
Interface afw_adaptor public struct.
Interface afw_data_type public struct.
Interface afw_object public struct.
Struct for afw_object_type_property_type_t.
Struct for afw_object_type_t.
Interface afw_pool public struct.
NFC normalized UTF-8 string.
struct for data type object values.
Interface afw_value public struct.
Interface afw_xctx public struct.