[openapi] Add support for nullable fields

Depending on the OpenAPI yaml files, fields can be marked as "nullable".
Which means that the field can be either present, not present, or null.

This feature is important for example in SmContextUpdateData structure,
where many fields are described similar as the following:
This IE shall be included for the modification .... For deleting the
field, it shall contain the Null value.
This commit is contained in:
Bostjan Meglic 2023-10-05 13:39:14 +02:00 committed by Sukchan Lee
parent 7ea37ef618
commit 50464d174e
154 changed files with 2773 additions and 0 deletions

View file

@ -22,26 +22,32 @@ extern "C" {
typedef struct OpenAPI_pp_data_entry_s OpenAPI_pp_data_entry_t;
typedef struct OpenAPI_pp_data_entry_s {
bool is_communication_characteristics_null;
struct OpenAPI_communication_characteristics_af_s *communication_characteristics;
bool is_reference_id;
int reference_id;
char *validity_time;
char *mtc_provider_information;
char *supported_features;
bool is_ecs_addr_config_info_null;
struct OpenAPI_ecs_addr_config_info_1_s *ecs_addr_config_info;
OpenAPI_list_t *additional_ecs_addr_config_infos;
bool is_ec_restriction_null;
struct OpenAPI_ec_restriction_1_s *ec_restriction;
} OpenAPI_pp_data_entry_t;
OpenAPI_pp_data_entry_t *OpenAPI_pp_data_entry_create(
bool is_communication_characteristics_null,
OpenAPI_communication_characteristics_af_t *communication_characteristics,
bool is_reference_id,
int reference_id,
char *validity_time,
char *mtc_provider_information,
char *supported_features,
bool is_ecs_addr_config_info_null,
OpenAPI_ecs_addr_config_info_1_t *ecs_addr_config_info,
OpenAPI_list_t *additional_ecs_addr_config_infos,
bool is_ec_restriction_null,
OpenAPI_ec_restriction_1_t *ec_restriction
);
void OpenAPI_pp_data_entry_free(OpenAPI_pp_data_entry_t *pp_data_entry);