Marker Updaters

Identifier: org.eclipse.ui.markerUpdaters

Since: Release 1.0

Description: This extension point is used for registering marker update strategies with marker annotation models. A resource that is opened in a text editor is associated with a marker annotation model. For each marker attached to the resource this model manages a position that is updated with each change applied to the text in the editor. If the resource is saved, the text in the editor and the position managed for a marker are passed over to the registered marker update strategies. These strategies can then update the marker's attributes based on the text and the position. Marker update strategies are requested to implement the interface org.eclipse.ui.texteditor.IMarkerUpdater. The update strategies can be registered either for a particular marker type or all marker types. The latter by omitting any marker type in the extension.

Configuration Markup:

   <!ELEMENT extension (updater*)>

   <!ATTLIST extension
     point CDATA #REQUIRED
     id    CDATA #IMPLIED
     name  CDATA #IMPLIED
   >

   <!ELEMENT updater EMPTY>

   <!ATTLIST updater
     id         CDATA #REQUIRED
     markerType CDATA #IMPLIED
     class      CDATA #REQUIRED
   >

Examples:
<extension point= "org.eclipse.ui.markerUpdaters"> 
    <updater 
        id="org.eclipse.jdt.ui.markerUpdaters.JavaSearchMarkerUpdater" 
        class="org.eclipse.jdt.internal.ui.search.JavaSearchMarkerUpdater" 
        markerType="org.eclipse.search.searchmarker"> 
    </updater> 
</extension> 

This example registers org.eclipse.jdt.internal.ui.search.JavaSearchMarkerUpdater as a marker updater for all markers of the type org.eclipse.search.searchmarker including all its derived types.

<extension point= "org.eclipse.ui.markerUpdaters"> 
    <updater 
        id="org.eclipse.ui.texteditor.BasicMarkerUpdater" 
        class="org.eclipse.ui.texteditor.BasicMarkerUpdater"> 
    </updater> 
</extension> 

This example registers org.eclipse.ui.texteditor.BasicMarkerUpdater as a marker updater independent from the type of the marker.

API Information: Registered marker updaters have to implement the interface org.eclipse.ui.texteditor.IMarkerUpdater.

Copyright (c) 2000, 2003 IBM Corporation and others. All Rights Reserved.