Class ImmutableLabelTemplateBean.Builder
java.lang.Object
com.riadalabs.jira.plugins.insight.services.model.ImmutableLabelTemplateBean.Builder
- Enclosing class:
- ImmutableLabelTemplateBean
Builds instances of type
ImmutableLabelTemplateBean
.
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 newImmutableLabelTemplateBean
.from
(LabelTemplateBean instance) Fill a builder with attribute values from the providedLabelTemplateBean
instance.setCreated
(Date created) Initializes the value for thecreated
attribute.setDescription
(String description) Initializes the value for thedescription
attribute.setDynamicHeight
(Boolean dynamicHeight) Initializes the value for thedynamicHeight
attribute.Initializes the value for theheight
attribute.Initializes the value for theid
attribute.setIncludeBorder
(Boolean includeBorder) Initializes the value for theincludeBorder
attribute.Initializes the value for thename
attribute.setObjectSchemaId
(Integer objectSchemaId) Initializes the value for theobjectSchemaId
attribute.setTemplate
(String template) Initializes the value for thetemplate
attribute.setUpdated
(Date updated) Initializes the value for theupdated
attribute.Initializes the value for thewidth
attribute.
-
Method Details
-
from
@CanIgnoreReturnValue public final ImmutableLabelTemplateBean.Builder from(LabelTemplateBean instance) Fill a builder with attribute values from the providedLabelTemplateBean
instance. 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:
this
builder for use in a chained invocation
-
setId
Initializes the value for theid
attribute.- Parameters:
id
- The value for id (can benull
)- Returns:
this
builder for use in a chained invocation
-
setDescription
@CanIgnoreReturnValue public final ImmutableLabelTemplateBean.Builder setDescription(@Nullable String description) Initializes the value for thedescription
attribute.- Parameters:
description
- The value for description (can benull
)- Returns:
this
builder for use in a chained invocation
-
setName
Initializes the value for thename
attribute.- Parameters:
name
- The value for name- Returns:
this
builder for use in a chained invocation
-
setTemplate
Initializes the value for thetemplate
attribute.- Parameters:
template
- The value for template- Returns:
this
builder for use in a chained invocation
-
setObjectSchemaId
@CanIgnoreReturnValue public final ImmutableLabelTemplateBean.Builder setObjectSchemaId(@Nullable Integer objectSchemaId) Initializes the value for theobjectSchemaId
attribute.- Parameters:
objectSchemaId
- The value for objectSchemaId (can benull
)- Returns:
this
builder for use in a chained invocation
-
setHeight
Initializes the value for theheight
attribute.- Parameters:
height
- The value for height- Returns:
this
builder for use in a chained invocation
-
setWidth
Initializes the value for thewidth
attribute.- Parameters:
width
- The value for width- Returns:
this
builder for use in a chained invocation
-
setDynamicHeight
@CanIgnoreReturnValue public final ImmutableLabelTemplateBean.Builder setDynamicHeight(Boolean dynamicHeight) Initializes the value for thedynamicHeight
attribute.- Parameters:
dynamicHeight
- The value for dynamicHeight- Returns:
this
builder for use in a chained invocation
-
setCreated
Initializes the value for thecreated
attribute.- Parameters:
created
- The value for created- Returns:
this
builder for use in a chained invocation
-
setUpdated
Initializes the value for theupdated
attribute.- Parameters:
updated
- The value for updated- Returns:
this
builder for use in a chained invocation
-
setIncludeBorder
@CanIgnoreReturnValue public final ImmutableLabelTemplateBean.Builder setIncludeBorder(Boolean includeBorder) Initializes the value for theincludeBorder
attribute.- Parameters:
includeBorder
- The value for includeBorder- Returns:
this
builder for use in a chained invocation
-
build
Builds a newImmutableLabelTemplateBean
.- Returns:
- An immutable instance of LabelTemplateBean
- Throws:
IllegalStateException
- if any required attributes are missing
-