Package org.n52.io.response
Class ParameterOutput
java.lang.Object
org.n52.io.response.SelfSerializedOutput
org.n52.io.response.ParameterOutput
- All Implemented Interfaces:
Comparable<ParameterOutput>,RawFormats
- Direct Known Subclasses:
AbstractOutput,DetectionLimitOutput,ProducerOutput,SamplerOutput,ServiceOutput
public abstract class ParameterOutput
extends SelfSerializedOutput
implements RawFormats, Comparable<ParameterOutput>
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final StringFields inherited from interface org.n52.series.spi.srv.RawFormats
RAW_FORMAT -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintstatic <T extends ParameterOutput>
Comparator<T>Takes the default comparator to compare.booleanReturns the domain id of the parameter, e.g.getHref()getId()getLabel()Deprecated.inthashCode()static <T extends ParameterOutput>
Comparator<T>Takes the ids to compare.static <T extends ParameterOutput>
Comparator<T>Takes the labels to compare.setDomainId(OptionalOutput<String> domainId) Sets the domain id of the parameter, e.g.setExtras(OptionalOutput<Collection<String>> extras) setHref(OptionalOutput<String> href) setHrefBase(OptionalOutput<String> hrefBase) setLabel(OptionalOutput<String> label) setLicense(OptionalOutput<String> license) Deprecated.setRawFormats(OptionalOutput<Set<String>> formats) <T> voidsetValue(String parameter, T value, IoParameters parameters, Consumer<OptionalOutput<T>> consumer) Methods inherited from class org.n52.io.response.SelfSerializedOutput
getIfSerialized, getIfSerializedCollection, getIfSerializedMap, getIfSet, getIfSetCollection, getIfSetMap, isSet, resolvesToNonNullValue
-
Field Details
-
ID
- See Also:
-
HREF
- See Also:
-
HREF_BASE
- See Also:
-
DOMAIN_ID
- See Also:
-
LABEL
- See Also:
-
EXTRAS
- See Also:
-
RAWFORMATS
- See Also:
-
-
Constructor Details
-
ParameterOutput
public ParameterOutput()
-
-
Method Details
-
setValue
public <T> void setValue(String parameter, T value, IoParameters parameters, Consumer<OptionalOutput<T>> consumer) -
getId
-
setId
-
getHref
-
getCollectionName
-
setHref
-
getHrefBase
-
setHrefBase
-
getDomainId
Returns the domain id of the parameter, e.g. a natural id (not arbitrarily generated) or the original id actually being used by proxied data sources.- Returns:
- the domain id
-
setDomainId
Sets the domain id of the parameter, e.g. a natural (not arbitrarily generated) id or the original id actually being used by proxied data sources.- Parameters:
domainId- the domain id of the parameter- Returns:
- the instance to enable chaining
-
getLabel
- Returns:
- the label. Returns null if label is not set.
-
setLabel
-
getLicense
Deprecated. -
setLicense
Deprecated. -
getExtras
- Returns:
- a list of extra identifiers available via
/{resource}/extras
-
setExtras
-
getRawFormats
- Specified by:
getRawFormatsin interfaceRawFormats- Returns:
- the rawFormats
-
setRawFormats
- Specified by:
setRawFormatsin interfaceRawFormats- Parameters:
formats- the rawFormats to set- Returns:
- the instance to enable chaining
-
hashCode
public int hashCode() -
equals
-
compareTo
- Specified by:
compareToin interfaceComparable<ParameterOutput>
-
defaultComparator
Takes the default comparator to compare.- Type Parameters:
T- the actual type.- Returns:
- a label or id comparing
Comparator
-
labelComparator
Takes the labels to compare.- Type Parameters:
T- the actual type.- Returns:
- a label comparing
Comparator
-
idComparator
Takes the ids to compare.- Type Parameters:
T- the actual type.- Returns:
- a id comparing
Comparator
-