|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.chorem.jtimer.entities.TimerTask
public class TimerTask
Represents a task. This task is cloneable using SerializationUtils (commons-lang).
SerializationUtils,
Serialized Form| Field Summary | |
|---|---|
protected SortedMap<Date,Long> |
allDaysAndTimes
Map calendar of day -> time. |
protected SortedMap<Date,String> |
allDaysAnnotations
Map date -> annotation text. |
protected boolean |
closed
Closed task. |
protected Date |
creationDate
Creation date. |
protected String |
name
Task name. |
protected int |
number
Task number. |
protected TimerTask |
parent
Parent Task. |
protected List<TimerTask> |
subTasks
Sub tasks. |
| Constructor Summary | |
|---|---|
TimerTask()
Constructor. |
|
TimerTask(String name)
Constructor with name. |
|
| Method Summary | |
|---|---|
void |
addAnnotation(Date date,
String note)
Add annotation. |
boolean |
addTask(TimerTask t)
Add task's subtask. |
TimerTask |
clone()
Clone task. |
int |
compareTo(TimerTask o)
|
boolean |
equals(Object o)
|
SortedMap<Date,Long> |
getAllDaysAndTimes()
Return all data. |
SortedMap<Date,String> |
getAllDaysAnnotations()
Return all annotation, sorted on date. |
Date |
getCreationDate()
Get task creation date. |
String |
getName()
Get task name. |
int |
getNumber()
Get task number. |
TimerTask |
getParent()
Get parent. |
List<TimerTask> |
getSubTasks()
Get task's subtasks. |
long |
getTime(Date date)
Get time at date. |
boolean |
isClosed()
Get closed task state. |
void |
setClosed(boolean closed)
Set closed. |
void |
setCreationDate(Date creationDate)
Set task creation date. |
void |
setName(String name)
Set task name. |
void |
setNumber(int number)
Set task number. |
protected void |
setParent(TimerTask parent)
Set parent. |
void |
setTime(Date date,
Long seconds)
Add time. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected int number
protected String name
protected Date creationDate
protected boolean closed
protected SortedMap<Date,Long> allDaysAndTimes
protected SortedMap<Date,String> allDaysAnnotations
protected TimerTask parent
protected List<TimerTask> subTasks
| Constructor Detail |
|---|
public TimerTask()
public TimerTask(String name)
name - task name| Method Detail |
|---|
public int getNumber()
public void setNumber(int number)
number - the number to setpublic String getName()
public void setName(String name)
name - the name to setpublic Date getCreationDate()
public void setCreationDate(Date creationDate)
creationDate - creation datepublic boolean isClosed()
public void setClosed(boolean closed)
closed - closedpublic List<TimerTask> getSubTasks()
public boolean addTask(TimerTask t)
t - the task to add
public void setTime(Date date,
Long seconds)
date - dateseconds - secondspublic long getTime(Date date)
date - date
public SortedMap<Date,Long> getAllDaysAndTimes()
public void addAnnotation(Date date,
String note)
date - datenote - note textpublic SortedMap<Date,String> getAllDaysAnnotations()
public TimerTask getParent()
protected void setParent(TimerTask parent)
parent - the parent to setpublic String toString()
toString in class Objectpublic boolean equals(Object o)
equals in class Objectpublic TimerTask clone()
clone in class Objectpublic int compareTo(TimerTask o)
compareTo in interface Comparable<TimerTask>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||