Package dk.mada.jaxrs.model.types
Class ImmutableTypeMap.Builder
java.lang.Object
dk.mada.jaxrs.model.types.ImmutableTypeMap.Builder
- Enclosing class:
ImmutableTypeMap
@Generated(from="TypeMap",
generator="Immutables")
public static final class ImmutableTypeMap.Builder
extends Object
Builds instances of type
ImmutableTypeMap
.
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 TypeMethodDescriptionbuild()
Builds a newImmutableTypeMap
.final ImmutableTypeMap.Builder
from
(TypeContainer instance) Fill a builder with attribute values from the provideddk.mada.jaxrs.model.types.TypeContainer
instance.final ImmutableTypeMap.Builder
Fill a builder with attribute values from the provideddk.mada.jaxrs.model.types.TypeMap
instance.final ImmutableTypeMap.Builder
Initializes the value for theinnerType
attribute.final ImmutableTypeMap.Builder
Initializes the value for thetypeNames
attribute.
-
Method Details
-
from
Fill a builder with attribute values from the provideddk.mada.jaxrs.model.types.TypeContainer
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
from
Fill a builder with attribute values from the provideddk.mada.jaxrs.model.types.TypeMap
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
innerType
Initializes the value for theinnerType
attribute.- Parameters:
innerType
- The value for innerType- Returns:
this
builder for use in a chained invocation
-
typeNames
Initializes the value for thetypeNames
attribute.- Parameters:
typeNames
- The value for typeNames- Returns:
this
builder for use in a chained invocation
-
build
Builds a newImmutableTypeMap
.- Returns:
- An immutable instance of TypeMap
- Throws:
IllegalStateException
- if any required attributes are missing
-