mirror of
https://github.com/open5gs/open5gs.git
synced 2026-05-04 22:30:09 +00:00
Upgrade SBI(Service-based Interface)
* OpenAPI Generator version: 4.3.1 ==> 5.5.1 * Specification : r16.8.0 (20210629)
This commit is contained in:
parent
2aaa8200c2
commit
f278d58a69
1914 changed files with 91329 additions and 57361 deletions
|
|
@ -10,7 +10,7 @@ OpenAPI_lmf_info_t *OpenAPI_lmf_info_create(
|
|||
OpenAPI_list_t *serving_access_types,
|
||||
OpenAPI_list_t *serving_an_node_types,
|
||||
OpenAPI_list_t *serving_rat_types
|
||||
)
|
||||
)
|
||||
{
|
||||
OpenAPI_lmf_info_t *lmf_info_local_var = OpenAPI_malloc(sizeof(OpenAPI_lmf_info_t));
|
||||
if (!lmf_info_local_var) {
|
||||
|
|
@ -53,75 +53,75 @@ cJSON *OpenAPI_lmf_info_convertToJSON(OpenAPI_lmf_info_t *lmf_info)
|
|||
|
||||
item = cJSON_CreateObject();
|
||||
if (lmf_info->serving_client_types) {
|
||||
cJSON *serving_client_typesList = cJSON_AddArrayToObject(item, "servingClientTypes");
|
||||
if (serving_client_typesList == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_client_types]");
|
||||
goto end;
|
||||
}
|
||||
cJSON *serving_client_typesList = cJSON_AddArrayToObject(item, "servingClientTypes");
|
||||
if (serving_client_typesList == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_client_types]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_lnode_t *serving_client_types_node;
|
||||
if (lmf_info->serving_client_types) {
|
||||
OpenAPI_list_for_each(lmf_info->serving_client_types, serving_client_types_node) {
|
||||
cJSON *itemLocal = OpenAPI_external_client_type_convertToJSON(serving_client_types_node->data);
|
||||
if (itemLocal == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_client_types]");
|
||||
goto end;
|
||||
}
|
||||
cJSON_AddItemToArray(serving_client_typesList, itemLocal);
|
||||
OpenAPI_lnode_t *serving_client_types_node;
|
||||
if (lmf_info->serving_client_types) {
|
||||
OpenAPI_list_for_each(lmf_info->serving_client_types, serving_client_types_node) {
|
||||
cJSON *itemLocal = OpenAPI_external_client_type_convertToJSON(serving_client_types_node->data);
|
||||
if (itemLocal == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_client_types]");
|
||||
goto end;
|
||||
}
|
||||
cJSON_AddItemToArray(serving_client_typesList, itemLocal);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (lmf_info->lmf_id) {
|
||||
if (cJSON_AddStringToObject(item, "lmfId", lmf_info->lmf_id) == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [lmf_id]");
|
||||
goto end;
|
||||
}
|
||||
if (cJSON_AddStringToObject(item, "lmfId", lmf_info->lmf_id) == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [lmf_id]");
|
||||
goto end;
|
||||
}
|
||||
}
|
||||
|
||||
if (lmf_info->serving_access_types) {
|
||||
cJSON *serving_access_types = cJSON_AddArrayToObject(item, "servingAccessTypes");
|
||||
if (serving_access_types == NULL) {
|
||||
cJSON *serving_access_types = cJSON_AddArrayToObject(item, "servingAccessTypes");
|
||||
if (serving_access_types == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_access_types]");
|
||||
goto end;
|
||||
}
|
||||
OpenAPI_lnode_t *serving_access_types_node;
|
||||
OpenAPI_list_for_each(lmf_info->serving_access_types, serving_access_types_node) {
|
||||
if (cJSON_AddStringToObject(serving_access_types, "", OpenAPI_access_type_ToString((intptr_t)serving_access_types_node->data)) == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_access_types]");
|
||||
goto end;
|
||||
}
|
||||
OpenAPI_lnode_t *serving_access_types_node;
|
||||
OpenAPI_list_for_each(lmf_info->serving_access_types, serving_access_types_node) {
|
||||
if (cJSON_AddStringToObject(serving_access_types, "", OpenAPI_access_type_ToString((intptr_t)serving_access_types_node->data)) == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_access_types]");
|
||||
goto end;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (lmf_info->serving_an_node_types) {
|
||||
cJSON *serving_an_node_types = cJSON_AddArrayToObject(item, "servingAnNodeTypes");
|
||||
if (serving_an_node_types == NULL) {
|
||||
cJSON *serving_an_node_types = cJSON_AddArrayToObject(item, "servingAnNodeTypes");
|
||||
if (serving_an_node_types == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_an_node_types]");
|
||||
goto end;
|
||||
}
|
||||
OpenAPI_lnode_t *serving_an_node_types_node;
|
||||
OpenAPI_list_for_each(lmf_info->serving_an_node_types, serving_an_node_types_node) {
|
||||
if (cJSON_AddStringToObject(serving_an_node_types, "", OpenAPI_an_node_type_ToString((intptr_t)serving_an_node_types_node->data)) == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_an_node_types]");
|
||||
goto end;
|
||||
}
|
||||
OpenAPI_lnode_t *serving_an_node_types_node;
|
||||
OpenAPI_list_for_each(lmf_info->serving_an_node_types, serving_an_node_types_node) {
|
||||
if (cJSON_AddStringToObject(serving_an_node_types, "", OpenAPI_an_node_type_ToString((intptr_t)serving_an_node_types_node->data)) == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_an_node_types]");
|
||||
goto end;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (lmf_info->serving_rat_types) {
|
||||
cJSON *serving_rat_types = cJSON_AddArrayToObject(item, "servingRatTypes");
|
||||
if (serving_rat_types == NULL) {
|
||||
cJSON *serving_rat_types = cJSON_AddArrayToObject(item, "servingRatTypes");
|
||||
if (serving_rat_types == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_rat_types]");
|
||||
goto end;
|
||||
}
|
||||
OpenAPI_lnode_t *serving_rat_types_node;
|
||||
OpenAPI_list_for_each(lmf_info->serving_rat_types, serving_rat_types_node) {
|
||||
if (cJSON_AddStringToObject(serving_rat_types, "", OpenAPI_rat_type_ToString((intptr_t)serving_rat_types_node->data)) == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_rat_types]");
|
||||
goto end;
|
||||
}
|
||||
OpenAPI_lnode_t *serving_rat_types_node;
|
||||
OpenAPI_list_for_each(lmf_info->serving_rat_types, serving_rat_types_node) {
|
||||
if (cJSON_AddStringToObject(serving_rat_types, "", OpenAPI_rat_type_ToString((intptr_t)serving_rat_types_node->data)) == NULL) {
|
||||
ogs_error("OpenAPI_lmf_info_convertToJSON() failed [serving_rat_types]");
|
||||
goto end;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
end:
|
||||
|
|
@ -134,100 +134,100 @@ OpenAPI_lmf_info_t *OpenAPI_lmf_info_parseFromJSON(cJSON *lmf_infoJSON)
|
|||
cJSON *serving_client_types = cJSON_GetObjectItemCaseSensitive(lmf_infoJSON, "servingClientTypes");
|
||||
|
||||
OpenAPI_list_t *serving_client_typesList;
|
||||
if (serving_client_types) {
|
||||
cJSON *serving_client_types_local_nonprimitive;
|
||||
if (!cJSON_IsArray(serving_client_types)) {
|
||||
if (serving_client_types) {
|
||||
cJSON *serving_client_types_local_nonprimitive;
|
||||
if (!cJSON_IsArray(serving_client_types)){
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_client_types]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
serving_client_typesList = OpenAPI_list_create();
|
||||
|
||||
cJSON_ArrayForEach(serving_client_types_local_nonprimitive, serving_client_types ) {
|
||||
if (!cJSON_IsObject(serving_client_types_local_nonprimitive)) {
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_client_types]");
|
||||
goto end;
|
||||
}
|
||||
OpenAPI_external_client_type_t *serving_client_typesItem = OpenAPI_external_client_type_parseFromJSON(serving_client_types_local_nonprimitive);
|
||||
|
||||
serving_client_typesList = OpenAPI_list_create();
|
||||
|
||||
cJSON_ArrayForEach(serving_client_types_local_nonprimitive, serving_client_types ) {
|
||||
if (!cJSON_IsObject(serving_client_types_local_nonprimitive)) {
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_client_types]");
|
||||
goto end;
|
||||
}
|
||||
OpenAPI_external_client_type_t *serving_client_typesItem = OpenAPI_external_client_type_parseFromJSON(serving_client_types_local_nonprimitive);
|
||||
|
||||
OpenAPI_list_add(serving_client_typesList, serving_client_typesItem);
|
||||
}
|
||||
OpenAPI_list_add(serving_client_typesList, serving_client_typesItem);
|
||||
}
|
||||
}
|
||||
|
||||
cJSON *lmf_id = cJSON_GetObjectItemCaseSensitive(lmf_infoJSON, "lmfId");
|
||||
|
||||
if (lmf_id) {
|
||||
if (!cJSON_IsString(lmf_id)) {
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [lmf_id]");
|
||||
goto end;
|
||||
}
|
||||
if (lmf_id) {
|
||||
if (!cJSON_IsString(lmf_id)) {
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [lmf_id]");
|
||||
goto end;
|
||||
}
|
||||
}
|
||||
|
||||
cJSON *serving_access_types = cJSON_GetObjectItemCaseSensitive(lmf_infoJSON, "servingAccessTypes");
|
||||
|
||||
OpenAPI_list_t *serving_access_typesList;
|
||||
if (serving_access_types) {
|
||||
cJSON *serving_access_types_local_nonprimitive;
|
||||
if (!cJSON_IsArray(serving_access_types)) {
|
||||
if (serving_access_types) {
|
||||
cJSON *serving_access_types_local_nonprimitive;
|
||||
if (!cJSON_IsArray(serving_access_types)) {
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_access_types]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
serving_access_typesList = OpenAPI_list_create();
|
||||
|
||||
cJSON_ArrayForEach(serving_access_types_local_nonprimitive, serving_access_types ) {
|
||||
if (!cJSON_IsString(serving_access_types_local_nonprimitive)){
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_access_types]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
serving_access_typesList = OpenAPI_list_create();
|
||||
|
||||
cJSON_ArrayForEach(serving_access_types_local_nonprimitive, serving_access_types ) {
|
||||
if (!cJSON_IsString(serving_access_types_local_nonprimitive)) {
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_access_types]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(serving_access_typesList, (void *)OpenAPI_access_type_FromString(serving_access_types_local_nonprimitive->valuestring));
|
||||
}
|
||||
OpenAPI_list_add(serving_access_typesList, (void *)OpenAPI_access_type_FromString(serving_access_types_local_nonprimitive->valuestring));
|
||||
}
|
||||
}
|
||||
|
||||
cJSON *serving_an_node_types = cJSON_GetObjectItemCaseSensitive(lmf_infoJSON, "servingAnNodeTypes");
|
||||
|
||||
OpenAPI_list_t *serving_an_node_typesList;
|
||||
if (serving_an_node_types) {
|
||||
cJSON *serving_an_node_types_local_nonprimitive;
|
||||
if (!cJSON_IsArray(serving_an_node_types)) {
|
||||
if (serving_an_node_types) {
|
||||
cJSON *serving_an_node_types_local_nonprimitive;
|
||||
if (!cJSON_IsArray(serving_an_node_types)) {
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_an_node_types]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
serving_an_node_typesList = OpenAPI_list_create();
|
||||
|
||||
cJSON_ArrayForEach(serving_an_node_types_local_nonprimitive, serving_an_node_types ) {
|
||||
if (!cJSON_IsString(serving_an_node_types_local_nonprimitive)){
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_an_node_types]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
serving_an_node_typesList = OpenAPI_list_create();
|
||||
|
||||
cJSON_ArrayForEach(serving_an_node_types_local_nonprimitive, serving_an_node_types ) {
|
||||
if (!cJSON_IsString(serving_an_node_types_local_nonprimitive)) {
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_an_node_types]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(serving_an_node_typesList, (void *)OpenAPI_an_node_type_FromString(serving_an_node_types_local_nonprimitive->valuestring));
|
||||
}
|
||||
OpenAPI_list_add(serving_an_node_typesList, (void *)OpenAPI_an_node_type_FromString(serving_an_node_types_local_nonprimitive->valuestring));
|
||||
}
|
||||
}
|
||||
|
||||
cJSON *serving_rat_types = cJSON_GetObjectItemCaseSensitive(lmf_infoJSON, "servingRatTypes");
|
||||
|
||||
OpenAPI_list_t *serving_rat_typesList;
|
||||
if (serving_rat_types) {
|
||||
cJSON *serving_rat_types_local_nonprimitive;
|
||||
if (!cJSON_IsArray(serving_rat_types)) {
|
||||
if (serving_rat_types) {
|
||||
cJSON *serving_rat_types_local_nonprimitive;
|
||||
if (!cJSON_IsArray(serving_rat_types)) {
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_rat_types]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
serving_rat_typesList = OpenAPI_list_create();
|
||||
|
||||
cJSON_ArrayForEach(serving_rat_types_local_nonprimitive, serving_rat_types ) {
|
||||
if (!cJSON_IsString(serving_rat_types_local_nonprimitive)){
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_rat_types]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
serving_rat_typesList = OpenAPI_list_create();
|
||||
|
||||
cJSON_ArrayForEach(serving_rat_types_local_nonprimitive, serving_rat_types ) {
|
||||
if (!cJSON_IsString(serving_rat_types_local_nonprimitive)) {
|
||||
ogs_error("OpenAPI_lmf_info_parseFromJSON() failed [serving_rat_types]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(serving_rat_typesList, (void *)OpenAPI_rat_type_FromString(serving_rat_types_local_nonprimitive->valuestring));
|
||||
}
|
||||
OpenAPI_list_add(serving_rat_typesList, (void *)OpenAPI_rat_type_FromString(serving_rat_types_local_nonprimitive->valuestring));
|
||||
}
|
||||
}
|
||||
|
||||
lmf_info_local_var = OpenAPI_lmf_info_create (
|
||||
serving_client_types ? serving_client_typesList : NULL,
|
||||
|
|
@ -235,7 +235,7 @@ OpenAPI_lmf_info_t *OpenAPI_lmf_info_parseFromJSON(cJSON *lmf_infoJSON)
|
|||
serving_access_types ? serving_access_typesList : NULL,
|
||||
serving_an_node_types ? serving_an_node_typesList : NULL,
|
||||
serving_rat_types ? serving_rat_typesList : NULL
|
||||
);
|
||||
);
|
||||
|
||||
return lmf_info_local_var;
|
||||
end:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue