Class RangeFlux

All Implemented Interfaces:
Expression, HasImports

public final class RangeFlux extends AbstractParametrizedFlux
Filters the results by time boundaries. See SPEC.

Options

  • start - Specifies the oldest time to be included in the results [duration or timestamp]
  • stop - Specifies the exclusive newest time to be included in the results. Defaults to "now". [duration or timestamp]

Example

 Flux flux = Flux
     .from("telegraf")
     .range(-12L, -1L, ChronoUnit.HOURS)
 
Author:
Jakub Bednar (bednar@github) (26/06/2018 07:04)
  • Constructor Details

    • RangeFlux

      public RangeFlux(@Nonnull Flux flux)
  • Method Details

    • operatorName

      @Nonnull protected String operatorName()
      Specified by:
      operatorName in class AbstractParametrizedFlux
      Returns:
      name of function
    • withStart

      @Nonnull public RangeFlux withStart(@Nonnull Instant start)
      Parameters:
      start - Specifies the oldest time to be included in the results
      Returns:
      this
    • withStart

      @Nonnull public RangeFlux withStart(@Nonnull Long start, @Nonnull ChronoUnit unit)
      Parameters:
      start - Specifies the oldest time to be included in the results
      unit - a ChronoUnit determining how to interpret the start parameter
      Returns:
      this
    • withStart

      @Nonnull public RangeFlux withStart(@Nonnull String start)
      Parameters:
      start - Specifies the oldest time to be included in the results
      Returns:
      this
    • withStart

      @Nonnull public RangeFlux withStart(Long start)
      Parameters:
      start - Specifies the oldest time (Unix timestamp in seconds) to be included in the results
      Returns:
      this
    • withStop

      @Nonnull public RangeFlux withStop(@Nonnull Instant stop)
      Parameters:
      stop - Specifies the exclusive newest time to be included in the results
      Returns:
      this
    • withStop

      @Nonnull public RangeFlux withStop(@Nonnull Long stop, @Nonnull ChronoUnit unit)
      Parameters:
      stop - Specifies the exclusive newest time to be included in the results
      unit - a ChronoUnit determining how to interpret the start parameter
      Returns:
      this
    • withStop

      @Nonnull public RangeFlux withStop(@Nonnull String stop)
      Parameters:
      stop - Specifies the exclusive newest time to be included in the results
      Returns:
      this
    • withStop

      @Nonnull public RangeFlux withStop(Long stop)
      Parameters:
      stop - Specifies the exclusive newest time (Unix timestamp in seconds) to be included in the results
      Returns:
      this
    • collectImports

      public void collectImports(@Nonnull Set<String> collectedImports)
      Description copied from class: Flux
      Collects all imports of the flux.
      Overrides:
      collectImports in class Flux
      Parameters:
      collectedImports - a set to be filled by the used imports