Class ZAggregateArgs

java.lang.Object
io.quarkus.redis.datasource.sortedset.ZAggregateArgs
All Implemented Interfaces:
RedisCommandExtraArguments

public class ZAggregateArgs extends Object implements RedisCommandExtraArguments
  • Constructor Details

    • ZAggregateArgs

      public ZAggregateArgs()
  • Method Details

    • weights

      public ZAggregateArgs weights(double... weights)
      Using the WEIGHTS option, it is possible to specify a multiplication factor for each input sorted set. This means that the score of every element in every input sorted set is multiplied by this factor before being passed to the aggregation function. When WEIGHTS is not given, the multiplication factors default to 1.
      Parameters:
      weights - the weight values
      Returns:
      the current ZAggregateArgs
    • aggregate

      public ZAggregateArgs aggregate(ZAggregateArgs.Aggregate aggregate)
      With the AGGREGATE option, it is possible to specify how the results of the union are aggregated. This option defaults to SUM, where the score of an element is summed across the inputs where it exists. When this option is set to either MIN or MAX, the resulting set will contain the minimum or maximum score of an element across the inputs where it exists.
      Parameters:
      aggregate - the aggregate value
      Returns:
      the current ZAggregateArgs
    • sum

      public ZAggregateArgs sum()
      Configure the aggregate function to be SUM.
      Returns:
      the current ZAggregateArgs
    • min

      public ZAggregateArgs min()
      Configure the aggregate function to be MIN.
      Returns:
      the current ZAggregateArgs
    • max

      public ZAggregateArgs max()
      Configure the aggregate function to be MAX.
      Returns:
      the current ZAggregateArgs
    • toArgs

      public List<Object> toArgs()
      Specified by:
      toArgs in interface RedisCommandExtraArguments
      Returns:
      the list of arguments.