Class ImmutableCtxPropertyExt
java.lang.Object
dk.mada.jaxrs.generator.mpclient.dto.tmpl.ImmutableCtxPropertyExt
- All Implemented Interfaces:
CtxPropertyExt
@Generated(from="CtxPropertyExt",
generator="Immutables")
@Generated("org.immutables.processor.ProxyProcessor")
public final class ImmutableCtxPropertyExt
extends Object
implements CtxPropertyExt
Immutable implementation of
CtxPropertyExt
.
Use the builder to create immutable instances:
ImmutableCtxPropertyExt.builder()
.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class
Builds instances of typeImmutableCtxPropertyExt
. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
Creates a builder forImmutableCtxPropertyExt
.static ImmutableCtxPropertyExt
copyOf
(CtxPropertyExt instance) Creates an immutable copy of aCtxPropertyExt
value.@Nullable String
Returns the summary as a java string, or null.@Nullable String
Returns the (embedded) enumeration class name.Returns the optional schema options for an inline enumeration type.@Nullable String
Returns the enumeration type name.boolean
This instance is equal to all instances ofImmutableCtxPropertyExt
that have equal attribute values.getter()
Returns the getter name.int
hashCode()
Computes a hash code from attributes:innerDatatypeWithEnum
,enumClassName
,enumTypeName
,enumSchemaOptions
,schemaOptions
,isUseBigDecimalForDouble
,isUseEmptyCollections
,isByteArray
,isEqualsPrimitive
,getter
,setter
,jsonb
,descriptionString
,multipartType
,jsonPropertyConstant
,isNullable
,isRequireNonNull
.@Nullable String
Returns the java inner type, or null.boolean
Returns true if this property is a byte array.boolean
Returns true if this property is primitive and can use == for equals.boolean
Returns true if this property is nullable.boolean
Returns true if this property should guard against nulls with Objects.requireNonNull.boolean
Returns true to use BigDecimal, false to use Double.boolean
Returns true to initialize collections, false to leave as null.boolean
jsonb()
Returns true if rendering for jsonb, false otherwise.@Nullable String
Returns a json property constant value, or null.@Nullable String
Returns the multipart type associated with this property, or null.Returns the optional schema options (for use in @Schema).setter()
Returns the setter name.toString()
Prints the immutable valueCtxPropertyExt
with attribute values.final ImmutableCtxPropertyExt
withDescriptionString
(@Nullable String value) Copy the current immutable object by setting a value for thedescriptionString
attribute.final ImmutableCtxPropertyExt
withEnumClassName
(@Nullable String value) Copy the current immutable object by setting a value for theenumClassName
attribute.final ImmutableCtxPropertyExt
withEnumSchemaOptions
(String value) Copy the current immutable object by setting a present value for the optionalenumSchemaOptions
attribute.final ImmutableCtxPropertyExt
withEnumSchemaOptions
(Optional<String> optional) Copy the current immutable object by setting an optional value for theenumSchemaOptions
attribute.final ImmutableCtxPropertyExt
withEnumTypeName
(@Nullable String value) Copy the current immutable object by setting a value for theenumTypeName
attribute.final ImmutableCtxPropertyExt
withGetter
(String value) Copy the current immutable object by setting a value for thegetter
attribute.final ImmutableCtxPropertyExt
withInnerDatatypeWithEnum
(@Nullable String value) Copy the current immutable object by setting a value for theinnerDatatypeWithEnum
attribute.final ImmutableCtxPropertyExt
withIsByteArray
(boolean value) Copy the current immutable object by setting a value for theisByteArray
attribute.final ImmutableCtxPropertyExt
withIsEqualsPrimitive
(boolean value) Copy the current immutable object by setting a value for theisEqualsPrimitive
attribute.final ImmutableCtxPropertyExt
withIsNullable
(boolean value) Copy the current immutable object by setting a value for theisNullable
attribute.final ImmutableCtxPropertyExt
withIsRequireNonNull
(boolean value) Copy the current immutable object by setting a value for theisRequireNonNull
attribute.final ImmutableCtxPropertyExt
withIsUseBigDecimalForDouble
(boolean value) Copy the current immutable object by setting a value for theisUseBigDecimalForDouble
attribute.final ImmutableCtxPropertyExt
withIsUseEmptyCollections
(boolean value) Copy the current immutable object by setting a value for theisUseEmptyCollections
attribute.final ImmutableCtxPropertyExt
withJsonb
(boolean value) Copy the current immutable object by setting a value for thejsonb
attribute.final ImmutableCtxPropertyExt
withJsonPropertyConstant
(@Nullable String value) Copy the current immutable object by setting a value for thejsonPropertyConstant
attribute.final ImmutableCtxPropertyExt
withMultipartType
(@Nullable String value) Copy the current immutable object by setting a value for themultipartType
attribute.final ImmutableCtxPropertyExt
withSchemaOptions
(String value) Copy the current immutable object by setting a present value for the optionalschemaOptions
attribute.final ImmutableCtxPropertyExt
withSchemaOptions
(Optional<String> optional) Copy the current immutable object by setting an optional value for theschemaOptions
attribute.final ImmutableCtxPropertyExt
withSetter
(String value) Copy the current immutable object by setting a value for thesetter
attribute.
-
Method Details
-
innerDatatypeWithEnum
Returns the java inner type, or null.- Specified by:
innerDatatypeWithEnum
in interfaceCtxPropertyExt
- Returns:
- the java inner type, or null
-
enumClassName
Returns the (embedded) enumeration class name. Used in enumerations that are rendered next to the (only) property where they are referenced. See enumClass.mustache. This is handled separately from the standard dataType/datatypeWithEnum values because they are both used separately by both containers and enumerations. Which prevents handling of enumerations in containers (or rather, I broke the templates somehow to match behavior from openapi-generator - and this is easier to read for me).- Specified by:
enumClassName
in interfaceCtxPropertyExt
- Returns:
- the enumeration class name
-
enumTypeName
Returns the enumeration type name.- Specified by:
enumTypeName
in interfaceCtxPropertyExt
- Returns:
- the enumeration type name
-
enumSchemaOptions
Returns the optional schema options for an inline enumeration type.- Specified by:
enumSchemaOptions
in interfaceCtxPropertyExt
- Returns:
- the optional schema options for an inline enumeration type
-
schemaOptions
Returns the optional schema options (for use in @Schema).- Specified by:
schemaOptions
in interfaceCtxPropertyExt
- Returns:
- the optional schema options (for use in @Schema)
-
isUseBigDecimalForDouble
public boolean isUseBigDecimalForDouble()Returns true to use BigDecimal, false to use Double.- Specified by:
isUseBigDecimalForDouble
in interfaceCtxPropertyExt
- Returns:
- true to use BigDecimal, false to use Double
-
isUseEmptyCollections
public boolean isUseEmptyCollections()Returns true to initialize collections, false to leave as null.- Specified by:
isUseEmptyCollections
in interfaceCtxPropertyExt
- Returns:
- true to initialize collections, false to leave as null
-
isByteArray
public boolean isByteArray()Returns true if this property is a byte array.- Specified by:
isByteArray
in interfaceCtxPropertyExt
- Returns:
- true if this property is a byte array
-
isEqualsPrimitive
public boolean isEqualsPrimitive()Returns true if this property is primitive and can use == for equals.- Specified by:
isEqualsPrimitive
in interfaceCtxPropertyExt
- Returns:
- true if this property is primitive and can use == for equals
-
getter
Returns the getter name.- Specified by:
getter
in interfaceCtxPropertyExt
- Returns:
- the getter name
-
setter
Returns the setter name.- Specified by:
setter
in interfaceCtxPropertyExt
- Returns:
- the setter name
-
jsonb
public boolean jsonb()Returns true if rendering for jsonb, false otherwise.- Specified by:
jsonb
in interfaceCtxPropertyExt
- Returns:
- true if rendering for jsonb, false otherwise
-
descriptionString
Returns the summary as a java string, or null.- Specified by:
descriptionString
in interfaceCtxPropertyExt
- Returns:
- the summary as a java string, or null
-
multipartType
Returns the multipart type associated with this property, or null.- Specified by:
multipartType
in interfaceCtxPropertyExt
- Returns:
- the multipart type associated with this property, or null
-
jsonPropertyConstant
Returns a json property constant value, or null.- Specified by:
jsonPropertyConstant
in interfaceCtxPropertyExt
- Returns:
- a json property constant value, or null
-
isNullable
public boolean isNullable()Returns true if this property is nullable.- Specified by:
isNullable
in interfaceCtxPropertyExt
- Returns:
- true if this property is nullable
-
isRequireNonNull
public boolean isRequireNonNull()Returns true if this property should guard against nulls with Objects.requireNonNull.- Specified by:
isRequireNonNull
in interfaceCtxPropertyExt
- Returns:
- true if this property should guard against nulls with Objects.requireNonNull
-
withInnerDatatypeWithEnum
Copy the current immutable object by setting a value for theinnerDatatypeWithEnum
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for innerDatatypeWithEnum (can benull
)- Returns:
- A modified copy or the
this
object
-
withEnumClassName
Copy the current immutable object by setting a value for theenumClassName
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for enumClassName (can benull
)- Returns:
- A modified copy or the
this
object
-
withEnumTypeName
Copy the current immutable object by setting a value for theenumTypeName
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for enumTypeName (can benull
)- Returns:
- A modified copy or the
this
object
-
withEnumSchemaOptions
Copy the current immutable object by setting a present value for the optionalenumSchemaOptions
attribute.- Parameters:
value
- The value for enumSchemaOptions- Returns:
- A modified copy or
this
if not changed
-
withEnumSchemaOptions
Copy the current immutable object by setting an optional value for theenumSchemaOptions
attribute. An equality check is used on inner value to prevent copying of the same value by returningthis
.- Parameters:
optional
- An optional value for enumSchemaOptions- Returns:
- A modified copy or
this
if not changed
-
withSchemaOptions
Copy the current immutable object by setting a present value for the optionalschemaOptions
attribute.- Parameters:
value
- The value for schemaOptions- Returns:
- A modified copy or
this
if not changed
-
withSchemaOptions
Copy the current immutable object by setting an optional value for theschemaOptions
attribute. An equality check is used on inner value to prevent copying of the same value by returningthis
.- Parameters:
optional
- An optional value for schemaOptions- Returns:
- A modified copy or
this
if not changed
-
withIsUseBigDecimalForDouble
Copy the current immutable object by setting a value for theisUseBigDecimalForDouble
attribute. A value equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for isUseBigDecimalForDouble- Returns:
- A modified copy or the
this
object
-
withIsUseEmptyCollections
Copy the current immutable object by setting a value for theisUseEmptyCollections
attribute. A value equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for isUseEmptyCollections- Returns:
- A modified copy or the
this
object
-
withIsByteArray
Copy the current immutable object by setting a value for theisByteArray
attribute. A value equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for isByteArray- Returns:
- A modified copy or the
this
object
-
withIsEqualsPrimitive
Copy the current immutable object by setting a value for theisEqualsPrimitive
attribute. A value equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for isEqualsPrimitive- Returns:
- A modified copy or the
this
object
-
withGetter
Copy the current immutable object by setting a value for thegetter
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for getter- Returns:
- A modified copy or the
this
object
-
withSetter
Copy the current immutable object by setting a value for thesetter
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for setter- Returns:
- A modified copy or the
this
object
-
withJsonb
Copy the current immutable object by setting a value for thejsonb
attribute. A value equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for jsonb- Returns:
- A modified copy or the
this
object
-
withDescriptionString
Copy the current immutable object by setting a value for thedescriptionString
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for descriptionString (can benull
)- Returns:
- A modified copy or the
this
object
-
withMultipartType
Copy the current immutable object by setting a value for themultipartType
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for multipartType (can benull
)- Returns:
- A modified copy or the
this
object
-
withJsonPropertyConstant
Copy the current immutable object by setting a value for thejsonPropertyConstant
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for jsonPropertyConstant (can benull
)- Returns:
- A modified copy or the
this
object
-
withIsNullable
Copy the current immutable object by setting a value for theisNullable
attribute. A value equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for isNullable- Returns:
- A modified copy or the
this
object
-
withIsRequireNonNull
Copy the current immutable object by setting a value for theisRequireNonNull
attribute. A value equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for isRequireNonNull- Returns:
- A modified copy or the
this
object
-
equals
This instance is equal to all instances ofImmutableCtxPropertyExt
that have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:innerDatatypeWithEnum
,enumClassName
,enumTypeName
,enumSchemaOptions
,schemaOptions
,isUseBigDecimalForDouble
,isUseEmptyCollections
,isByteArray
,isEqualsPrimitive
,getter
,setter
,jsonb
,descriptionString
,multipartType
,jsonPropertyConstant
,isNullable
,isRequireNonNull
. -
toString
Prints the immutable valueCtxPropertyExt
with attribute values. -
copyOf
Creates an immutable copy of aCtxPropertyExt
value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance
- The instance to copy- Returns:
- A copied immutable CtxPropertyExt instance
-
builder
Creates a builder forImmutableCtxPropertyExt
.ImmutableCtxPropertyExt.builder() .innerDatatypeWithEnum(String | null) // nullable
innerDatatypeWithEnum
.enumClassName(String | null) // nullableenumClassName
.enumTypeName(String | null) // nullableenumTypeName
.enumSchemaOptions(Optional<String>) // optionalenumSchemaOptions
.schemaOptions(Optional<String>) // optionalschemaOptions
.isUseBigDecimalForDouble(boolean) // requiredisUseBigDecimalForDouble
.isUseEmptyCollections(boolean) // requiredisUseEmptyCollections
.isByteArray(boolean) // requiredisByteArray
.isEqualsPrimitive(boolean) // requiredisEqualsPrimitive
.getter(String) // requiredgetter
.setter(String) // requiredsetter
.jsonb(boolean) // requiredjsonb
.descriptionString(String | null) // nullabledescriptionString
.multipartType(String | null) // nullablemultipartType
.jsonPropertyConstant(String | null) // nullablejsonPropertyConstant
.isNullable(boolean) // requiredisNullable
.isRequireNonNull(boolean) // requiredisRequireNonNull
.build();- Returns:
- A new ImmutableCtxPropertyExt builder
-