Package edu.umd.cs.findbugs.gui2
Enum Sortables
- java.lang.Object
-
- java.lang.Enum<Sortables>
-
- edu.umd.cs.findbugs.gui2.Sortables
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<Sortables>
,java.util.Comparator<java.lang.String>
public enum Sortables extends java.lang.Enum<Sortables> implements java.util.Comparator<java.lang.String>
A useful enum for dealing with all the types of filterable and sortable data in BugInstances This is the preferred way for getting the information out of a BugInstance and formatting it for display It also has the comparators for the different types of data- Author:
- Reuven
-
-
Enum Constant Summary
Enum Constants Enum Constant Description BUG_RANK
BUG_STATUS
BUGCODE
CATEGORY
CLASS
CONSENSUS
DESIGNATION
DIVIDER
FIRST_SEEN
FIRSTVERSION
LASTVERSION
PACKAGE
PACKAGE_PREFIX
PRIORITY
PROJECT
TYPE
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description int
compare(java.lang.String one, java.lang.String two)
java.lang.String
formatValue(java.lang.String value)
java.lang.String[]
getAll()
java.lang.String[]
getAll(BugSet set)
java.lang.String[]
getAllSorted()
java.lang.String[]
getAllSorted(BugSet set)
java.util.Comparator<BugLeafNode>
getBugLeafNodeComparator()
SortableStringComparator
getComparator()
abstract java.lang.String
getFrom(BugInstance bug)
static Sortables
getSortableByPrettyName(java.lang.String name)
boolean
isAvailable(MainFrame frame)
java.lang.String
toString()
static Sortables
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static Sortables[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
FIRST_SEEN
public static final Sortables FIRST_SEEN
-
FIRSTVERSION
public static final Sortables FIRSTVERSION
-
LASTVERSION
public static final Sortables LASTVERSION
-
PRIORITY
public static final Sortables PRIORITY
-
CLASS
public static final Sortables CLASS
-
PACKAGE
public static final Sortables PACKAGE
-
PACKAGE_PREFIX
public static final Sortables PACKAGE_PREFIX
-
CATEGORY
public static final Sortables CATEGORY
-
DESIGNATION
public static final Sortables DESIGNATION
-
BUGCODE
public static final Sortables BUGCODE
-
TYPE
public static final Sortables TYPE
-
CONSENSUS
public static final Sortables CONSENSUS
-
BUG_RANK
public static final Sortables BUG_RANK
-
BUG_STATUS
public static final Sortables BUG_STATUS
-
PROJECT
public static final Sortables PROJECT
-
DIVIDER
public static final Sortables DIVIDER
-
-
Method Detail
-
values
public static Sortables[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Sortables c : Sortables.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Sortables valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Enum<Sortables>
-
getFrom
public abstract java.lang.String getFrom(BugInstance bug)
-
getAll
public java.lang.String[] getAll()
-
getAll
public java.lang.String[] getAll(BugSet set)
-
formatValue
public java.lang.String formatValue(java.lang.String value)
-
compare
public int compare(java.lang.String one, java.lang.String two)
- Specified by:
compare
in interfacejava.util.Comparator<java.lang.String>
-
getAllSorted
public java.lang.String[] getAllSorted()
-
getAllSorted
public java.lang.String[] getAllSorted(BugSet set)
-
getComparator
public SortableStringComparator getComparator()
-
getBugLeafNodeComparator
public java.util.Comparator<BugLeafNode> getBugLeafNodeComparator()
-
isAvailable
public boolean isAvailable(MainFrame frame)
-
getSortableByPrettyName
public static Sortables getSortableByPrettyName(java.lang.String name)
-
-