Class ElementsLine
- java.lang.Object
-
- org.primefaces.model.charts.optionconfig.elements.ElementsLine
-
- All Implemented Interfaces:
Serializable
public class ElementsLine extends Object implements Serializable
Line elements are used to represent the line in a line chart.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ElementsLine()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Stringencode()Write the line options of ElementsStringgetBackgroundColor()Gets the backgroundColorStringgetBorderCapStyle()Gets the borderCapStyleStringgetBorderColor()Gets the borderColorList<Number>getBorderDash()Gets the borderDashNumbergetBorderDashOffset()Gets the borderDashOffsetStringgetBorderJoinStyle()Gets the borderJoinStyleNumbergetBorderWidth()Gets the borderWidthObjectgetFill()Gets the fillNumbergetTension()Gets the tensionbooleanisCapBezierPoints()Gets the capBezierPointsbooleanisStepped()Gets the steppedvoidsetBackgroundColor(String backgroundColor)Sets the backgroundColorvoidsetBorderCapStyle(String borderCapStyle)Sets the borderCapStylevoidsetBorderColor(String borderColor)Sets the borderColorvoidsetBorderDash(List<Number> borderDash)Sets the borderDashvoidsetBorderDashOffset(Number borderDashOffset)Sets the borderDashOffsetvoidsetBorderJoinStyle(String borderJoinStyle)Sets the borderJoinStylevoidsetBorderWidth(Number borderWidth)Sets the borderWidthvoidsetCapBezierPoints(boolean capBezierPoints)Sets the capBezierPointsvoidsetFill(Object fill)Sets the fillvoidsetStepped(boolean stepped)Sets the steppedvoidsetTension(Number tension)Sets the tension
-
-
-
Method Detail
-
getTension
public Number getTension()
Gets the tension- Returns:
- tension
-
setTension
public void setTension(Number tension)
Sets the tension- Parameters:
tension- Bézier curve tension (0 for no Bézier curves).
-
getBackgroundColor
public String getBackgroundColor()
Gets the backgroundColor- Returns:
- backgroundColor
-
setBackgroundColor
public void setBackgroundColor(String backgroundColor)
Sets the backgroundColor- Parameters:
backgroundColor- Line fill color.
-
getBorderWidth
public Number getBorderWidth()
Gets the borderWidth- Returns:
- borderWidth
-
setBorderWidth
public void setBorderWidth(Number borderWidth)
Sets the borderWidth- Parameters:
borderWidth- Line stroke width.
-
getBorderColor
public String getBorderColor()
Gets the borderColor- Returns:
- borderColor
-
setBorderColor
public void setBorderColor(String borderColor)
Sets the borderColor- Parameters:
borderColor- Line stroke color.
-
getBorderCapStyle
public String getBorderCapStyle()
Gets the borderCapStyle- Returns:
- borderCapStyle
-
setBorderCapStyle
public void setBorderCapStyle(String borderCapStyle)
Sets the borderCapStyle- Parameters:
borderCapStyle- Line cap style.
-
setBorderDash
public void setBorderDash(List<Number> borderDash)
Sets the borderDash- Parameters:
borderDash- Line dash
-
getBorderDashOffset
public Number getBorderDashOffset()
Gets the borderDashOffset- Returns:
- borderDashOffset
-
setBorderDashOffset
public void setBorderDashOffset(Number borderDashOffset)
Sets the borderDashOffset- Parameters:
borderDashOffset- Line dash offset
-
getBorderJoinStyle
public String getBorderJoinStyle()
Gets the borderJoinStyle- Returns:
- borderJoinStyle
-
setBorderJoinStyle
public void setBorderJoinStyle(String borderJoinStyle)
Sets the borderJoinStyle- Parameters:
borderJoinStyle- Line join style.
-
isCapBezierPoints
public boolean isCapBezierPoints()
Gets the capBezierPoints- Returns:
- capBezierPoints
-
setCapBezierPoints
public void setCapBezierPoints(boolean capBezierPoints)
Sets the capBezierPoints- Parameters:
capBezierPoints- true to keep Bézier control inside the chart, false for no restriction.
-
getFill
public Object getFill()
Gets the fill- Returns:
- fill
-
setFill
public void setFill(Object fill)
Sets the fill- Parameters:
fill- Fill location: 'zero', 'top', 'bottom', true (eq. 'zero') or false (no fill).
-
isStepped
public boolean isStepped()
Gets the stepped- Returns:
- stepped
-
setStepped
public void setStepped(boolean stepped)
Sets the stepped- Parameters:
stepped- true to show the line as a stepped line (tension will be ignored).
-
encode
public String encode() throws IOException
Write the line options of Elements- Returns:
- options as JSON object
- Throws:
IOException- If an I/O error occurs
-
-