|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--de.hunsicker.jalopy.language.DeclarationType
Represents a method type to distinguish between ordinary method names and those which adhere to the Java Bean naming conventions.
The default order for comparing is: ordinary Java method names, mutator,
accessor/tester. This can be changed via setOrder(java.lang.String)
.
Field Summary | |
static DeclarationType |
ANNOTATION
Represents an ANNOTATION declaration. |
static int |
ANNOTATION_INT
The bit value for annotations. |
static DeclarationType |
CLASS
Represents a class declaration. |
static int |
CLASS_INT
The bit value for classes. |
static DeclarationType |
CTOR
Represents a constructor declaration. |
static int |
CTOR_INT
The bit value for constructors. |
static DeclarationType |
ENUM
Represents an ENUM declaration. |
static int |
ENUM_INT
The bit value for enums. |
static DeclarationType |
INIT
Represents an instance initializer. |
static int |
INIT_INT
The bit value for instance initializers. |
static DeclarationType |
INTERFACE
Represents an interface declaration. |
static int |
INTERFACE_INT
The bit value for interfaces. |
static DeclarationType |
METHOD
Represents a method declaration. |
static int |
METHOD_INT
The bit value for methods. |
static int |
STATIC_VAR_INIT_INT
The bit value for static variables/initializers. |
static DeclarationType |
STATIC_VARIABLE_INIT
Represents a static variable declaration or initializer. |
static DeclarationType |
VARIABLE
Represents an instance variable declaration. |
static int |
VARIABLE_INT
The bit value for instance variables. |
Method Summary | |
int |
compareTo(java.lang.Object other)
Compares this object with the specified object for order. |
java.lang.String |
getDisplayName()
Returns the display name |
int |
getKey()
Returns the key |
java.lang.String |
getName()
Returns the name of this type. |
static java.lang.String |
getOrder()
Returns a string representation of the current sort order. |
static int |
getOrderSize()
|
static void |
setOrder(java.lang.String str)
Sets the order to use as the natural order. |
java.lang.String |
toString()
Returns a string representation of this method type. |
static DeclarationType |
valueOf(java.lang.String name)
Returns the declaration type of the given abreviation. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final int CLASS_INT
public static final int CTOR_INT
public static final int INIT_INT
public static final int INTERFACE_INT
public static final int METHOD_INT
public static final int ANNOTATION_INT
public static final int ENUM_INT
public static final int VARIABLE_INT
public static final int STATIC_VAR_INIT_INT
public static final DeclarationType CLASS
public static final DeclarationType ANNOTATION
public static final DeclarationType ENUM
public static final DeclarationType INTERFACE
public static final DeclarationType VARIABLE
public static final DeclarationType INIT
public static final DeclarationType CTOR
public static final DeclarationType METHOD
public static final DeclarationType STATIC_VARIABLE_INIT
Method Detail |
public java.lang.String getName()
public static void setOrder(java.lang.String str)
str
- a string representing the new order. The string must consist of exactly
four different, comma delimited strings which represents a method type.
java.lang.IllegalArgumentException
- if the given string is invalid.public static java.lang.String getOrder()
Variable,Initializer,Constructor,Method,Interface,Classor any combination thereof.
public static int getOrderSize()
public java.lang.String getDisplayName()
public int getKey()
public int compareTo(java.lang.Object other)
compareTo
in interface java.lang.Comparable
other
- the object to be compared.
java.lang.ClassCastException
- if the specified object's type prevents it from being
compared to this object.public java.lang.String toString()
toString
in class java.lang.Object
public static DeclarationType valueOf(java.lang.String name)
name
- a declaration identifier.
java.lang.IllegalArgumentException
- if no valid declaration identifier was given.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |