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 Details

    • injector

      @Inject protected com.google.inject.Injector injector
    • generatedFiles

      protected List<GeneratedFile<? extends ICompilationUnit>> generatedFiles
      List of all files to be generated.
    • copiedFiles

      protected List<CopiedFile> copiedFiles
    • entity

      protected E extends org.palladiosimulator.pcm.core.entity.NamedElement entity
      The represented element of the loaded PCM model.
  • Constructor Details

    • PcmRepresentative

      public PcmRepresentative()
  • Method Details

    • setEntity

      public PcmRepresentative<E> setEntity(E entity)
      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 and Generate are template methods.
    • 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.