Class AuxLine<C extends AbstractChartBuilder<C>>
Object
ObjectIdentity
BacklinkBuilder<C>
AuxLine<C>
Builder for an auxiliary reference line on a chart, obtained from
AbstractChartBuilder.addAuxLine() rather than instantiated directly. An auxiliary line is
independent of the chart's data series and is typically used to mark a fixed reference value, for example a
percentile threshold or a target. Choose its shape with withLine() (a straight line),
withSteppedLine() (a piecewise line through explicit points), or withVerticalLine() (a
single vertical line at a fixed X value); the three are alternatives, not meant to be combined on the same
auxiliary line.- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classAuxLine.Line<C extends ObjectIdentity>A straightAuxLineshape,y = yIntercept + steepness * x, obtained fromwithLine()rather than instantiated directly.static classAuxLine.SteppedLine<C extends ObjectIdentity>A piecewiseAuxLineshape defined by explicit (X, Y) points, obtained fromwithSteppedLine()rather than instantiated directly.static classAuxLine.VerticalLine<C extends ObjectIdentity>A single verticalAuxLineshape at a fixed X axis value, obtained fromwithVerticalLine()rather than instantiated directly. -
Field Summary
Fields inherited from class BacklinkBuilder
METHOD_BACKFields inherited from class ObjectIdentity
classId, idGenerator, instanceId, invocations, m, NONE, parentObjectIdentity -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionsetColor(AuxLineColor color) Sets this auxiliary line's color.setHideDataLabels(Boolean hideDataLabels) Hides this auxiliary line's data labels.Sets this auxiliary line's label, shown in the chart's legend and tooltips, for example"65th Percentile".setShowInLegend(Boolean showInLegend) Shows or hides this auxiliary line in the chart's legend.withLine()Shapes this auxiliary line as a straight line,y = yIntercept + steepness * x.Shapes this auxiliary line as a piecewise line through explicit points.Shapes this auxiliary line as a single vertical line at a fixed X axis value.Methods inherited from class BacklinkBuilder
back, getParentMethods inherited from class ObjectIdentity
addInvocation, addInvocation, addInvocationInternal, getClassId
-
Constructor Details
-
AuxLine
-
-
Method Details
-
setLabel
Sets this auxiliary line's label, shown in the chart's legend and tooltips, for example"65th Percentile".- Parameters:
label- the label to display for this auxiliary line- Returns:
- this auxiliary line, for chaining further configuration
-
setShowInLegend
Shows or hides this auxiliary line in the chart's legend.- Parameters:
showInLegend-trueto show it in the legend;falseornullto hide it- Returns:
- this auxiliary line, for chaining further configuration
-
setHideDataLabels
Hides this auxiliary line's data labels.- Parameters:
hideDataLabels-trueto hide the labels;falseornullto show them- Returns:
- this auxiliary line, for chaining further configuration
-
withLine
Shapes this auxiliary line as a straight line,y = yIntercept + steepness * x. CallAuxLine.Line.setYIntercept(String)andAuxLine.Line.setSteepness(String)on the returned builder.- Returns:
- a new
AuxLine.Linebuilder for this auxiliary line. Nevernull. - See Also:
-
withSteppedLine
Shapes this auxiliary line as a piecewise line through explicit points. CallAuxLine.SteppedLine.addStep(String, String)once per point.- Returns:
- a new
AuxLine.SteppedLinebuilder for this auxiliary line. Nevernull. - See Also:
-
withVerticalLine
Shapes this auxiliary line as a single vertical line at a fixed X axis value. CallAuxLine.VerticalLine.setXValue(String)on the returned builder.- Returns:
- a new
AuxLine.VerticalLinebuilder for this auxiliary line. Nevernull. - See Also:
-
setColor
Sets this auxiliary line's color.- Parameters:
color- the color to render this auxiliary line in- Returns:
- this auxiliary line, for chaining further configuration
-