Class JavaArrayType
java.lang.Object
com.github.muehmar.gradle.openapi.generator.java.model.type.JavaArrayType
- All Implemented Interfaces:
JavaType
Wraps a
ArrayType but not to be confused with actual java arrays.-
Method Summary
Modifier and TypeMethodDescription<T> Tfold(Function<JavaArrayType, T> onArrayType, Function<JavaBooleanType, T> onBooleanType, Function<JavaEnumType, T> onEnumType, Function<JavaMapType, T> onMapType, Function<JavaAnyType, T> onAnyType, Function<JavaNumericType, T> onNumericType, Function<JavaIntegerType, T> onIntegerType, Function<JavaObjectType, T> onObjectType, Function<JavaStringType, T> onStringType) Returns the qualified classnames used for this type, including the classes of possible type parameters as well as possible api types.Returns the parameterized classname of the java type used internally.Returns the qualified classname of the java type used internally in the DTO for serialization and validation.booleanReturns true in case this class is a java array (not to be confused with the openapi array-type).withNullability(Nullability nullability) static JavaArrayTypewrap(ArrayType arrayType, TypeMappings typeMappings) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.github.muehmar.gradle.openapi.generator.java.model.type.JavaType
getImports, getImportsAsString, getParameterizedApiClassName, getWriteableParameterizedClassName, hasApiTypeDeep, hasNoApiTypeDeep, isAnyType, isArrayType, isContainerType, isIntegerType, isMapType, isNullableContainerValueType, isNullableItemsArrayType, isNullableValuesMapType, isNumericType, onArrayType, onMapType
-
Method Details
-
wrap
-
getQualifiedClassName
Description copied from interface:JavaTypeReturns the qualified classname of the java type used internally in the DTO for serialization and validation.- Specified by:
getQualifiedClassNamein interfaceJavaType
-
getApiType
Description copied from interface:JavaTypeReturns theApiTypeof thisJavaType, not for possible generics. I.e. it returns also an emptyOptionalin case theJavaTypeitself has noApiTypebut it has generics with anApiType.- Specified by:
getApiTypein interfaceJavaType
-
getAllQualifiedClassNames
Description copied from interface:JavaTypeReturns the qualified classnames used for this type, including the classes of possible type parameters as well as possible api types.- Specified by:
getAllQualifiedClassNamesin interfaceJavaType
-
getParameterizedClassName
Description copied from interface:JavaTypeReturns the parameterized classname of the java type used internally.- Specified by:
getParameterizedClassNamein interfaceJavaType
-
isJavaArray
public boolean isJavaArray()Description copied from interface:JavaTypeReturns true in case this class is a java array (not to be confused with the openapi array-type).- Specified by:
isJavaArrayin interfaceJavaType
-
getNullability
- Specified by:
getNullabilityin interfaceJavaType
-
withNullability
- Specified by:
withNullabilityin interfaceJavaType
-
getConstraints
- Specified by:
getConstraintsin interfaceJavaType
-
getItemType
-
fold
public <T> T fold(Function<JavaArrayType, T> onArrayType, Function<JavaBooleanType, T> onBooleanType, Function<JavaEnumType, T> onEnumType, Function<JavaMapType, T> onMapType, Function<JavaAnyType, T> onAnyType, Function<JavaNumericType, T> onNumericType, Function<JavaIntegerType, T> onIntegerType, Function<JavaObjectType, T> onObjectType, Function<JavaStringType, T> onStringType)
-