Class DeleteProperty

  • All Implemented Interfaces:
    IQuickFix, IQuickFixer, org.eclipse.ui.IMarkerResolution, org.eclipse.ui.IMarkerResolution2

    public class DeleteProperty
    extends QuickFixAdapter
    implements IQuickFix
    Fixes a problem with the file name by deleting the property. This is typically used when a duplicate property has been created.
    Author:
    Christopher Mindus
    • Field Summary

      Fields 
      Modifier and TypeFieldDescription
      static java.lang.StringID
      The ID "DeleteProperty".
      protected GProp<?>property
      The property found, null if not found.
    • Constructor Summary

      Constructors 
      ModifierConstructorDescription
       DeleteProperty()
      Constructs the quick-fixer with default constructor for Eclipse.
      protectedDeleteProperty​(GProp<?> property)
      Creates a quick-fixer to go to the specified property.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and TypeMethodDescription
      java.util.Map<java.lang.String,​java.lang.Object>getAttributes()
      Gets the attributes for the marker.
      java.lang.StringgetID()
      Returns the ID of the Quick Fixer.
      java.lang.StringgetLabel()
      Gets the label of the quick fixer.
      voidrun​(org.eclipse.core.resources.IMarker marker)
      Runs this resolution.
      voidsetMarker​(org.eclipse.core.resources.IMarker marker)
      Call to set the marker in a new instance of the quick-fixer.
      • Methods inherited from class org.eclipse.ui.views.markers.WorkbenchMarkerResolution

        run
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • property

        protected GProp<?> property
        The property found, null if not found.
    • Constructor Detail

      • DeleteProperty

        public DeleteProperty()
        Constructs the quick-fixer with default constructor for Eclipse.
      • DeleteProperty

        protected DeleteProperty​(GProp<?> property)
        Creates a quick-fixer to go to the specified property.
        Parameters:
        property - The property to go to.
    • Method Detail

      • getAttributes

        public java.util.Map<java.lang.String,​java.lang.Object> getAttributes()
        Gets the attributes for the marker.
        Specified by:
        getAttributes in interface IQuickFix
      • run

        public void run​(org.eclipse.core.resources.IMarker marker)
        Runs this resolution.
        Specified by:
        run in interface org.eclipse.ui.IMarkerResolution
        Specified by:
        run in interface IQuickFixer
        Specified by:
        run in class QuickFixAdapter
        Parameters:
        marker - the marker to resolve.
      • setMarker

        public void setMarker​(org.eclipse.core.resources.IMarker marker)
        Call to set the marker in a new instance of the quick-fixer.
        Specified by:
        setMarker in interface IQuickFixer
        Overrides:
        setMarker in class QuickFixAdapter
        Parameters:
        marker - The marker.
      • getID

        public java.lang.String getID()
        Returns the ID of the Quick Fixer.
        Specified by:
        getID in interface IQuickFix
      • getLabel

        public java.lang.String getLabel()
        Gets the label of the quick fixer.
        Specified by:
        getLabel in interface org.eclipse.ui.IMarkerResolution
        Specified by:
        getLabel in interface IQuickFixer
        Specified by:
        getLabel in class QuickFixAdapter
        Returns:
        a short label for this resolution