Package org.jibx.util
Interface IClassItem
- All Known Implementing Classes:
ClassItemSourceWrapper,ClassItemWrapper
public interface IClassItem
Interface for field or method information. Provides the information needed
for access to the item.
- Version:
- 1.0
- Author:
- Dennis M. Sosnoski
-
Method Summary
Modifier and TypeMethodDescriptionintGet access flags.intGet number of arguments for method.getArgumentType(int index) Get argument type as fully qualified class name.getExceptionJavaDoc(int index) Get method throws JavaDoc description, if available.String[]Get names of exceptions thrown by method.Get the generics signature information for item.Get item JavaDoc description, if available.getName()Get item name.Get owning class information.getParameterJavaDoc(int index) Get method parameter JavaDoc description, if available.getParameterName(int index) Get method parameter name, if available.Get return JavaDoc description for method, if available.Get field or method signature.Get item type as fully qualified class name.booleanCheck if item is an initializer.booleanisMethod()Check if item is a method.
-
Method Details
-
getOwningClass
IClass getOwningClass()Get owning class information.- Returns:
- owning class information
-
getName
String getName()Get item name.- Returns:
- item name
-
getJavaDoc
String getJavaDoc()Get item JavaDoc description, if available.- Returns:
- non-empty JavaDoc text (
nullif not available)
-
getTypeName
String getTypeName()Get item type as fully qualified class name.- Returns:
- item type name
-
getReturnJavaDoc
String getReturnJavaDoc()Get return JavaDoc description for method, if available.- Returns:
- non-empty JavaDoc text (
nullif not available)
-
getArgumentCount
int getArgumentCount()Get number of arguments for method.- Returns:
- argument count for method, or
-1if not a method
-
getArgumentType
Get argument type as fully qualified class name. This method will throw a runtime exception if called on a field.- Parameters:
index- argument number- Returns:
- argument type name
-
getParameterName
Get method parameter name, if available. This method will throw a runtime exception if called on a field.- Parameters:
index- parameter number- Returns:
- parameter name (
nullif not available)
-
getParameterJavaDoc
Get method parameter JavaDoc description, if available. This method will throw a runtime exception if called on a field.- Parameters:
index- parameter number- Returns:
- non-empty JavaDoc text (
nullif not available)
-
getAccessFlags
int getAccessFlags()Get access flags.- Returns:
- flags for access type of field or method
-
getSignature
String getSignature()Get field or method signature.- Returns:
- encoded method signature
-
isMethod
boolean isMethod()Check if item is a method.- Returns:
trueif a method,falseif a field
-
isInitializer
boolean isInitializer()Check if item is an initializer.- Returns:
trueif an initializer,falseif a field or normal method
-
getExceptions
String[] getExceptions()Get names of exceptions thrown by method.- Returns:
- array of exceptions thrown by method, or
nullif a field
-
getExceptionJavaDoc
Get method throws JavaDoc description, if available. This method will throw a runtime exception if called on a field.- Parameters:
index- exception index (into array returned bygetExceptions()- Returns:
- non-empty JavaDoc text (
nullif not available)
-
getGenericsSignature
String getGenericsSignature()Get the generics signature information for item.- Returns:
- generics signature (
nullif none)
-