@ParametersAreNonnullByDefault @Generated(value="org.immutables.processor.ProxyProcessor") @Immutable public final class ImmutableDsFlag extends Object implements DsFlag
DsFlag.
Use the builder to create immutable instances:
ImmutableDsFlag.builder().
| Modifier and Type | Class and Description |
|---|---|
static class |
ImmutableDsFlag.Builder
Builds instances of type
ImmutableDsFlag. |
| Modifier and Type | Method and Description |
|---|---|
static ImmutableDsFlag.Builder |
builder()
Creates a builder for
ImmutableDsFlag. |
static ImmutableDsFlag |
copyOf(DsFlag instance)
Creates an immutable copy of a
DsFlag value. |
Object |
darkskyUnavailable()
The presence of this property indicates that the Dark Sky data source supports the
given location, but a temporary error (such as a radar station being down for
maintenance) has made the data unavailable.
|
boolean |
equals(Object another)
This instance is equal to all instances of
ImmutableDsFlag that have equal attribute values. |
int |
hashCode()
Computes a hash code from attributes:
darkskyUnavailable, nearestStation, sources, units. |
BigDecimal |
nearestStation()
The distance to the nearest weather station that contributed data to this response.
|
List<String> |
sources()
This property contains a list of IDs for each
data source utilized in
servicing this request.
|
String |
toString()
Prints the immutable value
DsFlag with attribute values. |
DsUnit |
units()
Indicates the units which were used for the data in this request.
|
ImmutableDsFlag |
withDarkskyUnavailable(Object value)
Copy the current immutable object by setting a value for the
darkskyUnavailable attribute. |
ImmutableDsFlag |
withNearestStation(BigDecimal value)
Copy the current immutable object by setting a value for the
nearestStation attribute. |
ImmutableDsFlag |
withSources(Iterable<String> elements)
Copy the current immutable object with elements that replace the content of
sources. |
ImmutableDsFlag |
withSources(String... elements)
Copy the current immutable object with elements that replace the content of
sources. |
ImmutableDsFlag |
withUnits(DsUnit value)
Copy the current immutable object by setting a value for the
units attribute. |
@Nullable public Object darkskyUnavailable()
darkskyUnavailable in interface DsFlag@Nullable public BigDecimal nearestStation()
nearestStation in interface DsFlagpublic List<String> sources()
@Nullable public DsUnit units()
public final ImmutableDsFlag withDarkskyUnavailable(@Nullable Object value)
darkskyUnavailable attribute.
A shallow reference equality check is used to prevent copying of the same value by returning this.value - A new value for darkskyUnavailable (can be null)this objectpublic final ImmutableDsFlag withNearestStation(@Nullable BigDecimal value)
nearestStation attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for nearestStation (can be null)this objectpublic final ImmutableDsFlag withSources(String... elements)
sources.elements - The elements to setthis objectpublic final ImmutableDsFlag withSources(Iterable<String> elements)
sources.
A shallow reference equality check is used to prevent copying of the same value by returning this.elements - An iterable of sources elements to setthis objectpublic final ImmutableDsFlag withUnits(@Nullable DsUnit value)
units attribute.
A value equality check is used to prevent copying of the same value by returning this.value - A new value for units (can be null)this objectpublic boolean equals(@Nullable Object another)
ImmutableDsFlag that have equal attribute values.public int hashCode()
darkskyUnavailable, nearestStation, sources, units.public String toString()
DsFlag with attribute values.public static ImmutableDsFlag copyOf(DsFlag instance)
DsFlag 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 ImmutableDsFlag.Builder builder()
ImmutableDsFlag.
ImmutableDsFlag.builder()
.darkskyUnavailable(Object | null) // nullable darkskyUnavailable
.nearestStation(java.math.BigDecimal | null) // nullable nearestStation
.addSources|addAllSources(String) // sources elements
.units(ch.rasc.darksky.model.DsUnit | null) // nullable units
.build();
Copyright © 2016–2020. All rights reserved.