Package org.openapitools.codegen
Interface IJsonSchemaValidationProperties
-
- All Known Implementing Classes:
CodegenModel
,CodegenParameter
,CodegenProperty
,CodegenResponse
public interface IJsonSchemaValidationProperties
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description CodegenProperty
getAdditionalProperties()
boolean
getAdditionalPropertiesIsAnyType()
default String
getBaseType()
default String
getComplexType()
CodegenComposedSchemas
getComposedSchemas()
CodegenProperty
getContains()
LinkedHashMap<String,List<String>>
getDependentRequired()
boolean
getExclusiveMaximum()
boolean
getExclusiveMinimum()
String
getFormat()
boolean
getHasDiscriminatorWithNonEmptyMapping()
boolean
getHasMultipleTypes()
boolean
getHasRequired()
boolean
getHasValidation()
boolean
getHasVars()
default Set<String>
getImports(boolean importContainerType, boolean importBaseType, FeatureSet featureSet)
Recursively collect all necessary imports to include so that the type may be resolved.boolean
getIsAnyType()
boolean
getIsArray()
boolean
getIsBoolean()
boolean
getIsBooleanSchemaFalse()
boolean
getIsBooleanSchemaTrue()
boolean
getIsDate()
boolean
getIsDateTime()
boolean
getIsMap()
boolean
getIsModel()
boolean
getIsNull()
boolean
getIsNumber()
boolean
getIsPrimitiveType()
boolean
getIsShort()
boolean
getIsString()
boolean
getIsUnboundedInteger()
boolean
getIsVoid()
CodegenProperty
getItems()
String
getMaximum()
Integer
getMaxItems()
Integer
getMaxLength()
Integer
getMaxProperties()
String
getMinimum()
Integer
getMinItems()
Integer
getMinLength()
Integer
getMinProperties()
Number
getMultipleOf()
String
getPattern()
String
getRef()
List<CodegenProperty>
getRequiredVars()
Map<String,CodegenProperty>
getRequiredVarsMap()
boolean
getSchemaIsFromAdditionalProperties()
boolean
getUniqueItems()
Boolean
getUniqueItemsBoolean()
List<CodegenProperty>
getVars()
void
setAdditionalProperties(CodegenProperty additionalProperties)
void
setAdditionalPropertiesIsAnyType(boolean additionalPropertiesIsAnyType)
void
setComposedSchemas(CodegenComposedSchemas composedSchemas)
void
setContains(CodegenProperty contains)
void
setDependentRequired(LinkedHashMap<String,List<String>> dependentRequired)
void
setExclusiveMaximum(boolean exclusiveMaximum)
void
setExclusiveMinimum(boolean exclusiveMinimum)
void
setFormat(String format)
void
setHasDiscriminatorWithNonEmptyMapping(boolean hasDiscriminatorWithNonEmptyMapping)
void
setHasMultipleTypes(boolean hasMultipleTypes)
void
setHasRequired(boolean hasRequired)
void
setHasValidation(boolean hasValidation)
void
setHasVars(boolean hasVars)
void
setIsAnyType(boolean isAnyType)
void
setIsArray(boolean isShort)
void
setIsBoolean(boolean isBoolean)
void
setIsBooleanSchemaFalse(boolean isBooleanSchemaFalse)
void
setIsBooleanSchemaTrue(boolean isBooleanSchemaTrue)
void
setIsDate(boolean isDate)
void
setIsDateTime(boolean isDateTime)
void
setIsMap(boolean isMap)
void
setIsModel(boolean isModel)
void
setIsNull(boolean isNull)
void
setIsNumber(boolean isNumber)
void
setIsPrimitiveType(boolean isPrimitiveType)
void
setIsShort(boolean isShort)
void
setIsString(boolean isNumber)
void
setIsUnboundedInteger(boolean isUnboundedInteger)
void
setIsVoid(boolean isVoid)
void
setItems(CodegenProperty items)
void
setMaximum(String maximum)
void
setMaxItems(Integer maxItems)
void
setMaxLength(Integer maxLength)
void
setMaxProperties(Integer maxProperties)
void
setMinimum(String minimum)
void
setMinItems(Integer minItems)
void
setMinLength(Integer minLength)
void
setMinProperties(Integer minProperties)
void
setMultipleOf(Number multipleOf)
void
setPattern(String pattern)
void
setRef(String ref)
void
setRequiredVars(List<CodegenProperty> requiredVars)
void
setRequiredVarsMap(Map<String,CodegenProperty> requiredVarsMap)
void
setSchemaIsFromAdditionalProperties(boolean schemaIsFromAdditionalProperties)
default void
setTypeProperties(io.swagger.v3.oas.models.media.Schema p)
Syncs all the schema's type properties into the IJsonSchemaValidationProperties instance for now this only supports types without format information TODO: in the future move the format handling in here toovoid
setUniqueItems(boolean uniqueItems)
void
setUniqueItemsBoolean(Boolean uniqueItems)
void
setVars(List<CodegenProperty> vars)
-
-
-
Method Detail
-
getContains
CodegenProperty getContains()
-
setContains
void setContains(CodegenProperty contains)
-
getDependentRequired
LinkedHashMap<String,List<String>> getDependentRequired()
-
setDependentRequired
void setDependentRequired(LinkedHashMap<String,List<String>> dependentRequired)
-
getPattern
String getPattern()
-
setPattern
void setPattern(String pattern)
-
getMaximum
String getMaximum()
-
setMaximum
void setMaximum(String maximum)
-
getMinimum
String getMinimum()
-
setMinimum
void setMinimum(String minimum)
-
getExclusiveMaximum
boolean getExclusiveMaximum()
-
setExclusiveMaximum
void setExclusiveMaximum(boolean exclusiveMaximum)
-
getExclusiveMinimum
boolean getExclusiveMinimum()
-
setExclusiveMinimum
void setExclusiveMinimum(boolean exclusiveMinimum)
-
getMinLength
Integer getMinLength()
-
setMinLength
void setMinLength(Integer minLength)
-
getMaxLength
Integer getMaxLength()
-
setMaxLength
void setMaxLength(Integer maxLength)
-
getMinItems
Integer getMinItems()
-
setMinItems
void setMinItems(Integer minItems)
-
getMaxItems
Integer getMaxItems()
-
setMaxItems
void setMaxItems(Integer maxItems)
-
getUniqueItems
boolean getUniqueItems()
-
setUniqueItems
void setUniqueItems(boolean uniqueItems)
-
getUniqueItemsBoolean
Boolean getUniqueItemsBoolean()
-
setUniqueItemsBoolean
void setUniqueItemsBoolean(Boolean uniqueItems)
-
getMinProperties
Integer getMinProperties()
-
setMinProperties
void setMinProperties(Integer minProperties)
-
getMaxProperties
Integer getMaxProperties()
-
setMaxProperties
void setMaxProperties(Integer maxProperties)
-
getMultipleOf
Number getMultipleOf()
-
setMultipleOf
void setMultipleOf(Number multipleOf)
-
getItems
CodegenProperty getItems()
-
setItems
void setItems(CodegenProperty items)
-
getIsModel
boolean getIsModel()
-
setIsModel
void setIsModel(boolean isModel)
-
getIsDate
boolean getIsDate()
-
setIsDate
void setIsDate(boolean isDate)
-
getIsDateTime
boolean getIsDateTime()
-
setIsDateTime
void setIsDateTime(boolean isDateTime)
-
getIsMap
boolean getIsMap()
-
setIsMap
void setIsMap(boolean isMap)
-
getIsArray
boolean getIsArray()
-
setIsArray
void setIsArray(boolean isShort)
-
getIsShort
boolean getIsShort()
-
setIsShort
void setIsShort(boolean isShort)
-
getIsBoolean
boolean getIsBoolean()
-
setIsBoolean
void setIsBoolean(boolean isBoolean)
-
getIsUnboundedInteger
boolean getIsUnboundedInteger()
-
setIsUnboundedInteger
void setIsUnboundedInteger(boolean isUnboundedInteger)
-
getIsPrimitiveType
boolean getIsPrimitiveType()
-
setIsPrimitiveType
void setIsPrimitiveType(boolean isPrimitiveType)
-
getAdditionalProperties
CodegenProperty getAdditionalProperties()
-
setAdditionalProperties
void setAdditionalProperties(CodegenProperty additionalProperties)
-
getVars
List<CodegenProperty> getVars()
-
setVars
void setVars(List<CodegenProperty> vars)
-
getRequiredVars
List<CodegenProperty> getRequiredVars()
-
setRequiredVars
void setRequiredVars(List<CodegenProperty> requiredVars)
-
getRequiredVarsMap
Map<String,CodegenProperty> getRequiredVarsMap()
-
setRequiredVarsMap
void setRequiredVarsMap(Map<String,CodegenProperty> requiredVarsMap)
-
getIsNull
boolean getIsNull()
-
setIsNull
void setIsNull(boolean isNull)
-
getIsVoid
boolean getIsVoid()
-
setIsVoid
void setIsVoid(boolean isVoid)
-
getHasValidation
boolean getHasValidation()
-
setHasValidation
void setHasValidation(boolean hasValidation)
-
getAdditionalPropertiesIsAnyType
boolean getAdditionalPropertiesIsAnyType()
-
setAdditionalPropertiesIsAnyType
void setAdditionalPropertiesIsAnyType(boolean additionalPropertiesIsAnyType)
-
getHasVars
boolean getHasVars()
-
setHasVars
void setHasVars(boolean hasVars)
-
getHasRequired
boolean getHasRequired()
-
setHasRequired
void setHasRequired(boolean hasRequired)
-
getHasDiscriminatorWithNonEmptyMapping
boolean getHasDiscriminatorWithNonEmptyMapping()
-
setHasDiscriminatorWithNonEmptyMapping
void setHasDiscriminatorWithNonEmptyMapping(boolean hasDiscriminatorWithNonEmptyMapping)
-
getIsString
boolean getIsString()
-
setIsString
void setIsString(boolean isNumber)
-
getIsNumber
boolean getIsNumber()
-
setIsNumber
void setIsNumber(boolean isNumber)
-
getIsAnyType
boolean getIsAnyType()
-
setIsAnyType
void setIsAnyType(boolean isAnyType)
-
getRef
String getRef()
-
setRef
void setRef(String ref)
-
getComposedSchemas
CodegenComposedSchemas getComposedSchemas()
-
setComposedSchemas
void setComposedSchemas(CodegenComposedSchemas composedSchemas)
-
getHasMultipleTypes
boolean getHasMultipleTypes()
-
setHasMultipleTypes
void setHasMultipleTypes(boolean hasMultipleTypes)
-
getIsBooleanSchemaTrue
boolean getIsBooleanSchemaTrue()
-
setIsBooleanSchemaTrue
void setIsBooleanSchemaTrue(boolean isBooleanSchemaTrue)
-
getIsBooleanSchemaFalse
boolean getIsBooleanSchemaFalse()
-
setIsBooleanSchemaFalse
void setIsBooleanSchemaFalse(boolean isBooleanSchemaFalse)
-
getSchemaIsFromAdditionalProperties
boolean getSchemaIsFromAdditionalProperties()
-
setSchemaIsFromAdditionalProperties
void setSchemaIsFromAdditionalProperties(boolean schemaIsFromAdditionalProperties)
-
setFormat
void setFormat(String format)
-
getFormat
String getFormat()
-
setTypeProperties
default void setTypeProperties(io.swagger.v3.oas.models.media.Schema p)
Syncs all the schema's type properties into the IJsonSchemaValidationProperties instance for now this only supports types without format information TODO: in the future move the format handling in here too- Parameters:
p
- the schema which contains the type info
-
getBaseType
default String getBaseType()
- Returns:
- basic type - no generics supported.
-
getComplexType
default String getComplexType()
- Returns:
- complex type that can contain type parameters - like
List<Items>
for Java
-
getImports
default Set<String> getImports(boolean importContainerType, boolean importBaseType, FeatureSet featureSet)
Recursively collect all necessary imports to include so that the type may be resolved.- Parameters:
importContainerType
- whether or not to include the container types in the returned imports.importBaseType
- whether or not to include the base types in the returned imports.featureSet
- the generator feature set, used to determine if composed schemas should be added- Returns:
- all of the imports
-
-