Class ImmutableCtxProperty.Builder
java.lang.Object
dk.mada.jaxrs.generator.mpclient.dto.tmpl.ImmutableCtxProperty.Builder
- Enclosing class:
ImmutableCtxProperty
@Generated(from="CtxProperty",
generator="Immutables")
public static final class ImmutableCtxProperty.Builder
extends Object
Builds instances of type
ImmutableCtxProperty.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
-
Method Summary
Modifier and TypeMethodDescriptionallowableValues(@Nullable CtxEnum allowableValues) Initializes the value for theallowableValuesattribute.Initializes the value for thebaseNameattribute.build()Builds a newImmutableCtxProperty.Initializes the value for thedataTypeattribute.datatypeWithEnum(String datatypeWithEnum) Initializes the value for thedatatypeWithEnumattribute.defaultValue(@Nullable String defaultValue) Initializes the value for thedefaultValueattribute.description(String description) Initializes the optional valuedescriptionto description.description(Optional<String> description) Initializes the optional valuedescriptionto description.Initializes the optional valueexampleto example.Initializes the optional valueexampleto example.from(CtxProperty instance) Fill a builder with attribute values from the providedCtxPropertyinstance.Initializes the value for thegetterattribute.isArray(boolean isArray) Initializes the value for theisArrayattribute.isContainer(boolean isContainer) Initializes the value for theisContainerattribute.isDate(boolean isDate) Initializes the value for theisDateattribute.isDateTime(boolean isDateTime) Initializes the value for theisDateTimeattribute.isEnum(boolean isEnum) Initializes the value for theisEnumattribute.isMap(boolean isMap) Initializes the value for theisMapattribute.isSet(boolean isSet) Initializes the value for theisSetattribute.madaProp(CtxPropertyExt madaProp) Initializes the value for themadaPropattribute.Initializes the value for thenameattribute.nameInCamelCase(String nameInCamelCase) Initializes the value for thenameInCamelCaseattribute.nameInSnakeCase(String nameInSnakeCase) Initializes the value for thenameInSnakeCaseattribute.notNull(boolean notNull) Initializes the value for thenotNullattribute.required(boolean required) Initializes the value for therequiredattribute.Initializes the value for thesetterattribute.validation(CtxValidation validation) Initializes the optional valuevalidationto validation.validation(Optional<? extends CtxValidation> validation) Initializes the optional valuevalidationto validation.
-
Method Details
-
from
Fill a builder with attribute values from the providedCtxPropertyinstance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
name
Initializes the value for thenameattribute.- Parameters:
name- The value for name- Returns:
thisbuilder for use in a chained invocation
-
baseName
Initializes the value for thebaseNameattribute.- Parameters:
baseName- The value for baseName- Returns:
thisbuilder for use in a chained invocation
-
nameInCamelCase
Initializes the value for thenameInCamelCaseattribute.- Parameters:
nameInCamelCase- The value for nameInCamelCase- Returns:
thisbuilder for use in a chained invocation
-
nameInSnakeCase
Initializes the value for thenameInSnakeCaseattribute.- Parameters:
nameInSnakeCase- The value for nameInSnakeCase- Returns:
thisbuilder for use in a chained invocation
-
datatypeWithEnum
Initializes the value for thedatatypeWithEnumattribute.- Parameters:
datatypeWithEnum- The value for datatypeWithEnum- Returns:
thisbuilder for use in a chained invocation
-
getter
Initializes the value for thegetterattribute.- Parameters:
getter- The value for getter- Returns:
thisbuilder for use in a chained invocation
-
setter
Initializes the value for thesetterattribute.- Parameters:
setter- The value for setter- Returns:
thisbuilder for use in a chained invocation
-
dataType
Initializes the value for thedataTypeattribute.- Parameters:
dataType- The value for dataType (can benull)- Returns:
thisbuilder for use in a chained invocation
-
allowableValues
Initializes the value for theallowableValuesattribute.- Parameters:
allowableValues- The value for allowableValues (can benull)- Returns:
thisbuilder for use in a chained invocation
-
defaultValue
Initializes the value for thedefaultValueattribute.- Parameters:
defaultValue- The value for defaultValue (can benull)- Returns:
thisbuilder for use in a chained invocation
-
description
Initializes the optional valuedescriptionto description.- Parameters:
description- The value for description- Returns:
thisbuilder for chained invocation
-
description
Initializes the optional valuedescriptionto description.- Parameters:
description- The value for description- Returns:
thisbuilder for use in a chained invocation
-
validation
Initializes the optional valuevalidationto validation.- Parameters:
validation- The value for validation- Returns:
thisbuilder for chained invocation
-
validation
Initializes the optional valuevalidationto validation.- Parameters:
validation- The value for validation- Returns:
thisbuilder for use in a chained invocation
-
isArray
Initializes the value for theisArrayattribute.- Parameters:
isArray- The value for isArray- Returns:
thisbuilder for use in a chained invocation
-
isMap
Initializes the value for theisMapattribute.- Parameters:
isMap- The value for isMap- Returns:
thisbuilder for use in a chained invocation
-
isSet
Initializes the value for theisSetattribute.- Parameters:
isSet- The value for isSet- Returns:
thisbuilder for use in a chained invocation
-
isContainer
Initializes the value for theisContainerattribute.- Parameters:
isContainer- The value for isContainer- Returns:
thisbuilder for use in a chained invocation
-
isDate
Initializes the value for theisDateattribute.- Parameters:
isDate- The value for isDate- Returns:
thisbuilder for use in a chained invocation
-
isDateTime
Initializes the value for theisDateTimeattribute.- Parameters:
isDateTime- The value for isDateTime- Returns:
thisbuilder for use in a chained invocation
-
isEnum
Initializes the value for theisEnumattribute.- Parameters:
isEnum- The value for isEnum- Returns:
thisbuilder for use in a chained invocation
-
required
Initializes the value for therequiredattribute.- Parameters:
required- The value for required- Returns:
thisbuilder for use in a chained invocation
-
notNull
Initializes the value for thenotNullattribute.- Parameters:
notNull- The value for notNull- Returns:
thisbuilder for use in a chained invocation
-
example
Initializes the optional valueexampleto example.- Parameters:
example- The value for example- Returns:
thisbuilder for chained invocation
-
example
Initializes the optional valueexampleto example.- Parameters:
example- The value for example- Returns:
thisbuilder for use in a chained invocation
-
madaProp
Initializes the value for themadaPropattribute.- Parameters:
madaProp- The value for madaProp- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newImmutableCtxProperty.- Returns:
- An immutable instance of CtxProperty
- Throws:
IllegalStateException- if any required attributes are missing
-