Class PcmRepresentative<E extends org.palladiosimulator.pcm.core.entity.NamedElement>
java.lang.Object
org.palladiosimulator.protocom.traverse.framework.PcmRepresentative<E>
- Direct Known Subclasses:
XAllocation
,XBasicComponent
,XCollectionDataType
,XCompositeComponent
,XCompositeDataType
,XEventGroup
,XInfrastructureInterface
,XOperationInterface
,XRepository
,XResourceEnvironment
,XSystem
,XUsageScenario
public abstract class PcmRepresentative<E extends org.palladiosimulator.pcm.core.entity.NamedElement>
extends Object
Abstract class representing a generic PCM model entity. Includes methods to
further traverse the underlying PCM model.
Note that the generic type E extends NamedElement and not Entity. Due to some
(to me unknown) reasons an Allocation is a sub type of Entity, but a
ResourceEnvironment is not.
-
Field Summary
Modifier and TypeFieldDescriptionprotected List<CopiedFile>
protected E
The represented element of the loaded PCM model.protected List<GeneratedFile<? extends ICompilationUnit>>
List of all files to be generated.protected com.google.inject.Injector
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
generate()
Generate the files needed for this entity.Set the entity which will be represented by this object.void
Transformation process: Traverse through all relevant entities connected to this entity.protected void
traverse()
Traverse through the PCM model, following all relevant connections starting from the represented element.
-
Field Details
-
injector
@Inject protected com.google.inject.Injector injector -
generatedFiles
List of all files to be generated. -
copiedFiles
-
entity
The represented element of the loaded PCM model.
-
-
Constructor Details
-
PcmRepresentative
public PcmRepresentative()
-
-
Method Details
-
setEntity
Set the entity which will be represented by this object. -
transform
public void transform()Transformation process:- Traverse through all relevant entities connected to this entity.
- Generate files necessary for this entity, depending on the language and technology used.
- Store generated files.
-
traverse
protected void traverse()Traverse through the PCM model, following all relevant connections starting from the represented element. Nothing is traversed in the default case. -
generate
protected void generate()Generate the files needed for this entity. Nothing is generated in the default case.
-