Package io.resys.thena.api.entities
Class ImmutableTenant.Builder
java.lang.Object
io.resys.thena.api.entities.ImmutableTenant.Builder
- Enclosing class:
ImmutableTenant
@Generated(from="Tenant",
generator="Immutables")
public static final class ImmutableTenant.Builder
extends Object
Builds instances of type
ImmutableTenant.
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 newImmutableTenant.final ImmutableTenant.BuilderexternalId(String externalId) Initializes the value for theexternalIdattribute.final ImmutableTenant.BuilderFill a builder with attribute values from the providedTenantinstance.final ImmutableTenant.BuilderInitializes the value for theidattribute.final ImmutableTenant.BuilderInitializes the value for thenameattribute.final ImmutableTenant.BuilderInitializes the value for theprefixattribute.final ImmutableTenant.BuilderInitializes the value for therevattribute.final ImmutableTenant.Buildertype(Tenant.StructureType type) Initializes the value for thetypeattribute.
-
Method Details
-
from
Fill a builder with attribute values from the providedTenantinstance. 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
-
id
Initializes the value for theidattribute.- Parameters:
id- The value for id- Returns:
thisbuilder for use in a chained invocation
-
rev
Initializes the value for therevattribute.- Parameters:
rev- The value for rev- Returns:
thisbuilder for use in a chained invocation
-
prefix
Initializes the value for theprefixattribute.- Parameters:
prefix- The value for prefix- 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
-
externalId
Initializes the value for theexternalIdattribute.- Parameters:
externalId- The value for externalId (can benull)- Returns:
thisbuilder for use in a chained invocation
-
type
Initializes the value for thetypeattribute.- Parameters:
type- The value for type- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newImmutableTenant.- Returns:
- An immutable instance of Tenant
- Throws:
IllegalStateException- if any required attributes are missing
-