@NotThreadSafe public static final class ImmutableStoredQuery.Builder extends Object
ImmutableStoredQuery.
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.
| Modifier and Type | Method and Description |
|---|---|
ImmutableStoredQuery |
build()
Builds a new
ImmutableStoredQuery. |
ImmutableStoredQuery.Builder |
dns(DnsQuery dns)
Initializes the value for the
dns attribute. |
ImmutableStoredQuery.Builder |
from(StoredQuery instance)
Fill a builder with attribute values from the provided
StoredQuery instance. |
ImmutableStoredQuery.Builder |
id(String id)
Initializes the value for the
id attribute. |
ImmutableStoredQuery.Builder |
name(String name)
Initializes the value for the
name attribute. |
ImmutableStoredQuery.Builder |
service(ServiceQuery service)
Initializes the value for the
service attribute. |
ImmutableStoredQuery.Builder |
session(String session)
Initializes the value for the
session attribute. |
ImmutableStoredQuery.Builder |
token(String token)
Initializes the value for the
token attribute. |
@CanIgnoreReturnValue public final ImmutableStoredQuery.Builder from(StoredQuery instance)
StoredQuery instance.
Regular attribute values will be replaced with those from the given instance.
Absent optional values will not replace present values.instance - The instance from which to copy valuesthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableStoredQuery.Builder id(String id)
id attribute.id - The value for idthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableStoredQuery.Builder name(String name)
name attribute.name - The value for namethis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableStoredQuery.Builder session(String session)
session attribute.session - The value for sessionthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableStoredQuery.Builder token(String token)
token attribute.token - The value for tokenthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableStoredQuery.Builder service(ServiceQuery service)
service attribute.service - The value for servicethis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableStoredQuery.Builder dns(DnsQuery dns)
dns attribute.dns - The value for dnsthis builder for use in a chained invocationpublic ImmutableStoredQuery build()
ImmutableStoredQuery.IllegalStateException - if any required attributes are missingCopyright © 2019. All rights reserved.