net.vidageek.mirror.reflect
Class DefaultAllReflectionHandler<T>

java.lang.Object
  extended by net.vidageek.mirror.reflect.DefaultAllReflectionHandler<T>
All Implemented Interfaces:
AllReflectionHandler<T>

public final class DefaultAllReflectionHandler<T>
extends Object
implements AllReflectionHandler<T>

This class is responsible for reflecting lists of reflection elements

Author:
jonasabreu

Constructor Summary
DefaultAllReflectionHandler(ReflectionProvider provider, Class<T> clazz)
           
 
Method Summary
 AllAnnotationsHandler annotations()
          Use this method to reflect all annotations on a AccessibleObject
 List<Annotation> annotationsMatching(Matcher<Annotation> matcher)
          Use this method to reflect all annotations on the wrapped AnnotatedElement that matches matcher.
 MirrorList<Constructor<T>> constructors()
          Use this method to reflect all constructors on the wrapped class
 List<Constructor<T>> constructorsMatching(Matcher<Constructor<T>> matcher)
          Use this method to reflect all constructors on the wrapped class that matches matcher.
 MirrorList<Field> fields()
          Use this method to reflect all fields on the wrapped class
 List<Field> fieldsMatching(Matcher<Field> matcher)
          Use this method to reflect all fields on the wrapped class that matches matcher.
 MirrorList<Method> getters()
          Use this method to reflect all getters that follow JavaBean convention
 MirrorList<Method> methods()
          Use this method to reflect all methods on the wrapped class
 List<Method> methodsMatching(Matcher<Method> matcher)
          Use this method to reflect all methods on the wrapped class that matches matcher.
 MirrorList<Method> setters()
          Use this method to reflect all setters that follow JavaBean convention
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultAllReflectionHandler

public DefaultAllReflectionHandler(ReflectionProvider provider,
                                   Class<T> clazz)
Method Detail

fields

public MirrorList<Field> fields()
Description copied from interface: AllReflectionHandler
Use this method to reflect all fields on the wrapped class

Specified by:
fields in interface AllReflectionHandler<T>
Returns:
The list of fields or an empty list if none was found.
See Also:
ClassReflectionProvider.reflectAllFields()

methods

public MirrorList<Method> methods()
Description copied from interface: AllReflectionHandler
Use this method to reflect all methods on the wrapped class

Specified by:
methods in interface AllReflectionHandler<T>
Returns:
The list of methods or an empty list if none was found.
See Also:
ClassReflectionProvider.reflectAllMethods()

constructors

public MirrorList<Constructor<T>> constructors()
Description copied from interface: AllReflectionHandler
Use this method to reflect all constructors on the wrapped class

Specified by:
constructors in interface AllReflectionHandler<T>
Returns:
The list of constructors or an empty list if none was found.
See Also:
ClassReflectionProvider.reflectAllConstructors()

annotations

public AllAnnotationsHandler annotations()
Description copied from interface: AllReflectionHandler
Use this method to reflect all annotations on a AccessibleObject

Specified by:
annotations in interface AllReflectionHandler<T>
Returns:
An object responsible for reflecting annotations.

setters

public MirrorList<Method> setters()
Description copied from interface: AllReflectionHandler
Use this method to reflect all setters that follow JavaBean convention

Specified by:
setters in interface AllReflectionHandler<T>
Returns:
A list of setter methods

getters

public MirrorList<Method> getters()
Description copied from interface: AllReflectionHandler
Use this method to reflect all getters that follow JavaBean convention

Specified by:
getters in interface AllReflectionHandler<T>
Returns:
A list of getter methods

fieldsMatching

public List<Field> fieldsMatching(Matcher<Field> matcher)
Description copied from interface: AllReflectionHandler
Use this method to reflect all fields on the wrapped class that matches matcher.

Specified by:
fieldsMatching in interface AllReflectionHandler<T>
Returns:
The list of fields or an empty list if none was accepted by the matcher.
See Also:
AllReflectionHandler.fields()

methodsMatching

public List<Method> methodsMatching(Matcher<Method> matcher)
Description copied from interface: AllReflectionHandler
Use this method to reflect all methods on the wrapped class that matches matcher.

Specified by:
methodsMatching in interface AllReflectionHandler<T>
Returns:
The list of methods or an empty list if none was accepted by the matcher.
See Also:
AllReflectionHandler.methods()

constructorsMatching

public List<Constructor<T>> constructorsMatching(Matcher<Constructor<T>> matcher)
Description copied from interface: AllReflectionHandler
Use this method to reflect all constructors on the wrapped class that matches matcher.

Specified by:
constructorsMatching in interface AllReflectionHandler<T>
Returns:
The list of constructors or an empty list if none was accepted by the matcher.
See Also:
AllReflectionHandler.constructors()

annotationsMatching

public List<Annotation> annotationsMatching(Matcher<Annotation> matcher)
Description copied from interface: AllReflectionHandler
Use this method to reflect all annotations on the wrapped AnnotatedElement that matches matcher.

Specified by:
annotationsMatching in interface AllReflectionHandler<T>
Returns:
The list of annotations or an empty list if none was accepted by the matcher.
See Also:
AllReflectionHandler.annotations()


Copyright © 2011 VidaGeek.net. All Rights Reserved.