com.vaadin.flow.component.charts.model.
Class NodeSeries
All Implemented Interfaces:
A series containing nodes and links to nodes.
See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionAdds both nodes and links then in the series.
void
add
(NodeSeriesItem nodeSeriesItem) Adds a data item.
void
Adds a node to the chart.
getData()
getNodes()
void
Removes the node.
void
remove
(NodeSeriesItem nodeSeriesItem) Removes the nodeSeriesItem.
Methods inherited from class com.vaadin.flow.component.charts.model.AbstractSeries
getColorAxis, getConfiguration, getId, getName, getPlotOptions, getStack, getxAxis, getyAxis, isVisible, setColorAxis, setConfiguration, setId, setName, setPlotOptions, setStack, setVisible, setVisible, setxAxis, setyAxis, setyAxis, updateSeries
-
Constructor Details
-
NodeSeries
public NodeSeries()
-
-
Method Details
-
add
Adds a data item. The to and from nodes must also be added using
addNode(Node)
Parameters:
nodeSeriesItem
- item to be added.Throws:
IllegalArgumentException
- if the nodeSeriesItem is null or if either to or from nodes null or have null ids. -
add
Adds both nodes and links then in the series.
Parameters:
from
- seeNodeSeriesItem.setFrom(Node)
to
- seeNodeSeriesItem.setTo(Node)
Returns:
NodeSeriesItem
created. -
addNode
Adds a node to the chart. To link the added node to other nodes use
add(NodeSeriesItem)
.Parameters:
node
-Node
to be added. Not null.Throws:
IllegalArgumentException
- if the node is null or if its id is null. -
remove
Removes the nodeSeriesItem. To remove the to and from nodes, use
remove(Node)
Parameters:
nodeSeriesItem
- item to be removed. -
remove
Removes the node. To remove the links, use
remove(NodeSeriesItem)
Parameters:
node
- item to be removed. -
getData
Returns:
The data in this series.
-
getNodes
Returns:
The nodes in this Series.
-