|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--attrib4j.cfparse.CFParseClassAnnotator
The CFParse implementation of a ClassAnnotator. This class will use the CFParse API to insert attributes into .class files.
| Constructor Summary | |
CFParseClassAnnotator(java.io.InputStream classFile)
Create the instance using an InputStream initialized to the class file that will be modified/annotated. |
|
| Method Summary | |
java.lang.Object |
createAttributeInstance(java.lang.String text,
java.net.URLClassLoader classLoader,
java.lang.String[] attributePackages)
Just added to avoid compilation error. |
void |
insertClassAttribute(java.lang.Object attribute)
Insert a custom class attribute into the bytecode. |
void |
insertFieldAttribute(java.lang.String field,
java.lang.Object attribute)
Insert a custom field attribute into the bytecode. |
void |
insertMethodAttribute(com.sun.javadoc.MethodDoc methodDoc,
java.lang.Object attribute)
Insert a custom method attribute into the bytecode. |
void |
write(java.lang.String destDir)
Write out the modified classfile. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public CFParseClassAnnotator(java.io.InputStream classFile)
throws AttributeException
AttributeException - if an error occurs| Method Detail |
public void insertClassAttribute(java.lang.Object attribute)
insertClassAttribute in interface ClassAnnotatorattribute - The attribute to be inserted.
public void insertFieldAttribute(java.lang.String field,
java.lang.Object attribute)
insertFieldAttribute in interface ClassAnnotatorfield - The name of the field to apply the attribute.attribute - The attribute to be inserted.
public void insertMethodAttribute(com.sun.javadoc.MethodDoc methodDoc,
java.lang.Object attribute)
insertMethodAttribute in interface ClassAnnotatormethodDoc - The Javadoc metadata class defining the method to
annotate.attribute - The attribute to be inserted.public void write(java.lang.String destDir)
write in interface ClassAnnotatordestDir - The directory where the modified class fiel should be
written.
public java.lang.Object createAttributeInstance(java.lang.String text,
java.net.URLClassLoader classLoader,
java.lang.String[] attributePackages)
createAttributeInstance in interface ClassAnnotatortext - The string describing the attribute.classLoader - The class loader user to resolve the attribute classattributePackages - The list of package names to prefix the attribute
search
ClassAnnotator.createAttributeInstance(java.lang.String, java.net.URLClassLoader, java.lang.String[])
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||