Class PnmlNode
- java.lang.Object
-
- org.processmining.plugins.pnml.base.PnmlElement
-
- org.processmining.plugins.pnml.elements.PnmlBasicObject
-
- org.processmining.plugins.pnml.elements.PnmlNode
-
- Direct Known Subclasses:
PnmlLabel,PnmlPage,PnmlPlace,PnmlPort,PnmlReferencePlace,PnmlReferenceTransition,PnmlTransition
public abstract class PnmlNode extends PnmlBasicObject
Basic PNML node object.- Author:
- hverbeek
-
-
Field Summary
Fields Modifier and Type Field Description protected PnmlNodeGraphicsgraphicsGraphics element.protected java.lang.StringidId attribute.-
Fields inherited from class org.processmining.plugins.pnml.elements.PnmlBasicObject
name, toolSpecificList
-
Fields inherited from class org.processmining.plugins.pnml.base.PnmlElement
factory, lineNumber, tag
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedPnmlNode(java.lang.String tag)Creates a fresh PNML node.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidcheckValidity(Pnml pnml)Checks the validity of this node.PnmlNodeconvertFromNet(ExpandableSubNet parent, org.processmining.models.graphbased.AbstractGraphElement element, java.util.Map<org.processmining.framework.util.Pair<org.processmining.models.graphbased.AbstractGraphElement,ExpandableSubNet>,java.lang.String> idMap, org.processmining.models.connections.GraphLayoutConnection layout)voidconvertToNet(ExpandableSubNet subNet, PetrinetNode node, java.awt.geom.Point2D.Double displacement, org.processmining.models.connections.GraphLayoutConnection layout)protected java.lang.StringexportAttributes(Pnml pnml)Exports all attributes.protected java.lang.StringexportElements(Pnml pnml)Exports all child elements.org.processmining.framework.util.Pair<java.awt.geom.Point2D.Double,java.awt.geom.Point2D.Double>getBoundingBox()Gets the bounding box for this node.PnmlNodeGraphicsgetGraphics()protected voidimportAttributes(org.xmlpull.v1.XmlPullParser xpp, Pnml pnml)Imports all known attributes.protected booleanimportElements(org.xmlpull.v1.XmlPullParser xpp, Pnml pnml)Checks whether the current start tag is known.-
Methods inherited from class org.processmining.plugins.pnml.elements.PnmlBasicObject
convertFromNet, convertToNet, convertToNet, getName
-
Methods inherited from class org.processmining.plugins.pnml.base.PnmlElement
exportAttribute, exportElement, importElement, importText, setFactory
-
-
-
-
Field Detail
-
id
protected java.lang.String id
Id attribute.
-
graphics
protected PnmlNodeGraphics graphics
Graphics element.
-
-
Method Detail
-
importAttributes
protected void importAttributes(org.xmlpull.v1.XmlPullParser xpp, Pnml pnml)Imports all known attributes.- Overrides:
importAttributesin classPnmlElement
-
exportAttributes
protected java.lang.String exportAttributes(Pnml pnml)
Exports all attributes.- Overrides:
exportAttributesin classPnmlElement- Returns:
-
importElements
protected boolean importElements(org.xmlpull.v1.XmlPullParser xpp, Pnml pnml)Checks whether the current start tag is known. If known, it imports the corresponding child element and returns true. Otherwise, it returns false.- Overrides:
importElementsin classPnmlBasicObject- Returns:
- Whether the start tag was known.
-
exportElements
protected java.lang.String exportElements(Pnml pnml)
Exports all child elements.- Overrides:
exportElementsin classPnmlBasicObject- Returns:
-
checkValidity
protected void checkValidity(Pnml pnml)
Checks the validity of this node. Should have an id attribute.- Overrides:
checkValidityin classPnmlElement
-
getGraphics
public PnmlNodeGraphics getGraphics()
-
getBoundingBox
public org.processmining.framework.util.Pair<java.awt.geom.Point2D.Double,java.awt.geom.Point2D.Double> getBoundingBox()
Gets the bounding box for this node.- Returns:
- The bounding box for this node.
-
convertToNet
public void convertToNet(ExpandableSubNet subNet, PetrinetNode node, java.awt.geom.Point2D.Double displacement, org.processmining.models.connections.GraphLayoutConnection layout)
-
convertFromNet
public PnmlNode convertFromNet(ExpandableSubNet parent, org.processmining.models.graphbased.AbstractGraphElement element, java.util.Map<org.processmining.framework.util.Pair<org.processmining.models.graphbased.AbstractGraphElement,ExpandableSubNet>,java.lang.String> idMap, org.processmining.models.connections.GraphLayoutConnection layout)
-
-