Class AddVSParticipant
java.lang.Object
org.eclipse.ui.views.markers.WorkbenchMarkerResolution
com.iizigo.quickfix.QuickFixAdapter
com.iizigo.quickfix.fixer.AddVSParticipant
- All Implemented Interfaces:
IQuickFix, IQuickFixer, IMarkerResolution, IMarkerResolution2
Fixes a VirtualSpace participant reference whose VirtualSpace does not list the participant by adding the missing entry to the VirtualSpace's participant list, the repair "Fix back-references" in the VirtualSpace reference editor performs. The reference itself is kept.
- Author:
- Christopher Mindus
Field Summary
FieldsConstructor Summary
ConstructorsModifierConstructorDescriptionConstructs the quick-fixer with default constructor for Eclipse.protectedAddVSParticipant(GProp<?> property) Creates a quick-fixer for the VirtualSpace reference property of a participant.Method Summary
Modifier and TypeMethodDescriptionstatic StringaddEntry(GProp<?> gp, IPropUndoRedo undoRedo) Adds the participant to the list of the VirtualSpace its reference names, as one operation of the undo history.Gets the attributes for the marker.getID()Returns the ID of the Quick Fixer.getLabel()Gets the label of the quick fixer.voidRuns this resolution.Methods inherited from class QuickFixAdapter
canBeGrouped, findOtherMarkers, getDescription, getImage, getMarker, isMarkerRequired, setMarkerMethods inherited from class WorkbenchMarkerResolution
run
Field Details
ID
Constructor Details
AddVSParticipant
public AddVSParticipant()Constructs the quick-fixer with default constructor for Eclipse.AddVSParticipant
Creates a quick-fixer for the VirtualSpace reference property of a participant.- Parameters:
property- The VirtualSpace reference property.
Method Details
getAttributes
Gets the attributes for the marker.- Specified by:
getAttributesin interfaceIQuickFix
run
Runs this resolution.- Specified by:
runin interfaceIMarkerResolution- Specified by:
runin interfaceIQuickFixer- Specified by:
runin classQuickFixAdapter- Parameters:
marker- the marker to resolve.
addEntry
Adds the participant to the list of the VirtualSpace its reference names, as one operation of the undo history. The reference is kept as it is.- Parameters:
gp- The VirtualSpace reference property of the participant.undoRedo- The undo/redo instance.- Returns:
- null for success, also when the list already had the entry, otherwise the error message.
getID
getLabel
Gets the label of the quick fixer.- Specified by:
getLabelin interfaceIMarkerResolution- Specified by:
getLabelin interfaceIQuickFixer- Specified by:
getLabelin classQuickFixAdapter- Returns:
- a short label for this resolution