Class UniqueSetting


  • public class UniqueSetting
    extends java.lang.Object

    Convenience class for managing settings.

    Provides an equals method that returns true if the EObject and the EStructuralFeature are the same.

    Since:
    1.5
    Author:
    emueller
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      protected UniqueSetting​(org.eclipse.emf.ecore.EObject eObject, org.eclipse.emf.ecore.EStructuralFeature attribute)
      Constructor.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static UniqueSetting createSetting​(org.eclipse.emf.ecore.EObject eObject, org.eclipse.emf.ecore.EStructuralFeature attribute)
      Convenience method for creating a setting.
      static UniqueSetting createSetting​(org.eclipse.emf.ecore.EStructuralFeature.Setting setting)
      Convenience method for creating a setting.
      boolean equals​(java.lang.Object obj)
      org.eclipse.emf.ecore.EObject getEObject()
      Returns the EObject.
      org.eclipse.emf.ecore.EStructuralFeature getEStructuralFeature()
      Returns the EAttribute of the EObject.
      org.eclipse.emf.ecore.EStructuralFeature.Setting getSetting()
      Return the EStructuralFeature.Setting wrapped in this UniqueSetting.
      int hashCode()
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • UniqueSetting

        protected UniqueSetting​(org.eclipse.emf.ecore.EObject eObject,
                                org.eclipse.emf.ecore.EStructuralFeature attribute)
        Constructor.
        Parameters:
        eObject - an EObject
        attribute - an EAttribute of the given eObject
    • Method Detail

      • createSetting

        public static UniqueSetting createSetting​(org.eclipse.emf.ecore.EObject eObject,
                                                  org.eclipse.emf.ecore.EStructuralFeature attribute)
        Convenience method for creating a setting.
        Parameters:
        eObject - an EObject
        attribute - an EAttribute of the given eObject
        Returns:
        the constructed setting
      • createSetting

        public static UniqueSetting createSetting​(org.eclipse.emf.ecore.EStructuralFeature.Setting setting)
        Convenience method for creating a setting.
        Parameters:
        setting - the EStructuralFeature.Setting to wrap
        Returns:
        the constructed setting
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
        See Also:
        Object.hashCode()
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
        See Also:
        Object.equals(java.lang.Object)
      • getEObject

        public org.eclipse.emf.ecore.EObject getEObject()
        Returns the EObject.
        Returns:
        the EObject
      • getEStructuralFeature

        public org.eclipse.emf.ecore.EStructuralFeature getEStructuralFeature()
        Returns the EAttribute of the EObject.
        Returns:
        the EAttribute
      • getSetting

        public org.eclipse.emf.ecore.EStructuralFeature.Setting getSetting()
        Return the EStructuralFeature.Setting wrapped in this UniqueSetting.
        Returns:
        the wrapped EStructuralFeature.Setting
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object