Class SourceCode.Element<T>
java.lang.Object
org.apache.openjpa.persistence.util.SourceCode.Element<T>
- All Implemented Interfaces:
Comparable<SourceCode.Element<T>>
- Direct Known Subclasses:
SourceCode.Class
,SourceCode.Constructor
,SourceCode.Field
,SourceCode.Method
- Enclosing class:
- SourceCode
public abstract class SourceCode.Element<T>
extends Object
implements Comparable<SourceCode.Element<T>>
Abstract element has a name, optional list of modifiers, annotations
and arguments.
-
Field Summary
Modifier and TypeFieldDescriptionprotected SourceCode.ACCESS
protected List<SourceCode.Annotation>
protected org.apache.openjpa.persistence.util.SourceCode.Comment
protected boolean
protected boolean
protected String
protected List<org.apache.openjpa.persistence.util.SourceCode.ClassName>
protected org.apache.openjpa.persistence.util.SourceCode.ClassName
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddComment
(boolean inline, String... lines) addParameter
(String param) int
compareTo
(SourceCode.Element<T> other) org.apache.openjpa.persistence.util.SourceCode.ClassName
getType()
void
write
(PrintWriter out, int tab)
-
Field Details
-
name
-
type
protected org.apache.openjpa.persistence.util.SourceCode.ClassName type -
access
-
isStatic
protected boolean isStatic -
isFinal
protected boolean isFinal -
comment
protected org.apache.openjpa.persistence.util.SourceCode.Comment comment -
params
-
annos
-
-
Constructor Details
-
Element
-
-
Method Details
-
getType
public org.apache.openjpa.persistence.util.SourceCode.ClassName getType() -
addAnnotation
-
addParameter
-
compareTo
- Specified by:
compareTo
in interfaceComparable<T>
-
addComment
-
makePublic
-
makeProtected
-
makePrivate
-
makeStatic
-
makeFinal
-
write
-