src/swagger2x.py
def convert_to_c_type_array_size(json_type):
    """
    convert the json type to c type
    :param json_type: the json type
    :return: c type.
    """
    if json_type == "boolean":
        return 0
    if json_type == "number":
        return 0
    if json_type == "integer":
        return 0
    if json_type == "string":
        # string is already an array
        return 1

    # array versions e.g. postpended with []
    if json_type == "string[]":
        return 2
    if json_type == "integer[]":
        return 1
    if json_type == "boolean[]":
        return 1
    if json_type == "number[]":
        return 1

    # array versions e.g. postpended with [][]
    if json_type == "string[][]":
        return 3
    if json_type == "integer[][]":
        return 2
    if json_type == "boolean[][]":
        return 2
    if json_type == "number[][]":
        return 2

    return "void*"

    convert the json type to c type
    :param json_type: the json type
    :return: c type.
    
convert the json type to c type
convert the json type to c type
def convert_to_c_type_array_size(json_type):
    if json_type == "boolean":
        return 0
    if json_type == "number":
        return 0
    if json_type == "integer":
        return 0
    if json_type == "string":
        return 1
    if json_type == "string[]":
        return 2
    if json_type == "integer[]":
        return 1
    if json_type == "boolean[]":
        return 1
    if json_type == "number[]":
        return 1
    if json_type == "string[][]":
        return 3
    if json_type == "integer[][]":
        return 2
    if json_type == "boolean[][]":
        return 2
    if json_type == "number[][]":
        return 2
    return "void*"
def convert_to_c_type_array_size ( json_type ) : if json_type == "boolean" : return 0 if json_type == "number" : return 0 if json_type == "integer" : return 0 if json_type == "string" : return 1 if json_type == "string[]" : return 2 if json_type == "integer[]" : return 1 if json_type == "boolean[]" : return 1 if json_type == "number[]" : return 1 if json_type == "string[][]" : return 3 if json_type == "integer[][]" : return 2 if json_type == "boolean[][]" : return 2 if json_type == "number[][]" : return 2 return "void*"
convert the json type to c type
convert the json type to c type
"""
    convert the json type to c type
    :param json_type: the json type
    :return: c type.
    """ # string is already an array
 # array versions e.g. postpended with []
 # array versions e.g. postpended with [][]

None
json_type
the json type
the json type