org.codehaus.annogen.override
Interface AnnoOverrider

All Known Subinterfaces:
StoredAnnoOverrider

public interface AnnoOverrider

Modifes the annotations which apply to some annotated java element. AnnoOverrider is essentially a callback mechanism - it is consulted when an AnnnoViewer receives requests to view the annotations on a particular element. This model was chosen in the interests of efficiency, since the overrider doesn't have to worry about whether it's wasting time overriding annotations that will never be used anyway.

However, the callback approach can be ungainly, in the information you need to override annotations may not be readily available to you when it comes time to view the annotations. To help with this problem, see the StoredAnnoOverrider, which lets you determine your annotation overrides in a single pass and store them for later use in the View phase.

Author:
Patrick Calahan <email: codehaus-at-bea-dot-com>

Method Summary
 void init(AnnoContext pc)
          Provides the Populator with a context object to access various services such as logging.
 void modifyAnnos(ElementId id, AnnoBeanSet currentAnnos)
          Called to give this Overrider a chance to modify the annotations which apply to a given element.
 

Method Detail

init

void init(AnnoContext pc)

Provides the Populator with a context object to access various services such as logging. For a given instance, this method is guranteed to be called exactly once and before any other methods in this interface.


modifyAnnos

void modifyAnnos(ElementId id,
                 AnnoBeanSet currentAnnos)

Called to give this Overrider a chance to modify the annotations which apply to a given element.

Parameters:
id - Element to which the annotations apply.
currentAnnos - Currently viewed annotations.