|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectatt.grappa.Element
att.grappa.Node
org.processmining.framework.models.ModelGraphVertex
org.processmining.framework.models.petrinet.PNNode
org.processmining.framework.models.petrinet.Transition
public class Transition
A transition is node in a Petri net.
It is the active component in the Petri net structure, and when it fires
then it removes a token from all its input places and produces a token for
all its output places. This changes the marking, and therefore the state
of the Peti net.
From the business process perspective, a transition corresponds to a step,
or a task, in a Petri net process model.
PetriNet
,
Place
,
LogEvent
Field Summary |
---|
Fields inherited from class org.processmining.framework.models.ModelGraphVertex |
---|
identifier, object2, value, visualObject |
Fields inherited from class att.grappa.Node |
---|
defaultNamePrefix |
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 | |
---|---|
Transition(LogEvent logModelElement,
PetriNet net)
Constructor specifying the kind of log event. |
|
Transition(PetriNet net)
Basic constructor. |
|
Transition(java.lang.String identifier,
PetriNet net)
Constructor specifying the name. |
|
Transition(Transition t)
Copy Constructor. |
Method Summary | |
---|---|
java.lang.Object |
clone()
Make a deep copy of the object. |
boolean |
equals(java.lang.Object o)
Overridden to specify when two Petri net transitions are considered to be equal. |
void |
fire()
Fires this transition. |
void |
fire(java.util.Date timestamp)
Fires this transition at the given point in time. |
void |
fireQuick()
Fires this transition. |
void |
fireQuick(java.util.Date timestamp)
Fires this transition at the given point in time. |
LogEvent |
getLogEvent()
Gets the log event belonging to this transition. |
LogEvent |
getModelElement()
Deprecated. Please now use getLogEvent() |
int |
getNumber()
Returns the number which is associated to this transition. |
int |
hashCode()
Overridden to produce the same hash code for equal objects. |
protected boolean |
hasLogModelElement(LogEvent lme)
Compares a given log event with the one associated to this transition. |
boolean |
isDuplicateTask()
A task is considered as a duplicate task if there is at least one other task in the model which has the same log event associated. |
boolean |
isEnabled()
Checks whether this transition is enabled. |
boolean |
isEnabled(java.util.Date timestamp)
Checks whether this transition is enabled, taking time information into account. |
boolean |
isInvisibleTask()
A task is considered invisible if there is no log event associated to it. |
boolean |
isNegativeEnabled()
Checks whether this transition is negatively enabled. |
void |
setLogEvent(LogEvent lme)
Sets the log event belonging to this transition. |
void |
setModelElement(LogEvent le)
Deprecated. Please now use setLogEvent(LogEvent le) |
void |
setNumber(int n)
Assigns a number to this transition. |
java.lang.String |
toString()
Returns the name of the transition. |
void |
unFire()
Unfires this transition. |
void |
unFireQuick()
Unfires this transition. |
Methods inherited from class org.processmining.framework.models.ModelGraphVertex |
---|
getIdentifier, getIncidentEdges, getInEdgesIterator, getNeighbors, getOutEdgesIterator, getPredecessors, getSuccessors, getValue, getVerticesOnlyPredecessor, getVerticesOnlySuccessor, getVerticesPredecessorAndSuccessor, setIdentifier, setValue |
Methods inherited from class att.grappa.Node |
---|
addEdge, attributeType, edgeElements, findInEdgeByKey, findOutEdgeByKey, getCenterPoint, getInEdges, getOutEdges, getType, inDegree, inEdgeElements, isNode, outDegree, outEdgeElements, printNode, removeEdge |
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, isEdge, isOfInterest, isSubgraph, listAttrsOfInterest, printElement, removeTag, removeTags, setAttribute, setAttribute, setDefaultAttribute, setDefaultAttribute, setDefaultAttribute, setDefaultAttribute, setIdKey, setSubgraph, setUserAttributeType, typeString |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Transition(LogEvent logModelElement, PetriNet net)
logModelElement
- the log event associatednet
- the Petri net it belongs topublic Transition(PetriNet net)
net
- the Petri net it belongs topublic Transition(java.lang.String identifier, PetriNet net)
identifier
- the name of the transitionnet
- the Petri net it belongs topublic Transition(Transition t)
t
- the template transitionMethod Detail |
---|
public LogEvent getModelElement()
This method returns the current LogEvent the LogEventProvider has stored
public void setModelElement(LogEvent le)
le
- the LogEvent to storeThis method sets the LogEvent for the LogEventProvider to store
public LogEvent getLogEvent()
getLogEvent
in interface LogEventProvider
public void setLogEvent(LogEvent lme)
setLogEvent
in interface LogEventProvider
lme
- the new log event associatedpublic void setNumber(int n)
Since the identifier of a transition is not necessarily unique (i.e.,
two transitions can have the same name) this method can be used to
assign unique numbers to the transitions of a Petri net, if needed.
getNumber()
can be used to retrieve the number.
n
- the number to be assignedpublic int getNumber()
Since the identifier of a transition is not necessarily unique (i.e.,
two transitions can have the same name) this method can be used to
retrieve unique numbers from the transitions of a Petri net, if needed.
However, they are not associated automatically but must have been set
using the setNumber(int i)
method before.
public java.lang.String toString()
equals
method should be used.
toString
in class ModelGraphVertex
public boolean isEnabled()
true
if the transition is enabled, false
otherwiseisNegativeEnabled
public void fire()
Note that this only happens if the transition is enabled. If this check
is not needed, fireQuick()
should be used instead.
The effect is that tokens are produced in the output places of this transition.
isEnabled()
public void fireQuick()
Note that it is not checked whether the transition is enabled. If this
is needed, fire()
should be used instead.
The effect is that tokens are produced in the output places of this transition.
public boolean isEnabled(java.util.Date timestamp)
timestamp
- the time specified
true
if the transition is enabled, false
otherwisepublic void fire(java.util.Date timestamp)
Note that this only happens if the transition is enabled. If this check
is not needed, fireQuick(Date timestamp)
should be used instead.
The effect is that tokens are produced in the output places of this transition.
timestamp
- the time specifiedpublic void fireQuick(java.util.Date timestamp)
Note that it is not checked whether the transition is enabled. If this
is needed, fire(Date timestamp)
should be used instead.
The effect is that tokens are produced in the output places of this transition.
timestamp
- the time specifiedpublic boolean isNegativeEnabled()
true
if the transition is enabled, false
otherwiseisEnabled
public void unFire()
unFireQuick()
should be used instead.
isNegativeEnabled
public void unFireQuick()
unFire()
should be used instead.
protected boolean hasLogModelElement(LogEvent lme)
lme
- the log event to be compared with
true
if they are equal, false
otherwisepublic boolean isInvisibleTask()
true
if this transition is an invisible task, false
otherwisepublic boolean isDuplicateTask()
findTransitions
will return multiple tasks being
associated to that log event.
true
if this transition is a duplicate task, false
otherwisepublic boolean equals(java.lang.Object o)
equals
in class ModelGraphVertex
o
- the Transition
to be compared with
true
if the identifiers of the transitions and the
identifiers of all input and output places are the same, false
otherwisepublic int hashCode()
hashCode
in class java.lang.Object
public java.lang.Object clone()
PetriNet.clone()
method will update the
reference correspondingly.
clone
in class att.grappa.Node
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |