Class JavadocClassBuilder
- java.lang.Object
-
- org.apache.xmlbeans.impl.jam.provider.JamClassBuilder
-
- org.apache.xmlbeans.impl.jam.internal.javadoc.JavadocClassBuilder
-
- All Implemented Interfaces:
JamClassPopulator
public class JavadocClassBuilder extends JamClassBuilder implements JamClassPopulator
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringARGS_PROPERTYstatic java.lang.StringPARSETAGS_PROPERTY
-
Constructor Summary
Constructors Constructor Description JavadocClassBuilder()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description MMethodaddMethod(MClass dest, com.sun.javadoc.MethodDoc doc)static voidaddSourcePosition(MElement dest, com.sun.javadoc.Doc src)static voidaddSourcePosition(MElement dest, com.sun.javadoc.SourcePosition pos)MClassbuild(java.lang.String packageName, java.lang.String className)This is called by JAM when it attempts to load a class.static java.lang.StringgetFdFor(com.sun.javadoc.Type t)Returns a classfile-style field descriptor for the given type.voidinit(ElementContext ctx)This method is called by JAM to initialize this class builder.voidpopulate(MClass dest)Called by JAM to 'fill out' an instance of a given MClass with things like methods and fields.
-
-
-
Field Detail
-
ARGS_PROPERTY
public static final java.lang.String ARGS_PROPERTY
- See Also:
- Constant Field Values
-
PARSETAGS_PROPERTY
public static final java.lang.String PARSETAGS_PROPERTY
- See Also:
- Constant Field Values
-
-
Method Detail
-
init
public void init(ElementContext ctx)
Description copied from class:JamClassBuilderThis method is called by JAM to initialize this class builder. Extending classes can override this to perform additional initialization work (just remember to call super.init()!).- Overrides:
initin classJamClassBuilder
-
build
public MClass build(java.lang.String packageName, java.lang.String className)
Description copied from class:JamClassBuilderThis is called by JAM when it attempts to load a class. If the builder has access to an artifact (typically a java source or classfile) that represents the given type, it should call createClassToBuild() to get a new instance of MClass and then return it. No caching should be performed - if an MClass is going to be returned, it should be a new instance returned by createClassToBuild()
If no artififact is available, the builder should just return null, signalling that other JamClassBuilders should attempt to build the class.
- Specified by:
buildin classJamClassBuilder- Returns:
-
populate
public void populate(MClass dest)
Description copied from interface:JamClassPopulatorCalled by JAM to 'fill out' an instance of a given MClass with things like methods and fields. The implementing builder is responsible for inspecting the source artifact (typically a source or class file) to call the appropriate createX methods on the given MClass.
- Specified by:
populatein interfaceJamClassPopulator
-
getFdFor
public static java.lang.String getFdFor(com.sun.javadoc.Type t)
Returns a classfile-style field descriptor for the given type. This has to be called to get a name for a javadoc type that can be used with Class.forName(), JRootContext.getClass(), or JClass.forName().
-
addSourcePosition
public static void addSourcePosition(MElement dest, com.sun.javadoc.Doc src)
-
addSourcePosition
public static void addSourcePosition(MElement dest, com.sun.javadoc.SourcePosition pos)
-
-