Interface ParamAxis

All Known Implementing Classes:
ParamAxis.Range, ParamAxis.Values

public sealed interface ParamAxis permits ParamAxis.Range, ParamAxis.Values
One strategy property and the values a sweep should try for it: either a numeric ParamAxis.Range, or an explicit ParamAxis.Values list.

 Map<String, ParamAxis> params = Map.of(
     "rsiPeriod",      ParamAxis.range(7, 28, 1),
     "useTrendFilter", ParamAxis.of(true, false));
 

A sealed type rather than two builder methods, because the two shapes are mutually exclusive on the wire and mixing them is a request the platform rejects rather than reconciles.

  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static final record 
    A numeric range walked in fixed steps, from through to.
    static final record 
    An explicit list of values.
  • Method Summary

    Modifier and Type
    Method
    Description
    static ParamAxis
    of(Boolean... values)
    An explicit list of boolean values — typically of(true, false) to sweep a flag both ways.
    static ParamAxis
    of(Number... values)
    An explicit list of numeric values.
    static ParamAxis
    range(double from, double to, double step)
    A numeric range walked in fixed steps.
    default com.qtsurfer.api.client.model.SweepAxis
    Internal: the api-client representation of this axis.
  • Method Details

    • range

      static ParamAxis range(double from, double to, double step)
      A numeric range walked in fixed steps.
      Parameters:
      from - first value
      to - last value the walk may reach
      step - increment; must be greater than zero
      Returns:
      the axis
    • of

      static ParamAxis of(Number... values)
      An explicit list of numeric values.
      Parameters:
      values - the values to try; at least one
      Returns:
      the axis
    • of

      static ParamAxis of(Boolean... values)
      An explicit list of boolean values — typically of(true, false) to sweep a flag both ways.
      Parameters:
      values - the values to try; at least one
      Returns:
      the axis
    • wire

      default com.qtsurfer.api.client.model.SweepAxis wire()
      Internal: the api-client representation of this axis. Exposed so the SDK's own helpers can pass it through without re-encoding.
      Returns:
      the generated SweepAxis for this axis