Package io.micronaut.openapi.generator
Class Utils
java.lang.Object
io.micronaut.openapi.generator.Utils
Utilities methods to generators.
- Since:
- 5.2.0
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
addStrValueToEnum
(List<Object> enumVars, boolean isNumeric) static void
addStrValueToEnum
(org.openapitools.codegen.CodegenModel model) static void
addStrValueToEnum
(org.openapitools.codegen.CodegenProperty property) static boolean
isDateType
(String type) static void
normalizeExtraAnnotations
(String extName, boolean isKotlin, Map<String, Object> vendorExtensions) static void
processGenericAnnotations
(String dataType, String dataTypeWithEnum, boolean isMap, String containerType, org.openapitools.codegen.CodegenProperty itemsProp, Map<String, Object> ext, boolean useBeanValidation, boolean isGenerateHardNullable, boolean isNullable, boolean isRequired, boolean isReadonly, boolean withNullablePostfix) static void
processGenericAnnotations
(org.openapitools.codegen.CodegenParameter parameter, boolean useBeanValidation, boolean isGenerateHardNullable, boolean isNullable, boolean isRequired, boolean isReadonly, boolean withNullablePostfix) static void
processGenericAnnotations
(org.openapitools.codegen.CodegenProperty property, boolean useBeanValidation, boolean isGenerateHardNullable, boolean isNullable, boolean isRequired, boolean isReadonly, boolean withNullablePostfix) processMultipartBody
(org.openapitools.codegen.CodegenOperation op, Collection<org.openapitools.codegen.CodegenParameter> params, boolean isKotlin) Replace multipart data parameters, marked @Part annotation to single MultipartBody parameter.static String
-
Field Details
-
DATE_TIME_TYPES
-
DIVIDE_OPERATIONS_BY_CONTENT_TYPE
- See Also:
-
DEFAULT_BODY_PARAM_NAME
- See Also:
-
EXT_ANNOTATIONS_OPERATION
- See Also:
-
EXT_ANNOTATIONS_CLASS
- See Also:
-
EXT_ANNOTATIONS_FIELD
- See Also:
-
EXT_ANNOTATIONS_SETTER
- See Also:
-
-
Method Details
-
processMultipartBody
public static org.apache.commons.lang3.tuple.Pair<org.openapitools.codegen.CodegenParameter,Set<String>> processMultipartBody(org.openapitools.codegen.CodegenOperation op, Collection<org.openapitools.codegen.CodegenParameter> params, boolean isKotlin) Replace multipart data parameters, marked @Part annotation to single MultipartBody parameter.- Parameters:
op
- operationparams
- parametersisKotlin
- is kotlin generator- Returns:
- Pair with MultipartBody parameter and set of removed parameter names
-
processGenericAnnotations
public static void processGenericAnnotations(org.openapitools.codegen.CodegenParameter parameter, boolean useBeanValidation, boolean isGenerateHardNullable, boolean isNullable, boolean isRequired, boolean isReadonly, boolean withNullablePostfix) -
processGenericAnnotations
public static void processGenericAnnotations(org.openapitools.codegen.CodegenProperty property, boolean useBeanValidation, boolean isGenerateHardNullable, boolean isNullable, boolean isRequired, boolean isReadonly, boolean withNullablePostfix) -
processGenericAnnotations
public static void processGenericAnnotations(String dataType, String dataTypeWithEnum, boolean isMap, String containerType, org.openapitools.codegen.CodegenProperty itemsProp, Map<String, Object> ext, boolean useBeanValidation, boolean isGenerateHardNullable, boolean isNullable, boolean isRequired, boolean isReadonly, boolean withNullablePostfix) -
addStrValueToEnum
public static void addStrValueToEnum(org.openapitools.codegen.CodegenProperty property) -
addStrValueToEnum
public static void addStrValueToEnum(org.openapitools.codegen.CodegenModel model) -
addStrValueToEnum
-
toApiName
-
normalizeExtraAnnotations
-
isDateType
-