Class SourceCode.Method
- java.lang.Object
-
- org.apache.openjpa.persistence.util.SourceCode.Element<SourceCode.Method>
-
- org.apache.openjpa.persistence.util.SourceCode.Method
-
- All Implemented Interfaces:
java.lang.Comparable<SourceCode.Element<SourceCode.Method>>
- Enclosing class:
- SourceCode
public class SourceCode.Method extends SourceCode.Element<SourceCode.Method>
Represents Method declaration.
-
-
Constructor Summary
Constructors Constructor Description Method(java.lang.String name, org.apache.openjpa.persistence.util.SourceCode.ClassName returnType)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SourceCode.Method
addArgument(java.lang.String className, java.lang.String argName)
SourceCode.Method
addArgument(SourceCode.Argument<org.apache.openjpa.persistence.util.SourceCode.ClassName,java.lang.String> arg)
SourceCode.Method
addCodeLine(java.lang.String line)
SourceCode.Method
addCodeLine(java.lang.String line, boolean tabInc)
if tabInc = true, the current line, and all following lines will be tabbed.boolean
equals(java.lang.Object other)
SourceCode.Method
makeAbstract()
void
setTab(boolean inc)
java.lang.String
toString()
void
write(java.io.PrintWriter out, int tab)
-
Methods inherited from class org.apache.openjpa.persistence.util.SourceCode.Element
addAnnotation, addComment, addParameter, compareTo, getType, makeFinal, makePrivate, makeProtected, makePublic, makeStatic
-
-
-
-
Method Detail
-
addArgument
public SourceCode.Method addArgument(SourceCode.Argument<org.apache.openjpa.persistence.util.SourceCode.ClassName,java.lang.String> arg)
-
addArgument
public SourceCode.Method addArgument(java.lang.String className, java.lang.String argName)
-
setTab
public void setTab(boolean inc)
-
addCodeLine
public SourceCode.Method addCodeLine(java.lang.String line)
-
addCodeLine
public SourceCode.Method addCodeLine(java.lang.String line, boolean tabInc)
if tabInc = true, the current line, and all following lines will be tabbed. If false, a tab will be removed.
-
makeAbstract
public SourceCode.Method makeAbstract()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
write
public void write(java.io.PrintWriter out, int tab)
- Overrides:
write
in classSourceCode.Element<SourceCode.Method>
-
equals
public boolean equals(java.lang.Object other)
- Overrides:
equals
in classjava.lang.Object
-
-