@ParametersAreNonnullByDefault @Generated(value="org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutablePreparedQuery extends PreparedQuery
PreparedQuery.
Use the builder to create immutable instances:
ImmutablePreparedQuery.builder().
| Modifier and Type | Class and Description |
|---|---|
static class |
ImmutablePreparedQuery.Builder
Builds instances of type
ImmutablePreparedQuery. |
| Modifier and Type | Method and Description |
|---|---|
static ImmutablePreparedQuery.Builder |
builder()
Creates a builder for
ImmutablePreparedQuery. |
static ImmutablePreparedQuery |
copyOf(PreparedQuery instance)
Creates an immutable copy of a
PreparedQuery value. |
boolean |
equals(Object another)
This instance is equal to all instances of
ImmutablePreparedQuery that have equal attribute values. |
Optional<DnsQuery> |
getDns() |
String |
getName() |
ServiceQuery |
getService() |
Optional<String> |
getSession() |
Optional<Template> |
getTemplate() |
Optional<String> |
getToken() |
int |
hashCode()
Computes a hash code from attributes:
template, name, session, token, service, dns. |
String |
toString()
Prints the immutable value
PreparedQuery with attribute values. |
ImmutablePreparedQuery |
withDns(DnsQuery value)
Copy the current immutable object by setting a present value for the optional
dns attribute. |
ImmutablePreparedQuery |
withDns(Optional<? extends DnsQuery> optional)
Copy the current immutable object by setting an optional value for the
dns attribute. |
ImmutablePreparedQuery |
withName(String value)
Copy the current immutable object by setting a value for the
name attribute. |
ImmutablePreparedQuery |
withService(ServiceQuery value)
Copy the current immutable object by setting a value for the
service attribute. |
ImmutablePreparedQuery |
withSession(Optional<String> optional)
Copy the current immutable object by setting an optional value for the
session attribute. |
ImmutablePreparedQuery |
withSession(String value)
Copy the current immutable object by setting a present value for the optional
session attribute. |
ImmutablePreparedQuery |
withTemplate(Optional<? extends Template> optional)
Copy the current immutable object by setting an optional value for the
template attribute. |
ImmutablePreparedQuery |
withTemplate(Template value)
Copy the current immutable object by setting a present value for the optional
template attribute. |
ImmutablePreparedQuery |
withToken(Optional<String> optional)
Copy the current immutable object by setting an optional value for the
token attribute. |
ImmutablePreparedQuery |
withToken(String value)
Copy the current immutable object by setting a present value for the optional
token attribute. |
public Optional<Template> getTemplate()
getTemplate in class PreparedQuerytemplate attributepublic String getName()
getName in class PreparedQueryname attributepublic Optional<String> getSession()
getSession in class PreparedQuerysession attributepublic Optional<String> getToken()
getToken in class PreparedQuerytoken attributepublic ServiceQuery getService()
getService in class PreparedQueryservice attributepublic Optional<DnsQuery> getDns()
getDns in class PreparedQuerydns attributepublic final ImmutablePreparedQuery withTemplate(Template value)
template attribute.value - The value for templatethis objectpublic final ImmutablePreparedQuery withTemplate(Optional<? extends Template> optional)
template attribute.
A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returning this.optional - A value for templatethis objectpublic final ImmutablePreparedQuery withName(String value)
name attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for namethis objectpublic final ImmutablePreparedQuery withSession(String value)
session attribute.value - The value for sessionthis objectpublic final ImmutablePreparedQuery withSession(Optional<String> optional)
session attribute.
An equality check is used on inner nullable value to prevent copying of the same value by returning this.optional - A value for sessionthis objectpublic final ImmutablePreparedQuery withToken(String value)
token attribute.value - The value for tokenthis objectpublic final ImmutablePreparedQuery withToken(Optional<String> optional)
token attribute.
An equality check is used on inner nullable value to prevent copying of the same value by returning this.optional - A value for tokenthis objectpublic final ImmutablePreparedQuery withService(ServiceQuery value)
service attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for servicethis objectpublic final ImmutablePreparedQuery withDns(DnsQuery value)
dns attribute.value - The value for dnsthis objectpublic final ImmutablePreparedQuery withDns(Optional<? extends DnsQuery> optional)
dns attribute.
A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returning this.optional - A value for dnsthis objectpublic boolean equals(@Nullable Object another)
ImmutablePreparedQuery that have equal attribute values.public int hashCode()
template, name, session, token, service, dns.public String toString()
PreparedQuery with attribute values.public static ImmutablePreparedQuery copyOf(PreparedQuery instance)
PreparedQuery value.
Uses accessors to get values to initialize the new immutable instance.
If an instance is already immutable, it is returned as is.instance - The instance to copypublic static ImmutablePreparedQuery.Builder builder()
ImmutablePreparedQuery.
ImmutablePreparedQuery.builder()
.template(com.orbitz.consul.model.query.Template) // optional template
.name(String) // required name
.session(String) // optional session
.token(String) // optional token
.service(com.orbitz.consul.model.query.ServiceQuery) // required service
.dns(com.orbitz.consul.model.query.DnsQuery) // optional dns
.build();
Copyright © 2019. All rights reserved.