Package org.deckfour.xes.extension.std
Class XLifecycleExtension
- java.lang.Object
-
- org.deckfour.xes.extension.XExtension
-
- org.deckfour.xes.extension.std.XLifecycleExtension
-
- All Implemented Interfaces:
java.io.Serializable
public class XLifecycleExtension extends XExtension
Extension defining additional attributes for the event lifecycle. Lifecycles define a set of states for activities, with an accompanying set of transitions between those states. Any event which is referring to by a lifecycle represents a certain transition of an activity within that lifecycle.- Author:
- Christian W. Guenther (christian@deckfour.org)
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classXLifecycleExtension.StandardModelEnumeration for the standard lifecycle model.
-
Field Summary
Fields Modifier and Type Field Description static XAttributeLiteralATTR_MODELLifecycle model attribute prototypestatic XAttributeLiteralATTR_TRANSITIONTransition attribute prototypestatic java.net.URIEXTENSION_URIThe unique URI of this extension.static java.lang.StringKEY_MODELKey for the lifecycle model attribute.static java.lang.StringKEY_TRANSITIONKey for the transition attribute.static java.lang.StringVALUE_MODEL_STANDARDValue for the lifecycle model attribute referring to the standard model.-
Fields inherited from class org.deckfour.xes.extension.XExtension
allAttributes, eventAttributes, logAttributes, metaAttributes, name, prefix, traceAttributes, uri
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidassignModel(XLog log, java.lang.String model)Assigns a value for the lifecycle model identifier to a given log.voidassignStandardTransition(XEvent event, XLifecycleExtension.StandardModel transition)Assigns a standard lifecycle transition to the given event.voidassignTransition(XEvent event, java.lang.String transition)Assigns a lifecycle transition string to the given event.java.lang.StringextractModel(XLog log)Extracts the lifecycle model identifier from a given log.XLifecycleExtension.StandardModelextractStandardTransition(XEvent event)Extracts the standard lifecycle transition object from a given event.java.lang.StringextractTransition(XEvent event)Extracts the lifecycle transition string from a given event.static XLifecycleExtensioninstance()Provides static access to the singleton instance of this extension.booleanusesStandardModel(XLog log)Checks, whether a given log uses the standard model for lifecycle transitions.-
Methods inherited from class org.deckfour.xes.extension.XExtension
accept, equals, getDefinedAttributes, getEventAttributes, getLogAttributes, getMetaAttributes, getName, getPrefix, getTraceAttributes, getUri, hashCode, toString
-
-
-
-
Field Detail
-
EXTENSION_URI
public static final java.net.URI EXTENSION_URI
The unique URI of this extension.
-
KEY_MODEL
public static final java.lang.String KEY_MODEL
Key for the lifecycle model attribute.- See Also:
- Constant Field Values
-
KEY_TRANSITION
public static final java.lang.String KEY_TRANSITION
Key for the transition attribute.- See Also:
- Constant Field Values
-
VALUE_MODEL_STANDARD
public static final java.lang.String VALUE_MODEL_STANDARD
Value for the lifecycle model attribute referring to the standard model.- See Also:
- Constant Field Values
-
ATTR_MODEL
public static XAttributeLiteral ATTR_MODEL
Lifecycle model attribute prototype
-
ATTR_TRANSITION
public static XAttributeLiteral ATTR_TRANSITION
Transition attribute prototype
-
-
Method Detail
-
instance
public static XLifecycleExtension instance()
Provides static access to the singleton instance of this extension.- Returns:
- Singleton instance.
-
extractModel
public java.lang.String extractModel(XLog log)
Extracts the lifecycle model identifier from a given log.- Parameters:
log- Event log.- Returns:
- Lifecycle model identifier string.
-
assignModel
public void assignModel(XLog log, java.lang.String model)
Assigns a value for the lifecycle model identifier to a given log.- Parameters:
log- Log to be tagged.model- Lifecycle model identifier string to be used.
-
usesStandardModel
public boolean usesStandardModel(XLog log)
Checks, whether a given log uses the standard model for lifecycle transitions.- Parameters:
log- Log to be checked.- Returns:
- Returns true, if the log indeed uses the standard lifecycle model.
-
extractTransition
public java.lang.String extractTransition(XEvent event)
Extracts the lifecycle transition string from a given event.- Parameters:
event- An event.- Returns:
- The lifecycle transition string of this event. Can be
null, if not defined.
-
extractStandardTransition
public XLifecycleExtension.StandardModel extractStandardTransition(XEvent event)
Extracts the standard lifecycle transition object from a given event.- Parameters:
event- An event.- Returns:
- The standard lifecycle transition instance of this event. Can be
null, if not defined.
-
assignTransition
public void assignTransition(XEvent event, java.lang.String transition)
Assigns a lifecycle transition string to the given event.- Parameters:
event- Event to be tagged.transition- Lifecycle transition string to be assigned.
-
assignStandardTransition
public void assignStandardTransition(XEvent event, XLifecycleExtension.StandardModel transition)
Assigns a standard lifecycle transition to the given event.- Parameters:
event- Event to be tagged.transition- Standard lifecycle transition to be assigned.
-
-