org.processmining.exporting.petrinet.cpnexport
Class ColoredEdge

java.lang.Object
  extended by att.grappa.Element
      extended by att.grappa.Edge
          extended by org.processmining.framework.models.ModelGraphEdge
              extended by org.processmining.framework.models.petrinet.PNEdge
                  extended by org.processmining.exporting.petrinet.cpnexport.ColoredEdge
All Implemented Interfaces:
att.grappa.GrappaConstants, java.lang.Cloneable

public class ColoredEdge
extends PNEdge

An edge being part of a high-level Petri net simulation model.

Author:
Anne Rozinat, Ronny Mans
See Also:
ColoredPetriNet, ColoredTransition, ColoredPlace

Field Summary
 
Fields inherited from class org.processmining.framework.models.ModelGraphEdge
object2, style, value, visualObject
 
Fields inherited from class att.grappa.Edge
defaultNamePrefix, headNode, tailNode
 
Fields inherited from class att.grappa.Element
counter, highlight, linewidth, object, printAllAttributes, printDefaultAttributes, usePrintList, visible
 
Fields inherited from interface att.grappa.GrappaConstants
_NO_TYPE, ANONYMOUS_PREFIX, BBOX_ATTR, BBOX_HASH, BOX_SHAPE, BOX_TYPE, CLUSTERRANK_ATTR, COLOR_ATTR, COLOR_HASH, COLOR_TYPE, CUSTOM_ATTR, CUSTOM_HASH, CUSTOM_SHAPE, DELETION_MASK, DIAMOND_SHAPE, DIR_ATTR, DIR_HASH, DIR_TYPE, DISTORTION_ATTR, DISTORTION_HASH, DOUBLE_TYPE, DOUBLECIRCLE_SHAPE, DOUBLEOCTAGON_SHAPE, EDGE, EGG_SHAPE, FILLCOLOR_ATTR, FILLCOLOR_HASH, FONTCOLOR_ATTR, FONTCOLOR_HASH, FONTNAME_ATTR, FONTNAME_HASH, FONTSIZE_ATTR, FONTSIZE_HASH, FONTSTYLE_ATTR, FONTSTYLE_HASH, FONTSTYLE_TYPE, GRAPPA_BACKGROUND_COLOR_ATTR, GRAPPA_BACKGROUND_COLOR_HASH, GRAPPA_DELETION_STYLE_ATTR, GRAPPA_DELETION_STYLE_HASH, GRAPPA_FONTSIZE_ADJUSTMENT_ATTR, GRAPPA_FONTSIZE_ADJUSTMENT_HASH, GRAPPA_SELECTION_STYLE_ATTR, GRAPPA_SELECTION_STYLE_HASH, GRAPPA_SHAPE, HASHLIST_TYPE, HEIGHT_ATTR, HEIGHT_HASH, HEXAGON_SHAPE, HIGHLIGHT_MASK, HIGHLIGHT_OFF, HIGHLIGHT_ON, HIGHLIGHT_TOGGLE, HOUSE_SHAPE, IDENTXFRM, IMAGE_ATTR, IMAGE_HASH, INTEGER_TYPE, INVERTEDHOUSE_SHAPE, INVERTEDTRAPEZIUM_SHAPE, INVERTEDTRIANGLE_SHAPE, LABEL_ATTR, LABEL_HASH, LINE_SHAPE, LINE_TYPE, LOG10, LP_ATTR, LP_HASH, MARGIN_ATTR, MARGIN_HASH, MCIRCLE_SHAPE, MCLIMIT_ATTR, MCLIMIT_HASH, MDIAMOND_SHAPE, MINBOX_ATTR, MINBOX_HASH, MINLEN_ATTR, MINLEN_HASH, MINSIZE_ATTR, MINSIZE_HASH, MRECORD_SHAPE, MSQUARE_SHAPE, NBSP, NEW_LINE, NO_SHAPE, NODE, NODESEP_ATTR, NODESEP_HASH, OCTAGON_SHAPE, ORIENTATION_ATTR, ORIENTATION_HASH, OVAL_SHAPE, PACKAGE_PREFIX, PARALLELOGRAM_SHAPE, PATCH_ATTR, PATCH_HASH, PENTAGON_SHAPE, PERIPHERIES_ATTR, PERIPHERIES_HASH, PERIPHERY_GAP, PKG_LOWER, PKG_UPLOW, PKG_UPPER, PLAINTEXT_SHAPE, POINT_TYPE, PointsPerInch, POLYGON_SHAPE, POS_ATTR, POS_HASH, PRINTLIST_ATTR, PRINTLIST_HASH, RANKDIR_ATTR, RANKDIR_HASH, RANKSEP_ATTR, RANKSEP_HASH, RECORD_SHAPE, RECTS_ATTR, RECTS_HASH, ROTATION_ATTR, ROTATION_HASH, ROUNDEDBOX_SHAPE, SELECTION_MASK, SHAPE_ATTR, SHAPE_HASH, SHAPE_MASK, SHAPE_TYPE, SIDES_ATTR, SIDES_HASH, SIZE_ATTR, SIZE_HASH, SIZE_TYPE, SKEW_ATTR, SKEW_HASH, STRING_TYPE, STYLE_ATTR, STYLE_HASH, STYLE_TYPE, SUBGRAPH, SYSTEM, TAG_ATTR, TAG_HASH, TIP_ATTR, TIP_HASH, TRAPEZIUM_SHAPE, TRIANGLE_SHAPE, TRIPLEOCTAGON_SHAPE, TYPES_SHIFT, WEIGHT_ATTR, WEIGHT_HASH, WIDTH_ATTR, WIDTH_HASH
 
