Package dk.mada.jaxrs.model.types
Class ImmutableTypeEnum.Builder
java.lang.Object
dk.mada.jaxrs.model.types.ImmutableTypeEnum.Builder
- Enclosing class:
ImmutableTypeEnum
@Generated(from="TypeEnum",
generator="Immutables")
public static final class ImmutableTypeEnum.Builder
extends Object
Builds instances of type
ImmutableTypeEnum.
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 TypeMethodDescriptionaddAllValues(Iterable<String> elements) Adds elements tovalueslist.Adds one element tovalueslist.Adds elements tovalueslist.build()Builds a newImmutableTypeEnum.Fill a builder with attribute values from the provideddk.mada.jaxrs.model.types.Typeinstance.Fill a builder with attribute values from the provideddk.mada.jaxrs.model.types.TypeEnuminstance.Initializes the value for theinnerTypeattribute.Initializes the value for thetypeNameattribute.Sets or replaces all elements forvalueslist.
-
Method Details
-
from
Fill a builder with attribute values from the provideddk.mada.jaxrs.model.types.TypeEnuminstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
from
Fill a builder with attribute values from the provideddk.mada.jaxrs.model.types.Typeinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
typeName
Initializes the value for thetypeNameattribute.- Parameters:
typeName- The value for typeName- Returns:
thisbuilder for use in a chained invocation
-
innerType
Initializes the value for theinnerTypeattribute.- Parameters:
innerType- The value for innerType- Returns:
thisbuilder for use in a chained invocation
-
addValues
Adds one element tovalueslist.- Parameters:
element- A values element- Returns:
thisbuilder for use in a chained invocation
-
addValues
Adds elements tovalueslist.- Parameters:
elements- An array of values elements- Returns:
thisbuilder for use in a chained invocation
-
values
Sets or replaces all elements forvalueslist.- Parameters:
elements- An iterable of values elements- Returns:
thisbuilder for use in a chained invocation
-
addAllValues
Adds elements tovalueslist.- Parameters:
elements- An iterable of values elements- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newImmutableTypeEnum.- Returns:
- An immutable instance of TypeEnum
- Throws:
IllegalStateException- if any required attributes are missing
-