org.jbpm.sim.def
Class LeavingTransitionProbabilityConfiguration

java.lang.Object
  extended by org.jbpm.sim.def.LeavingTransitionProbabilityConfiguration

public class LeavingTransitionProbabilityConfiguration
extends java.lang.Object

This class cares about the probabilities of outgoing transitions of a org.jbpm.graph.def.Node

Author:
bernd.ruecker@camunda.com

Constructor Summary
LeavingTransitionProbabilityConfiguration(Node node)
           
LeavingTransitionProbabilityConfiguration(Node node, Transition trans, double probability)
           
 
Method Summary
 void addTransition(Transition trans, double probability)
           
 desmoj.core.dist.Distribution createDistribution(desmoj.core.simulator.Model owner)
          create the distribution.
 Transition decideOutgoingTransition()
          now let the dices decide, which transition to take
 Node getNode()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LeavingTransitionProbabilityConfiguration

public LeavingTransitionProbabilityConfiguration(Node node)

LeavingTransitionProbabilityConfiguration

public LeavingTransitionProbabilityConfiguration(Node node,
                                                 Transition trans,
                                                 double probability)
Method Detail

addTransition

public void addTransition(Transition trans,
                          double probability)

createDistribution

public desmoj.core.dist.Distribution createDistribution(desmoj.core.simulator.Model owner)
create the distribution. Call this method AFTER all transitions are added, otherwise we get wrong probability sums we use an uniform distribution, because every value is equal probable now so the probability values configured on each transition refers to a "range" of samples. If the value is in these range, the transition is chosen. Every node gets a own distribution, to make them statistically independent

Returns:
the distribution used

decideOutgoingTransition

public Transition decideOutgoingTransition()
now let the dices decide, which transition to take

Returns:
the chosen transition

getNode

public Node getNode()


Copyright © 2010 JBoss Community. All Rights Reserved.