Constructor Summary
ColoredEdge(Place source, Transition target)
          The constructor creates a ColoredEdge from a ColoredPlace to a ColoredTransition.
ColoredEdge(Transition source, Place target)
          The constructor creates a ColoredEdge from a ColoredTransition to a ColoredPlace.
 
Method Summary
 void addBendPoint(java.util.ArrayList<java.lang.String> bendPoint)
          Add a bend point to this arc
 java.lang.String getArcInscription()
          Returns the arc inscription for this arc (according to the CPN tools syntax).
 java.util.ArrayList<java.util.ArrayList> getBendPoints()
          Retrieve all the bendpoints for this arc
 boolean isDoubleHeaded()
          Retrieves whether the arc is doubleheaded.
 void setArcInscription(java.lang.String inscript)
          Sets the arc inscription for this arc (The inscription has to be according to the CPN tools syntax).
 void setDoubleHeaded(boolean doubleHeaded)
          indicate whether the arc is doubleheaded USE ONLY FOR CPN FILE GENERATION
 void write(java.io.BufferedWriter bw)
          Writes this edge to the cpn-file.
 
Methods inherited from class org.processmining.framework.models.petrinet.PNEdge
clone, getProbability, getTransition, isPT, isTP, setProbability
 
Methods inherited from class org.processmining.framework.models.ModelGraphEdge
getDest, getSource, getStyle, getValue, setValue
 
Methods inherited from class att.grappa.Edge
attributeType, findEdgeByKey, findEdgesByEnds, getHead, getHeadPortId, getKey, getOpposite, getTail, getTailPortId, getType, goesForward, goesReverse, isEdge, printEdge, toString
 
Methods inherited from class att.grappa.Element
addTag, attrNotOfInterest, attrOfInterest, bdfs, buildShape, canonString, canonValue, clearBBox, delete, getAttribute, getAttributePairs, getAttributeValue, getDefaultAttribute, getDefaultAttribute, getGraph, getGrappaNexus, getId, getIdKey, getLocalAttribute, getLocalAttributeKeys, getLocalAttributePairs, getName, getSubgraph, getThisAttribute, getThisAttributeValue, hasAttributeForKey, hasDefaultTag, hasDefaultTags, hasLocalTag, hasLocalTags, hasTag, hasTags, isNode, isOfInterest, isSubgraph, listAttrsOfInterest, printElement, removeTag, removeTags, setAttribute, setAttribute, setDefaultAttribute, setDefaultAttribute, setDefaultAttribute, setDefaultAttribute, setIdKey, setSubgraph, setUserAttributeType, typeString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ColoredEdge

public ColoredEdge(Transition source,
                   Place target)
The constructor creates a ColoredEdge from a ColoredTransition to a ColoredPlace.

Parameters:
source - the transition to be connected to this arc as a source node
target - the place to be connected to this arc as a target node

ColoredEdge

public ColoredEdge(Place source,
                   Transition target)
The constructor creates a ColoredEdge from a ColoredPlace to a ColoredTransition.

Parameters:
source - the place to be connected to this arc as a source node
target - the transition to be connected to this arc as a target node
Method Detail

write

public void write(java.io.BufferedWriter bw)
           throws java.io.IOException
Writes this edge to the cpn-file.

Parameters:
bw - BufferedWriter used to stream the data to the file
Throws:
IOException

getArcInscription

public java.lang.String getArcInscription()
Returns the arc inscription for this arc (according to the CPN tools syntax).

Returns:
the arc inscription.

setArcInscription

public void setArcInscription(java.lang.String inscript)
Sets the arc inscription for this arc (The inscription has to be according to the CPN tools syntax).

Parameters:
inscript - the arc inscription for this arc.

addBendPoint

public void addBendPoint(java.util.ArrayList<java.lang.String> bendPoint)
Add a bend point to this arc

Parameters:
bendPoint - ArrayList the first element in the array needs to be value for the x-axis and the second value in the array needs to be the value on the y-axis

getBendPoints

public java.util.ArrayList<java.util.ArrayList> getBendPoints()
Retrieve all the bendpoints for this arc

Returns:
ArrayList

setDoubleHeaded

public void setDoubleHeaded(boolean doubleHeaded)
indicate whether the arc is doubleheaded USE ONLY FOR CPN FILE GENERATION

Parameters:
doubleHeaded - boolean

isDoubleHeaded

public boolean isDoubleHeaded()
Retrieves whether the arc is doubleheaded. USE ONLY FOR CPN FILE GENERATION

Returns:
boolean