Class ParameterizedArc
- java.lang.Object
-
- org.processmining.models.graphbased.directed.petrinet.configurable.ConfigurableParameter<java.lang.Integer>
-
- org.processmining.models.graphbased.directed.petrinet.configurable.impl.ConfigurableParameterInteger
-
- org.processmining.models.graphbased.directed.petrinet.configurable.impl.ConfigurableIntegerFeature<T>
-
- org.processmining.models.graphbased.directed.petrinet.configurable.impl.ParameterizedIntegerFeature<Arc>
-
- org.processmining.models.graphbased.directed.petrinet.configurable.elements.ParameterizedArc
-
- All Implemented Interfaces:
ConfigurableFeature<Arc,java.lang.Integer>,ParameterizedFeature<ConfigurableParameter<java.lang.Integer>>
public class ParameterizedArc extends ParameterizedIntegerFeature<Arc>
Configurable arc to determine arc weights based on an expression.- Author:
- dfahland
-
-
Constructor Summary
Constructors Constructor Description ParameterizedArc(java.lang.String id, Arc element, java.lang.Integer min, java.lang.Integer max, java.lang.String expression, java.util.List<ConfigurableParameter<java.lang.Integer>> inputParameters)Create a new parameterized marking of this place.ParameterizedArc(Arc element, java.lang.Integer min, java.lang.Integer max, java.lang.String expression, java.util.List<ConfigurableParameter<java.lang.Integer>> inputParameters)Create a new parameterized marking of this place.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclearElementVisualization()Clear visual representation ofConfigurableFeature.getConfiguredElement()back to normalConfigurableFeature<Arc,java.lang.Integer>cloneFor(Arc newElement)Create a clone of this feature using newElement asConfigurableFeature.getConfiguredElement().voidexecuteConfiguration(ConfigurablePetrinet<? extends PetrinetGraph> parent)Set the weight of the configurable arc toParameterizedIntegerFeature.getValue()(if > 0) and remove arc from parent (if == 0)booleanisStillExecutable(ConfigurablePetrinet<? extends PetrinetGraph> parent)voidupdateElementVisualization()Change visual representation ofConfigurableFeature.getConfiguredElement()-
Methods inherited from class org.processmining.models.graphbased.directed.petrinet.configurable.impl.ParameterizedIntegerFeature
getExpression, getInputParameters, getInputParametersByName, getValue, setInputParameter, setValue, updateValue
-
Methods inherited from class org.processmining.models.graphbased.directed.petrinet.configurable.impl.ConfigurableIntegerFeature
getConfiguredElement, getId, getParameter
-
Methods inherited from class org.processmining.models.graphbased.directed.petrinet.configurable.impl.ConfigurableParameterInteger
isValidIntervalValue
-
Methods inherited from class org.processmining.models.graphbased.directed.petrinet.configurable.ConfigurableParameter
getDiscreteDomain, getIntervalMax, getIntervalMin, isIntervalDomain, isValidValue, setDiscreteDomain, setId, setIntervalDomain, updateParameter
-
-
-
-
Constructor Detail
-
ParameterizedArc
public ParameterizedArc(java.lang.String id, Arc element, java.lang.Integer min, java.lang.Integer max, java.lang.String expression, java.util.List<ConfigurableParameter<java.lang.Integer>> inputParameters) throws InvalidConfigurationException, de.congrace.exp4j.UnknownFunctionException, de.congrace.exp4j.UnparsableExpressionExceptionCreate a new parameterized marking of this place. The number of tokens on the place in the initial marking is computed from the given expression which contains the provided parameters with their default values. Values of variables may range between min and max.- Parameters:
id-element-min-max-expression-inputParameters-- Throws:
InvalidConfigurationExceptionde.congrace.exp4j.UnknownFunctionExceptionde.congrace.exp4j.UnparsableExpressionException
-
ParameterizedArc
public ParameterizedArc(Arc element, java.lang.Integer min, java.lang.Integer max, java.lang.String expression, java.util.List<ConfigurableParameter<java.lang.Integer>> inputParameters) throws InvalidConfigurationException, de.congrace.exp4j.UnknownFunctionException, de.congrace.exp4j.UnparsableExpressionException
Create a new parameterized marking of this place. The number of tokens on the place in the initial marking is computed from the given expression which contains the provided parameters with their default values. Values of variables may range between min and max.- Parameters:
element-min-max-expression-inputParameters-- Throws:
InvalidConfigurationExceptionde.congrace.exp4j.UnknownFunctionExceptionde.congrace.exp4j.UnparsableExpressionException
-
-
Method Detail
-
isStillExecutable
public boolean isStillExecutable(ConfigurablePetrinet<? extends PetrinetGraph> parent)
- Returns:
- true iff this configuration can be executed on the parent, e.g.
if
ConfigurableFeature.getConfiguredElement()is still an element of parent
-
executeConfiguration
public void executeConfiguration(ConfigurablePetrinet<? extends PetrinetGraph> parent)
Set the weight of the configurable arc toParameterizedIntegerFeature.getValue()(if > 0) and remove arc from parent (if == 0)- Specified by:
executeConfigurationin interfaceConfigurableFeature<Arc,java.lang.Integer>- Specified by:
executeConfigurationin classParameterizedIntegerFeature<Arc>- Parameters:
parent-- See Also:
ConfigurableFeature.executeConfiguration(org.processmining.models.graphbased.directed.petrinet.configurable.ConfigurablePetrinet)
-
cloneFor
public ConfigurableFeature<Arc,java.lang.Integer> cloneFor(Arc newElement) throws InvalidConfigurationException
Description copied from interface:ConfigurableFeatureCreate a clone of this feature using newElement asConfigurableFeature.getConfiguredElement().- Specified by:
cloneForin interfaceConfigurableFeature<Arc,java.lang.Integer>- Specified by:
cloneForin classParameterizedIntegerFeature<Arc>- Throws:
InvalidConfigurationException
-
updateElementVisualization
public void updateElementVisualization()
Description copied from interface:ConfigurableFeatureChange visual representation ofConfigurableFeature.getConfiguredElement()
-
clearElementVisualization
public void clearElementVisualization()
Description copied from interface:ConfigurableFeatureClear visual representation ofConfigurableFeature.getConfiguredElement()back to normal
-
-