org.jboss.metadata.annotation
Class AnnotationMatcher

java.lang.Object
  extended by org.jboss.metadata.annotation.AnnotationMatcher

public final class AnnotationMatcher
extends Object

AnnotationMatcher.

Version:
$Revision: 57133 $
Author:
Adrian Brock

Constructor Summary
AnnotationMatcher()
           
 
Method Summary
static
<T extends Annotation>
T
matchAnnotation(Annotation[] annotations, Class<T> annotationType)
          Match an annotation
static
<T extends Annotation>
AnnotationItem<T>
matchAnnotationItem(AnnotationItem[] annotations, Class<T> annotationType)
          Match an annotation item
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AnnotationMatcher

public AnnotationMatcher()
Method Detail

matchAnnotation

public static final <T extends Annotation> T matchAnnotation(Annotation[] annotations,
                                                             Class<T> annotationType)
Match an annotation

Type Parameters:
T - the annotation type
Parameters:
annotations - the annotations
annotationType - the annotation type
Returns:
the matched annotation or null if no match

matchAnnotationItem

public static final <T extends Annotation> AnnotationItem<T> matchAnnotationItem(AnnotationItem[] annotations,
                                                                                 Class<T> annotationType)
Match an annotation item

Type Parameters:
T - the annotation type
Parameters:
annotations - the annotation items
annotationType - the annotation type
Returns:
the matched annotation item or null if no match


Copyright © 2011 JBoss, a division of Red Hat, Inc.. All Rights Reserved.