|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.schmant.task.tp.taskref.TaskCategory
public class TaskCategory
This is an immutable object representing a task category. It contains a name, a descriptive text and an abbreviation. The abbreviation for each task category must be unique.
This object is Comparable
with other TaskCategory
objects. It
compares the task category names.
Constructor Summary | |
---|---|
TaskCategory(String name,
String abbreviation,
String description)
|
Method Summary | |
---|---|
int |
compareTo(TaskCategory tc)
This compares the category's name, making it easy to sort categories in alphabetical order. |
boolean |
equals(Object o)
Two task categories are equal if they have the same abbreviations. |
String |
getAbbreviation()
Get the task's abbreviation. |
String |
getDescription()
Get a descriptive text for the task. |
String |
getName()
Get the category's name. |
int |
hashCode()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TaskCategory(String name, String abbreviation, String description)
Method Detail |
---|
public String getName()
public String getAbbreviation()
public String getDescription()
public int compareTo(TaskCategory tc)
compareTo
in interface Comparable<TaskCategory>
public boolean equals(Object o)
equals
in class Object
public int hashCode()
hashCode
in class Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |