Class GetSamplesParameters

java.lang.Object
com.seeq.link.sdk.interfaces.GetSamplesParameters

public class GetSamplesParameters extends Object
  • Constructor Details

  • Method Details

    • getDataId

      public String getDataId()
      A connector-defined string that identifies the signal to retrieve data for.
      Returns:
      connector-defined string that identifies the signal to retrieve data for.
    • getStartTime

      public TimeInstant getStartTime()
      The start time for the requested data. Note: This function must return "boundary values" as well, which are the nearest values immediately outside the requested interval. If your datasource does not return such "boundary values" efficiently, use the getExpandedStartTime() field for your datasource query.
      Returns:
      start time for the requested data
    • getExpandedStartTime

      public TimeInstant getExpandedStartTime()
      The start time for the requested data minus the "maximum interpolation" for the signal. This value represents the earliest possible time that a sample may be relevant for a given request. This is useful when the datasource does not have a facility for efficiently returning a sample that is "on or before" the start time. You can just use the ExpandedStartTime/ExpandedEndTime fields instead and return all the samples within the expanded range. Seeq Server will ignore the values it doesn't need.
      Returns:
      expanded start time for the requested data
    • getEndTime

      public TimeInstant getEndTime()
      The end time for the requested data. Note: This function must return "boundary values" as well, which are the nearest values immediately outside the requested interval.
      Returns:
      end time for the requested data
    • getExpandedEndTime

      public TimeInstant getExpandedEndTime()
      The end time for the requested data plus the "maximum interpolation" for the signal. This value represents the latest possible time that a sample may be relevant for a given request. This is useful when the datasource does not have a facility for efficiently returning a sample that is "on or after" the end time. You can just use the ExpandedStartTime/ExpandedEndTime fields instead and return all the samples within the expanded range. Seeq Server will ignore the values it doesn't need.
      Returns:
      expanded end time for the requested data
    • getMaxInterpolation

      public long getMaxInterpolation()
      Returns:
      the maximum interpolation for the requested signal in nanoseconds.
    • getSampleLimit

      public int getSampleLimit()
      The maximum samples that can be returned as part of this request. Note that the connection need not enforce this limit, as no more samples than the limit will be read from the sample stream that is returned from this method. This limit is provided for informational purposes to enable optimization where possible.
      Returns:
      sample limit for this request
    • isLastCertainKeyRequested

      public boolean isLastCertainKeyRequested()
      If true, you can specify a time instant to setLastCertainKey(TimeInstant) to indicate to Seeq that any samples after a time instant are uncertain. If false, you cannot make such a method call (and should not try to calculate a time) because Seeq will not use the value.
    • getValueUom

      public String getValueUom()
    • setLastCertainKey

      public void setLastCertainKey(TimeInstant key)
      If isLastCertainKeyRequested() returns true, you can invoke this method to indicate to Seeq that any samples after a time instant are uncertain. There does not need to be a sample present at the key specified; for instance, if a historian guarantees that all data is recorded within three hours, and the most recent sample is two weeks ago, this value may be now - three hours. Any samples after this key will be treated as uncertain by Seeq, and any samples before or at the key will be treated as certain.

      If this method is not invoked, Seeq will assume that all samples returned are certain, and that no new samples will change or appear at or before the latest sample key seen. This inference carries no performance penalty, so for a datasource where no historical changes are expected, not invoking this method is a reasonable default.

      If you supply null for the key, it will clear any key set by a previous call.

      You can invoke this method anytime after SignalPullDatasourceConnection.getSamples(GetSamplesParameters) is entered, and you may invoke it multiple times. If you do, the last invocation takes precedence.