Class ParameterService<T extends ParameterOutput>

java.lang.Object
org.n52.series.spi.srv.ParameterService<T>
Type Parameters:
T - the actual parameter type.
All Implemented Interfaces:
RawDataInfo
Direct Known Subclasses:
TransformingGeometryOutputService, TransformingStationOutputService, TransformingTimeseriesService

public abstract class ParameterService<T extends ParameterOutput> extends Object implements RawDataInfo
A generic service to get arbitrary parameters from the underlying data access implementation. In general the access can result either in compact or detailed outputs. However, each query can be controlled in more detail by a parameter values hold by a IoParameters.
  • Constructor Details

    • ParameterService

      public ParameterService()
  • Method Details

    • getExpandedParameters

      public abstract OutputCollection<T> getExpandedParameters(IoParameters query)
      Parameters:
      query - query parameters to control the output.
      Returns:
      an output collection of expanded items.
    • getCondensedParameters

      public abstract OutputCollection<T> getCondensedParameters(IoParameters query)
      Parameters:
      query - query parameters to control the output.
      Returns:
      an output collection of compact items.
    • getParameters

      public abstract OutputCollection<T> getParameters(String[] items, IoParameters query)
      Gets the requested items with respect to the given query parameters. Note, that implementations may be aware of parameters not specified by the official timeseries API. However, at least all officially specified query parameters should be considered by all implementations.
      Parameters:
      items - a subset of item ids which are of interest.
      query - query parameters to control the output.
      Returns:
      an output collection of expanded items which are of interest. Not known ids will be ignored.
    • getParameter

      public abstract T getParameter(String item, IoParameters query)
      Gets the requested item with respect to the given query parameters. Note, that implementations may be aware of parameters not specified by the official timeseries API. However, at least all officially specified query parameters should be considered by all implementations.
      Parameters:
      item - the item id of interest.
      query - query parameters to control the output.
      Returns:
      an expanded items of interest.
    • exists

      public abstract boolean exists(String id, IoParameters parameters)
      If a resource exists or not.
      Parameters:
      id - the id of the resource.
      parameters - the query passed along.
      Returns:
      true if the resource exists, false otherwise.
      Since:
      2.0.0
    • getRawDataService

      public RawDataService getRawDataService()
      Specified by:
      getRawDataService in interface RawDataInfo
    • setRawDataService

      public void setRawDataService(RawDataService rawDataService)