Interface ObjectMapping


  • public interface ObjectMapping
    Provides information related to the traceability between an input element and its corresponding output elements.

    An input element is usually transformed into one output element, known here as its primary corresponding element. The primary corresponding element is notably used by the ReferenceManager to build references in the output model.

    The input element might also generate additional elements in the output model (e.g. UML dependencies), known here as secondary elements.

    Information stored in ObjectMapping instances is also used to build traceability matrices in the main operation log.

    This interface is not intended to be implemented by clients.

    Since:
    3.6.0
    See Also:
    MappingFunction.getMapping(EObject), Mapping.getMapping(EObject), ReferenceManager
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      org.eclipse.emf.ecore.EObject getInput()
      Returns the input element.
      org.eclipse.emf.ecore.EObject getPrimary()
      Returns the primary output element corresponding to the underlying input element, if any.
      List<org.eclipse.emf.ecore.EObject> getSecondary()
      Returns a modifiable list of known secondary output elements corresponding to the underlying input element.
      void setPrimary​(org.eclipse.emf.ecore.EObject output)
      Associates an output element to the underlying input element.
    • Method Detail

      • getInput

        org.eclipse.emf.ecore.EObject getInput()
        Returns the input element.
        Returns:
        the input element.
      • getPrimary

        org.eclipse.emf.ecore.EObject getPrimary()
        Returns the primary output element corresponding to the underlying input element, if any.
        Returns:
        the primary output element corresponding to the underlying input element, or null if no output element is associated.
        See Also:
        setPrimary(EObject)
      • setPrimary

        void setPrimary​(org.eclipse.emf.ecore.EObject output)
        Associates an output element to the underlying input element.

        The primary element is used by the ReferenceManager to build references in the output model.

        Parameters:
        output - the element part of the output model corresponding to the underlying input element.
        See Also:
        ReferenceManager
      • getSecondary

        List<org.eclipse.emf.ecore.EObject> getSecondary()
        Returns a modifiable list of known secondary output elements corresponding to the underlying input element. The caller might add or remove secondary elements directly from the returned list.
        Returns:
        a modifiable list of known secondary output elements corresponding to the underlying input element.