Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: add API documentation to interface JavaReflectionVisitor #1850

Merged
merged 1 commit into from
Feb 15, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -28,42 +28,65 @@
import java.lang.reflect.TypeVariable;
import java.lang.reflect.WildcardType;

/**
* Internal, package-visible interface for building shadow classes.
* Client code should not rely on it.
*/
interface JavaReflectionVisitor {
/** Visits a {@link java.lang.Package} */
void visitPackage(Package aPackage);

/** Visits a {@link java.lang.Class} */
<T> void visitClass(Class<T> clazz);

/** Visits a {@link java.lang.Class} representing an interface, see {@link Class#isInterface()} ()} */
<T> void visitInterface(Class<T> clazz);

/** Visits a {@link java.lang.Class} representing an enum, see {@link Class#isEnum()} */
<T> void visitEnum(Class<T> clazz);

/** Visits a {@link java.lang.Class} representing an enum, see {@link Class#isAnnotation()} */
<T extends Annotation> void visitAnnotationClass(Class<T> clazz);

/** Visits an {@link Annotation} instance */
void visitAnnotation(Annotation annotation);

/** Visits a {@link Constructor} */
<T> void visitConstructor(Constructor<T> constructor);

/** Visits a {@link RtMethod} (spoon wrapper) */
void visitMethod(RtMethod method);

/** Visits a {@link Field} */
void visitField(Field field);

/** Visits a {@link Field} from an enum */
void visitEnumValue(Field field);

/** Visits a {@link RtParameter} (spoon wrapper) */
void visitParameter(RtParameter parameter);

/** Visits a {@link TypeVariable} */
<T extends GenericDeclaration> void visitTypeParameter(TypeVariable<T> parameter);

/** Visits a {@link TypeVariable} */
<T extends GenericDeclaration> void visitTypeParameterReference(TypeVariable<T> parameter);

/** Visits a {@link Type} */
void visitType(Type type);

/** Visits a {@link ParameterizedType} */
void visitType(ParameterizedType type);

/** Visits a {@link WildcardType} */
void visitType(WildcardType type);

/** Visits a class as an array reference */
<T> void visitArrayReference(Class<T> typeArray);

/** Visits a class as a class reference */
<T> void visitClassReference(Class<T> clazz);

/** Visits a class as an interface reference */
<T> void visitInterfaceReference(Class<T> anInterface);
}