Package com.inet.report.chart.axis
Class IntervalMarker
- java.lang.Object
-
- com.inet.report.chart.axis.AbstractMarker
-
- com.inet.report.chart.axis.IntervalMarker
-
- All Implemented Interfaces:
java.io.Serializable
public class IntervalMarker extends AbstractMarker
Class to create interval markers in a chart plot. An interval marker has two values, a start and an end value.- Since:
- 8.0
- See Also:
AbstractMarker
, Serialized Form
-
-
Field Summary
-
Fields inherited from class com.inet.report.chart.axis.AbstractMarker
DEFAULT_ALPHA, DEFAULT_COLOR, DEFAULT_LINE_STYLE, DEFAULT_LINE_WIDTH, DEFAULT_VALUE
-
-
Constructor Summary
Constructors Constructor Description IntervalMarker()
Creates a marker area with two values: the first (start value) and the second (end value).
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description double
getFirstValue()
Returns the first value (lower bound) of this marker.FormulaField
getFirstValueFormula()
Get the Formula which returns the first value of the marker.double
getSecondValue()
Returns the end value (upper bound) of this marker.FormulaField
getSecondValueFormula()
Get the Formula which returns the second value for the marker.protected java.lang.StringBuilder
getSubProperties(int depth)
Returns the serialized properties of subclasses.boolean
isFirstValueFormulaDate()
Get whether the firstValueFormula returns Dateboolean
isSecondValueFormulaDate()
Get whether the secondValueFormula returns Datevoid
readProperties(org.w3c.dom.Element element, Chart2 chart)
Loads the XML properties of a marker.void
setFirstValue(double firstValue)
Sets the start value (lower bound) of this marker.void
setFirstValueFormula(FormulaField firstValueFormula, boolean isDate)
Set the Formula for the first value of the marker.
Expected type is double or datetime.void
setSecondValue(double secondValue)
Sets the end value (upper bound) of this marker.void
setSecondValueFormula(FormulaField secondValueFormula, boolean isDate)
Set the Formula for the second value of the marker.-
Methods inherited from class com.inet.report.chart.axis.AbstractMarker
getColor, getLineStyle, getLineWidth, getMarkerReferencesIfExist, setColor, setLineStyle, setLineWidth
-
-
-
-
Method Detail
-
getFirstValue
public double getFirstValue()
Returns the first value (lower bound) of this marker.- Returns:
- the firstValue.
- Since:
- 8.0
-
setFirstValue
public void setFirstValue(double firstValue)
Sets the start value (lower bound) of this marker.- Parameters:
firstValue
- the start value- Since:
- 8.0
- See Also:
getFirstValue()
,setSecondValue(double)
-
getSecondValue
public double getSecondValue()
Returns the end value (upper bound) of this marker.- Returns:
- the end Value.
- Since:
- 8.0
-
setSecondValue
public void setSecondValue(double secondValue)
Sets the end value (upper bound) of this marker.- Parameters:
secondValue
- the end value- Since:
- 8.0
- See Also:
getSecondValue()
,setFirstValue(double)
-
getSubProperties
protected java.lang.StringBuilder getSubProperties(int depth)
Returns the serialized properties of subclasses.- Overrides:
getSubProperties
in classAbstractMarker
- Parameters:
depth
- the depth of XML indent- Returns:
- the properties.
-
readProperties
public void readProperties(org.w3c.dom.Element element, Chart2 chart)
Loads the XML properties of a marker.- Overrides:
readProperties
in classAbstractMarker
- Parameters:
element
- DOM element to read marker properties fromchart
- the Chart this marker belongs to, not null
-
getFirstValueFormula
public FormulaField getFirstValueFormula()
Get the Formula which returns the first value of the marker.- Returns:
- the firstValueFormula, can be null when no formula was set
- Since:
- 11.3
-
setFirstValueFormula
public void setFirstValueFormula(FormulaField firstValueFormula, boolean isDate)
Set the Formula for the first value of the marker.
Expected type is double or datetime.- Parameters:
firstValueFormula
- the firstValueFormula to setisDate
- true when this is for a date-axis, so the return type of the formula is DateTime, otherwise it is NUMBER- Throws:
java.lang.IllegalArgumentException
- if the given formula has a different type thanFORMULA_PROPERTY
- Since:
- 11.3
-
getSecondValueFormula
public FormulaField getSecondValueFormula()
Get the Formula which returns the second value for the marker.- Returns:
- the secondValueFormula, can be null when no formula was set
- Since:
- 11.3
-
setSecondValueFormula
public void setSecondValueFormula(FormulaField secondValueFormula, boolean isDate)
Set the Formula for the second value of the marker.- Parameters:
secondValueFormula
- the secondValueFormula to setisDate
- true when this is for a date-axis, so the return type of the formula is DateTime, otherwise it is NUMBER- Throws:
java.lang.IllegalArgumentException
- if the given formula has a different type thanFORMULA_PROPERTY
- Since:
- 11.3
-
isFirstValueFormulaDate
public boolean isFirstValueFormulaDate()
Get whether the firstValueFormula returns Date- Returns:
- the firstValueFormulaIsDate
- Since:
- 11.3
-
isSecondValueFormulaDate
public boolean isSecondValueFormulaDate()
Get whether the secondValueFormula returns Date- Returns:
- the secondValueFormulaIsDate
- Since:
- 11.3
-
-