Package io.resys.thena.api.envelope
Class ImmutableQueryEnvelopePage.Builder<T extends ThenaContainer>
java.lang.Object
io.resys.thena.api.envelope.ImmutableQueryEnvelopePage.Builder<T>
- Enclosing class:
ImmutableQueryEnvelopePage<T extends ThenaContainer>
@Generated(from="QueryEnvelopePage",
generator="Immutables")
public static final class ImmutableQueryEnvelopePage.Builder<T extends ThenaContainer>
extends Object
Builds instances of type
ImmutableQueryEnvelopePage.
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 TypeMethodDescriptionaddAllCurrentPageObjects(Iterable<? extends T> elements) Adds elements tocurrentPageObjectslist.addAllMessages(Iterable<? extends Message> elements) Adds elements tomessageslist.addCurrentPageObjects(T element) Adds one element tocurrentPageObjectslist.addCurrentPageObjects(T... elements) Adds elements tocurrentPageObjectslist.addMessages(Message element) Adds one element tomessageslist.addMessages(Message... elements) Adds elements tomessageslist.build()Builds a newImmutableQueryEnvelopePage.currentPageNumber(Integer currentPageNumber) Initializes the value for thecurrentPageNumberattribute.currentPageObjects(Iterable<? extends T> elements) Sets or replaces all elements forcurrentPageObjectslist.from(QueryEnvelopePage<T> instance) Fill a builder with attribute values from the providedQueryEnvelopePageinstance.Sets or replaces all elements formessageslist.Initializes the value for therepoattribute.Initializes the value for thestatusattribute.totalObjectsOnPages(Long totalObjectsOnPages) Initializes the value for thetotalObjectsOnPagesattribute.totalPages(Integer totalPages) Initializes the value for thetotalPagesattribute.
-
Method Details
-
from
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> from(QueryEnvelopePage<T> instance) Fill a builder with attribute values from the providedQueryEnvelopePageinstance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values. Collection elements and entries will be added, not replaced.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
repo
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> repo(@Nullable Tenant repo) Initializes the value for therepoattribute.- Parameters:
repo- The value for repo (can benull)- Returns:
thisbuilder for use in a chained invocation
-
addCurrentPageObjects
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> addCurrentPageObjects(T element) Adds one element tocurrentPageObjectslist.- Parameters:
element- A currentPageObjects element- Returns:
thisbuilder for use in a chained invocation
-
addCurrentPageObjects
@CanIgnoreReturnValue @SafeVarargs public final ImmutableQueryEnvelopePage.Builder<T> addCurrentPageObjects(T... elements) Adds elements tocurrentPageObjectslist.- Parameters:
elements- An array of currentPageObjects elements- Returns:
thisbuilder for use in a chained invocation
-
currentPageObjects
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> currentPageObjects(@Nullable Iterable<? extends T> elements) Sets or replaces all elements forcurrentPageObjectslist.- Parameters:
elements- An iterable of currentPageObjects elements- Returns:
thisbuilder for use in a chained invocation
-
addAllCurrentPageObjects
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> addAllCurrentPageObjects(Iterable<? extends T> elements) Adds elements tocurrentPageObjectslist.- Parameters:
elements- An iterable of currentPageObjects elements- Returns:
thisbuilder for use in a chained invocation
-
currentPageNumber
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> currentPageNumber(@Nullable Integer currentPageNumber) Initializes the value for thecurrentPageNumberattribute.- Parameters:
currentPageNumber- The value for currentPageNumber (can benull)- Returns:
thisbuilder for use in a chained invocation
-
totalPages
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> totalPages(@Nullable Integer totalPages) Initializes the value for thetotalPagesattribute.- Parameters:
totalPages- The value for totalPages (can benull)- Returns:
thisbuilder for use in a chained invocation
-
totalObjectsOnPages
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> totalObjectsOnPages(@Nullable Long totalObjectsOnPages) Initializes the value for thetotalObjectsOnPagesattribute.- Parameters:
totalObjectsOnPages- The value for totalObjectsOnPages (can benull)- Returns:
thisbuilder for use in a chained invocation
-
status
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> status(QueryEnvelope.QueryEnvelopeStatus status) Initializes the value for thestatusattribute.- Parameters:
status- The value for status- Returns:
thisbuilder for use in a chained invocation
-
addMessages
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> addMessages(Message element) Adds one element tomessageslist.- Parameters:
element- A messages element- Returns:
thisbuilder for use in a chained invocation
-
addMessages
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> addMessages(Message... elements) Adds elements tomessageslist.- Parameters:
elements- An array of messages elements- Returns:
thisbuilder for use in a chained invocation
-
messages
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> messages(Iterable<? extends Message> elements) Sets or replaces all elements formessageslist.- Parameters:
elements- An iterable of messages elements- Returns:
thisbuilder for use in a chained invocation
-
addAllMessages
@CanIgnoreReturnValue public final ImmutableQueryEnvelopePage.Builder<T> addAllMessages(Iterable<? extends Message> elements) Adds elements tomessageslist.- Parameters:
elements- An iterable of messages elements- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newImmutableQueryEnvelopePage.- Returns:
- An immutable instance of QueryEnvelopePage
- Throws:
IllegalStateException- if any required attributes are missing
-