Class PCMServices

    • Constructor Detail

      • PCMServices

        public PCMServices()
    • Method Detail

      • getStereotypeApplications

        public Collection<org.modelversioning.emfprofileapplication.StereotypeApplication> getStereotypeApplications​(EObject eObject)
        See Also:
        StereotypeAPI.getStereotypeApplications(EObject)
      • getATStereotypeApplications

        public Collection<org.modelversioning.emfprofileapplication.StereotypeApplication> getATStereotypeApplications​(EObject eObject)
        See Also:
        StereotypeAPI.getStereotypeApplications(EObject), ArchitecturalTemplateAPI.isArchitecturalTemplateStereotypeApplication(StereotypeApplication)
      • isRole

        public boolean isRole​(org.modelversioning.emfprofileapplication.StereotypeApplication stereotypeApplication)
        See Also:
        ArchitecturalTemplateAPI.isRole(Stereotype)
      • isSystemRole

        public boolean isSystemRole​(org.modelversioning.emfprofileapplication.StereotypeApplication stereotypeApplication)
        See Also:
        ArchitecturalTemplateAPI.isSystemRole(Stereotype)
      • setParameterValue

        public void setParameterValue​(EStructuralFeature parameter,
                                      EObject owningEObject,
                                      String valueLiteral)
        Sets the value of the EStructuralFeature on the given EObject to the parsed value literal.
        Parameters:
        parameter - the feature to set
        owningEObject - the object for which the feature will be set
        valueLiteral - the literal representing the new value
      • getParameters

        public Collection<EStructuralFeature> getParameters​(org.modelversioning.emfprofile.Stereotype stereotype)
        Returns the EStructuralFeatures that define the Stereotype`s parameters.
        Parameters:
        stereotype - the Stereotype
        Returns:
        the parameters` features
      • getRoleApplications

        public Collection<org.modelversioning.emfprofileapplication.StereotypeApplication> getRoleApplications​(EObject eObject)
        Returns the StereotypeApplications that define a Role -Application on the given EObject.
        Parameters:
        eObject - object to get roles for
        Returns:
        collection of role-StereotypeApplications
        See Also:
        ArchitecturalTemplateAPI.getRoleApplications(EObject)
      • getStereotypeApplicationsWithoutRoles

        public Collection<org.modelversioning.emfprofileapplication.StereotypeApplication> getStereotypeApplicationsWithoutRoles​(EObject eObject)
      • getATProfileImports

        public Collection<org.modelversioning.emfprofileapplication.ProfileImport> getATProfileImports​(EObject eObject)
        Returns the Profiles on the given EObject that are associated with architectural templates.
        Parameters:
        eObject - object to get profiles for
        Returns:
        collection of Profiles
        See Also:
        ArchitecturalTemplateAPI#getProfiles(EObject)
      • hasRoles

        public boolean hasRoles​(EObject object)
        Returns, whether the given StereotypableElement has roles applied.
        Parameters:
        object - object to test
        Returns:
        indicator for applied roles
      • editPCMRandomVariable

        public EObject editPCMRandomVariable​(EObject pcmRandomVariable,
                                             String expressionString)
        Sets the given string as a specification on the PCMRandomVariable . For this it first parses it to prevent any errors.
        Parameters:
        pcmRandomVariable - the random variable
        expression - the expression
        Returns:
        the random variable
      • getSemanticDiagram

        public org.eclipse.sirius.diagram.DSemanticDiagram getSemanticDiagram​(EObject containerView)
        Retrieves the top-most container view (i.e. the diagram element) from the specified container view. It does the job of getting the element referenced by the variable "diagram". This function should in fact be used when the variable "diagram" is not available.
        Parameters:
        containerView - the container view from which the top-most container is going to be retrieved
        Returns:
        the diagram element
      • copyEObject

        public EObject copyEObject​(EObject eObject)
        Copies an EObject
        Parameters:
        eObject - the EObject to be copied
        Returns:
        The copy
      • copyIdentifier

        public de.uka.ipd.sdq.identifier.Identifier copyIdentifier​(de.uka.ipd.sdq.identifier.Identifier eObject)
        Copies an Identifier and generates new IDs for it and all its contents
        Parameters:
        eObject - Identifier to be copied
        Returns:
        The copy