Class StringAttributeChangeAccessor

    • Constructor Detail

      • StringAttributeChangeAccessor

        public StringAttributeChangeAccessor​(EObject eObject,
                                             AttributeChange attributeChange)
        Creates a new accessor for the given eObject and eAttribute.
        Parameters:
        eObject - The EObject to get the value of the EAttribute from.
        attributeChange - The attribute change to get the attribute Eattribute from.
    • Method Detail

      • getContents

        public InputStream getContents()
                                throws org.eclipse.core.runtime.CoreException
        Returns an open InputStream for this object which can be used to retrieve the object's content. The client is responsible for closing the stream when finished. Returns null if this object has no streamable contents.
        Specified by:
        getContents in interface IStreamContentAccessor
        Returns:
        an input stream containing the contents of this object
        Throws:
        org.eclipse.core.runtime.CoreException - if the contents of this object could not be accessed
        See Also:
        IStreamContentAccessor.getContents()
      • getEObject

        protected final EObject getEObject()
        Returns the EObject to get the value of the EAttribute from.
        Returns:
        the EObject to get the value of the EAttribute from.
      • getEAtribute

        protected final EAttribute getEAtribute()
        Returns the EAttribute to retrieve from the wrapped EObject.
        Returns:
        the EAttribute to retrieve from the wrapped EObject.
      • getImage

        public org.eclipse.swt.graphics.Image getImage()
        Returns an image for this object. This image is used when displaying this object in the UI.
        Specified by:
        getImage in interface ITypedElement
        Returns:
        the image of this object or null if this type of input has no image
        See Also:
        ITypedElement.getImage()
      • getType

        public String getType()
        Returns the type of this object. For objects with a file name this is typically the file extension. For folders its the constant FOLDER_TYPE. The type is used for determining a suitable viewer for this object.
        Specified by:
        getType in interface ITypedElement
        Returns:
        the type of this object
        See Also:
        ITypedElement.getType()