FileDocCategorySizeDatePackage
AbstractAnnotationScanner.javaAPI DocGlassfish v2 API3458Fri May 04 22:31:34 BST 2007com.sun.enterprise.deployment.annotation.introspection

AbstractAnnotationScanner

public abstract class AbstractAnnotationScanner extends Object implements CustomAnnotationScanner
Abstract superclass for instance-based annotation scanners.
author
tjquinn

Fields Summary
protected Set
annotations
holds the annotations of interest to the specific type of scanner
Constructors Summary
public AbstractAnnotationScanner()
Creates a new instance of AbstractAnnotationScanner

    
           
      
    
Methods Summary
protected abstract voidinit(java.util.Set annotationsSet)
Invoked so the concrete subclass can populate the annotations set.

Concrete implementations of this method should add to the set one or more Strings corresponding to the annotations of interest.

param
annotationsSet the Set object to be populated

public booleanisAnnotation(java.lang.String value)
Test if the passed constant pool string is a reference to a Type.TYPE annotation of a J2EE component

String
the constant pool info string
return
true if it is an annotation reference of interest to this scanner

        if (annotations==null) {
            synchronized(this) {
                if (annotations == null) {
                    annotations = new HashSet();
                    init(annotations);
                }
            }
        }
        return annotations.contains(value);