|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.enhydra.xml.xmlc.codegen.JavaMethod
Object that is used to assemble the Java source for a method.
Field Summary | |
protected int |
fModifiers
Modifiers of the method |
Constructor Summary | |
JavaMethod(String name,
String returnType,
int modifiers,
JavaParameter[] parameters,
String[] doc)
Constructor. |
Method Summary | |
JavaCode |
getCode()
Get the code object associate with the method body. |
int |
getModifiers()
Get the modifiers. |
String |
getName()
Get the name. |
String |
getReturnType()
Get the return type. |
void |
print(IndentWriter out,
boolean printBody)
Print the method. |
void |
printMethodSignature(IndentWriter out,
boolean beginBody)
Print the method signature. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected int fModifiers
Constructor Detail |
public JavaMethod(String name, String returnType, int modifiers, JavaParameter[] parameters, String[] doc)
returnType
- The type the method returns. Specify null for a
constructor.name
- The name of the method. If name is null, then this
creates a static initializer.parameters
- A array describing the parameters; null or empty if
no parameters.modifiers
- The method modifier bit set.doc
- The documentation to include. The parameter documentation
will be appended to this, so should not be repeated.
Each row of the array is a line of documentation.Method Detail |
public JavaCode getCode()
public String getName()
public String getReturnType()
public int getModifiers()
public void printMethodSignature(IndentWriter out, boolean beginBody)
out
- Write to this stream.beginBody
- If true, start a method body, otherwise end with
a semicolon.public void print(IndentWriter out, boolean printBody)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |