Class ScenarioBehaviourCreator
- java.lang.Object
-
- org.palladiosimulator.generator.fluent.shared.structure.Entity
-
- org.palladiosimulator.generator.fluent.usagemodel.structure.UsageModelEntity
-
- org.palladiosimulator.generator.fluent.usagemodel.structure.components.ScenarioBehaviourCreator
-
public class ScenarioBehaviourCreator extends UsageModelEntity
This class constructs aScenario Behaviour
. It is used to create the 'Scenario Behaviour' object step-by-step, i.e. 'ScenarioBehaviourCreator' objects are of intermediate state.- See Also:
ScenarioBehaviour
-
-
Field Summary
-
Fields inherited from class org.palladiosimulator.generator.fluent.usagemodel.structure.UsageModelEntity
usageModelCreator
-
-
Constructor Summary
Constructors Constructor Description ScenarioBehaviourCreator(UsageModelCreator usgModelCreator)
Instantiates a new scenario behaviour creator.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ScenarioBehaviourCreator
addToScenarioBehaviour(ActionCreator action)
Adds anAbstract User Action
to the scenario behaviour.org.palladiosimulator.pcm.usagemodel.ScenarioBehaviour
build()
Turns the entity in the making into the finished entity.ScenarioBehaviourCreator
withName(String name)
Defines the unique name of this current entity.
-
-
-
Constructor Detail
-
ScenarioBehaviourCreator
public ScenarioBehaviourCreator(UsageModelCreator usgModelCreator)
Instantiates a new scenario behaviour creator.A ScenarioBehaviour specifies possible sequences of executing services provided by the system.It contains a set of AbstractUserActions, each referencing a predecessor and successor (except the first and last action), thereby forming a sequence of actions.See the AbstractAction documentation for why it is advantageous to model control flow in this way, as the same principle is used in the RDSEFF language.Concrete user actions of the usage model are:- Branch- Loop- EntryLevelSystemCall- Delay- Start- Stop So far, ScenarioBehaviours do not include forks in the user flow (i.e., splitting the flow with an AND semantic), as it is assumed that users always act sequentially. As there are no random variables depending on other variables in the usage model, there are no equivalent actions to GuardedBranchTransitions or CollectionIteratorActions
- Parameters:
usgModelCreator
- the usage model creator- See Also:
ScenarioBehaviour
-
-
Method Detail
-
addToScenarioBehaviour
public ScenarioBehaviourCreator addToScenarioBehaviour(ActionCreator action)
Adds anAbstract User Action
to the scenario behaviour.Concrete User Actions of the scenario behaviour are Branch, Delay, EntryLevelSystemCall, Loop, Start and Stop. Set connected user actions by using
ActionCreator.withSuccessor(ActionCreator)
. If a concrete start or end action is not added manually, it will be added as it's mandatory to the action chain.Create a new action by using the org.palladiosimulator.generator.fluent.usagemodel.factory, i.e.
create.newBranchAction()
.- Parameters:
action
- (or action chain) in the making- Returns:
- the scenario behaviour in the making
- See Also:
FluentUsageModelFactory.newBranchAction()
,FluentUsageModelFactory.newDelayAction(String)
,FluentUsageModelFactory.newEntryLevelSystemCall(org.palladiosimulator.pcm.repository.OperationProvidedRole, org.palladiosimulator.pcm.repository.OperationSignature)
,FluentUsageModelFactory.newLoopAction(String, ScenarioBehaviourCreator)
,FluentUsageModelFactory.newStartAction()
,FluentUsageModelFactory.newStopAction()
,AbstractUserAction
-
build
public org.palladiosimulator.pcm.usagemodel.ScenarioBehaviour build()
Description copied from class:Entity
Turns the entity in the making into the finished entity.
-
withName
public ScenarioBehaviourCreator withName(String name)
Description copied from class:Entity
Defines the unique name of this current entity. Once created entities are referenced by this name. Only entities with a unique name can be fetched from the model.
-
-