|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.modello.plugin.java.javasource.JConstructor
public class JConstructor
A class for handling source code for a constructor of a JClass
Constructor Summary | |
---|---|
JConstructor(JClass declaringClass)
Creates a new method with the given name and returnType. |
Method Summary | |
---|---|
void |
addParameter(JParameter parameter)
Adds the given parameter to this Methods list of parameters |
void |
appendAnnotation(java.lang.String annotation)
|
JAnnotations |
getAnnotations()
|
JClass |
getDeclaringClass()
Returns the class in which this JMember has been declared |
JModifiers |
getModifiers()
Returns the modifiers for this JConstructor |
JParameter[] |
getParameters()
Returns an array of JParameters consisting of the parameters of this Method in declared order |
JSourceCode |
getSourceCode()
|
void |
print(JSourceWriter jsw)
|
void |
setAnnotations(JAnnotations annotations)
|
void |
setModifiers(JModifiers modifiers)
|
void |
setSourceCode(JSourceCode sourceCode)
|
void |
setSourceCode(java.lang.String sourceCode)
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public JConstructor(JClass declaringClass)
Method Detail |
---|
public void addParameter(JParameter parameter) throws java.lang.IllegalArgumentException
parameter
- the parameter to add to the this Methods
list of parameters.
java.lang.IllegalArgumentException
- when a parameter already
exists for this Method with the same name as the new parameterpublic JClass getDeclaringClass()
public JModifiers getModifiers()
public JParameter[] getParameters()
public JSourceCode getSourceCode()
public void print(JSourceWriter jsw)
public void setModifiers(JModifiers modifiers)
public void setSourceCode(java.lang.String sourceCode)
public void setSourceCode(JSourceCode sourceCode)
public java.lang.String toString()
toString
in class java.lang.Object
public JAnnotations getAnnotations()
public void appendAnnotation(java.lang.String annotation)
annotation
- the annotation to appendpublic void setAnnotations(JAnnotations annotations)
annotations
- the annotations to set
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |