Class CumulativeSumFlux

All Implemented Interfaces:
Expression, HasImports

public final class CumulativeSumFlux extends AbstractParametrizedFlux
Cumulative sum computes a running sum for non null records in the table. The output table schema will be the same as the input table. See SPEC.

Options

  • columns - a list of columns on which to operate [array of strings]

Example

 Flux flux = Flux
     .from("telegraf")
     .cumulativeSum(new String[]{"_value"});
 
Author:
Jakub Bednar (10/10/2018 07:32)
  • Constructor Details

    • CumulativeSumFlux

      public CumulativeSumFlux(@Nonnull Flux source)
  • Method Details

    • operatorName

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

      @Nonnull public CumulativeSumFlux withColumns(@Nonnull String[] columns)
      Parameters:
      columns - the columns on which to operate
      Returns:
      this
    • withColumns

      @Nonnull public CumulativeSumFlux withColumns(@Nonnull Collection<String> columns)
      Parameters:
      columns - the columns on which to operate
      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