public class QuickFixer extends Object implements IMarkerResolutionGenerator2
Modifier and Type | Field and Description |
---|---|
static IMarker[] |
EMPTY_MARKERS
Empty array of markers.
|
static IMarkerResolution[] |
EMPTY_RESOLUTIONS
Empty array of marker resolutions.
|
static String |
ID
The quick fixer ID.
|
Constructor and Description |
---|
QuickFixer() |
Modifier and Type | Method and Description |
---|---|
static IMarker[] |
findOtherMarkers(IQuickFixer fixer,
IMarker[] markers)
Iterate through the list of supplied markers.
|
static String |
getMarkerAttribute(String... fixerIDs)
Gets a list of quick-fixes for the marker attribute.
|
static Map<String,Object> |
getMarkerAttributes(IQuickFix[] fixers)
Gets the attributes required for quick-fixes when they consist of a instances of
IQuickFix . |
static Map<String,Object> |
getMarkerAttributes(IQuickFix[] fixers,
String[] fixerIDs)
Gets the attributes required for quick-fixes when they consist of a combination
of "static quick-fixes" using String IDs and instances of
IQuickFix . |
static Map<String,Object> |
getMarkerAttributes(String[] fixerIDs)
Gets the attributes required for quick-fixes when they consist of a combination
of "static quick-fixes" using String IDs and instances of
IQuickFix . |
IMarkerResolution[] |
getResolutions(IMarker marker)
Returns resolutions for the given marker (may be empty).
|
boolean |
hasResolutions(IMarker marker)
Returns whether there are any resolutions for the given marker.
|
static void |
register(String fixID,
IQuickFixer quickFixer)
Registers a quick fix with an ID.
|
public static final String ID
public static final IMarker[] EMPTY_MARKERS
public static final IMarkerResolution[] EMPTY_RESOLUTIONS
public static void register(String fixID, IQuickFixer quickFixer)
fixID
- The fix ID, unique.quickFixer
- The doer for quick-fixing.IllegalArgumentException
- If the fixID is registered.public static String getMarkerAttribute(String... fixerIDs)
fixerIDs
- The quick-fixer IDs.null
for no quick-fixes.public static Map<String,Object> getMarkerAttributes(String[] fixerIDs)
IQuickFix
.fixerIDs
- An array of static quick-fixer IDs.public static Map<String,Object> getMarkerAttributes(IQuickFix[] fixers)
IQuickFix
.fixers
- An array of quick-fixes instances.public static Map<String,Object> getMarkerAttributes(IQuickFix[] fixers, String[] fixerIDs)
IQuickFix
.fixers
- An array of quick-fixes instances.fixerIDs
- An array of static quick-fixer IDs.public static IMarker[] findOtherMarkers(IQuickFixer fixer, IMarker[] markers)
markers
- The array of markers.public IMarkerResolution[] getResolutions(IMarker marker)
getResolutions
in interface IMarkerResolutionGenerator
marker
- The marker.public boolean hasResolutions(IMarker marker)
hasResolutions
in interface IMarkerResolutionGenerator2
marker
- The marker.true
if there are resolutions for the given marker,
false
if not.iizi® is a registered trademark of Mindus SARL. © Copyright Mindus SARL, 2020. All rights reserved.