@Documented @Retention(value=RUNTIME) @Target(value={TYPE,PACKAGE}) public @interface IndexSubclasses
During compilation ClassIndexProcessor
creates a resource files listing all classes
extending annotated class or located inside annotated package.
You can retrieve the list at runtime using either ClassIndex.getSubclasses(Class)
or ClassIndex.getPackageClasses(String)
.
For subclasses of the annotated class the resource file name is compatible with
what ServiceLoader
expects. So if all the subclasses have a zero-argument constructor
you can use ServiceLoader
. For subclasses of given package index file is named
"jaxb.index", it is located inside the package folder and it's format is compatible with
what JAXBContext.newInstance(String)
expects.
Modifier and Type | Optional Element and Description |
---|---|
boolean |
storeJavadoc
Specifies whether to store Javadoc for runtime retrieval.
|
public abstract boolean storeJavadoc
You can retrieve the stored Javadoc summary using ClassIndex.getClassSummary(Class)
.
Copyright © 2014 Atteo. All rights reserved.