org.processmining.plugins.pnml
Class PnmlElement

java.lang.Object
  extended by org.processmining.plugins.pnml.PnmlElement
Direct Known Subclasses:
Pnml, PnmlAnnotation, PnmlAnnotationGraphics, PnmlArcGraphics, PnmlBasicObject, PnmlDimension, PnmlFill, PnmlFinalMarking, PnmlFinalMarkings, PnmlFont, PnmlLabelConnection, PnmlLine, PnmlMarkedPlace, PnmlModule, PnmlNodeGraphics, PnmlOffset, PnmlPorts, PnmlPosition, PnmlText, PnmlToolSpecific

public class PnmlElement
extends java.lang.Object

Basic PNML element. All PNML objects extend this class (either directly or indirectly).

Author:
hverbeek

Field Summary
 int lineNumber
           
 java.lang.String tag
          The PNML tag for this element.
 
Constructor Summary
PnmlElement(java.lang.String tag)
          Creates a fresh PNML element.
 
Method Summary
protected  void checkValidity(Pnml pnml)
          Default check for validity: No action.
protected  java.lang.String exportAttribute(java.lang.String tag, java.lang.String value, Pnml pnml)
          Default way to export some attribute.
protected  java.lang.String exportAttributes(Pnml pnml)
          Exports all standard attributes: None.
 java.lang.String exportElement(Pnml pnml)
          Exports the element.
protected  java.lang.String exportElements(Pnml pnml)
          Exports all standard elements: None.
protected  void importAttributes(org.xmlpull.v1.XmlPullParser xpp, Pnml pnml)
          Imports all standard attributes: None.
 void importElement(org.xmlpull.v1.XmlPullParser xpp, Pnml pnml)
          Imports the given element.
protected  boolean importElements(org.xmlpull.v1.XmlPullParser xpp, Pnml pnml)
          Imports all standard child elements: None.
protected  void importText(java.lang.String text, Pnml pnml)
          Imports standard text: No action.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

tag

public java.lang.String tag
The PNML tag for this element.


lineNumber

public int lineNumber
Constructor Detail

PnmlElement

public PnmlElement(java.lang.String tag)
Creates a fresh PNML element.

Parameters:
tag -
Method Detail

importElement

public void importElement(org.xmlpull.v1.XmlPullParser xpp,
                          Pnml pnml)
Imports the given element.

Parameters:
xpp -
pnml -

exportElement

public java.lang.String exportElement(Pnml pnml)
Exports the element.

Returns:

importAttributes

protected void importAttributes(org.xmlpull.v1.XmlPullParser xpp,
                                Pnml pnml)
Imports all standard attributes: None. If some subclass has attributes, this method needs to be overruled by it.

Parameters:
xpp -
pnml -

exportAttributes

protected java.lang.String exportAttributes(Pnml pnml)
Exports all standard attributes: None. If some subclass has attributes, this method needs to be overruled by it.

Returns:

importElements

protected boolean importElements(org.xmlpull.v1.XmlPullParser xpp,
                                 Pnml pnml)
Imports all standard child elements: None. If some subclass has child elements, this method needs to be overruled by it.

Parameters:
xpp -
pnml -
Returns:

exportElements

protected java.lang.String exportElements(Pnml pnml)
Exports all standard elements: None. If some subclass has child elements, this method needs to be overruled by it.

Returns:

importText

protected void importText(java.lang.String text,
                          Pnml pnml)
Imports standard text: No action. If some subclass needs to import text, this method needs to be overruled by it.

Parameters:
text -
pnml -

exportAttribute

protected java.lang.String exportAttribute(java.lang.String tag,
                                           java.lang.String value,
                                           Pnml pnml)
Default way to export some attribute.

Parameters:
tag - The attribute tag.
value - The attribute value.
Returns:

checkValidity

protected void checkValidity(Pnml pnml)
Default check for validity: No action. If some subclass needs to check validity, this method needs to be overruled by it.

Parameters:
pnml -