Package org.jboss.weld.util.reflection
Class DeclaredMemberIndexer
java.lang.Object
org.jboss.weld.util.reflection.DeclaredMemberIndexer
- Author:
- Martin Kouba
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T> Constructor<T>getConstructorForIndex(int index, Class<T> declaringClass) static List<Constructor<?>>getDeclaredConstructors(Class<?> declaringClass) getDeclaredFields(Class<?> declaringClass) getDeclaredMethods(Class<?> declaringClass) static FieldgetFieldForIndex(int index, Class<?> declaringClass) static intgetIndexForConstructor(Constructor<?> constructor) static intgetIndexForField(Field field) static intgetIndexForMethod(Method method) static MethodgetMethodForIndex(int index, Class<?> declaringClass)
-
Method Details
-
getIndexForField
- Parameters:
field-- Returns:
- the index for the given field
-
getFieldForIndex
- Parameters:
index-declaringClass-- Returns:
- the declared field for the given index and declaring class
- Throws:
IndexOutOfBoundsException- if the index is out of range
-
getIndexForMethod
- Parameters:
method-- Returns:
- the index for the given method
-
getMethodForIndex
- Parameters:
index-declaringClass-- Returns:
- the declared method for the given index and declaring class
- Throws:
IndexOutOfBoundsException- if the index is out of range
-
getIndexForConstructor
- Parameters:
constructor-- Returns:
- the index for the given constructor
-
getConstructorForIndex
- Parameters:
index-declaringClass-- Returns:
- the declared constructor for the given index and declaring class
- Throws:
IndexOutOfBoundsException- if the index is out of range
-
getDeclaredFields
- Parameters:
declaringClass-- Returns:
- the ordered list of declared fields for the given class
-
getDeclaredMethods
- Parameters:
declaringClass-- Returns:
- the ordered list of declared methods for the given class
-
getDeclaredConstructors
- Parameters:
declaringClass-- Returns:
- the ordered list of declared constructors for the given class
-