net.sf.borg.ui.popup
Class ProjectReminderInstance

java.lang.Object
  extended by net.sf.borg.ui.popup.ReminderInstance
      extended by net.sf.borg.ui.popup.ProjectReminderInstance

public class ProjectReminderInstance
extends ReminderInstance

A Reminder Instance class that holds a Project


Constructor Summary
ProjectReminderInstance(Project project)
           
 
Method Summary
 String calculateToGoMessage()
          calculate the to go message for a reminder instance
 void do_todo(boolean delete)
          if the reminder instance is a todo, then mark it as done/complete
 boolean equals(Object obj)
           
 int getCurrentReminder()
          get the index of the active reminder for this instance - i.e.
 String getText()
          get the text for the reminder
 int hashCode()
           
 boolean isNote()
          return true if the reminder is a note (is untimed)
 boolean isTodo()
          return true if the reminder is a todo - either an appointment todo or another type of todo, such as a task
 boolean reloadAndCheckForChanges()
          reload the model entity from the db and check if it has changed.
 boolean shouldBeShown()
          determine if an appointment popup should be shown for an appointment that doesn't yet have a popup associated with it
 
Methods inherited from class net.sf.borg.ui.popup.ReminderInstance
dueForPopup, getInstanceTime, getRemindersShown, isHidden, markAsShown, minutesToGo, setHidden, setInstanceTime, setRemindersShown, setShown, wasEverShown
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProjectReminderInstance

public ProjectReminderInstance(Project project)
Parameters:
project -
Method Detail

do_todo

public void do_todo(boolean delete)
Description copied from class: ReminderInstance
if the reminder instance is a todo, then mark it as done/complete

Specified by:
do_todo in class ReminderInstance

equals

public boolean equals(Object obj)
Specified by:
equals in class ReminderInstance

getCurrentReminder

public int getCurrentReminder()
Description copied from class: ReminderInstance
get the index of the active reminder for this instance - i.e. latest one passed

Specified by:
getCurrentReminder in class ReminderInstance
Returns:
index of reminder or -1 if none

getText

public String getText()
Description copied from class: ReminderInstance
get the text for the reminder

Specified by:
getText in class ReminderInstance
Returns:
the reminder text

calculateToGoMessage

public String calculateToGoMessage()
Description copied from class: ReminderInstance
calculate the to go message for a reminder instance

Overrides:
calculateToGoMessage in class ReminderInstance
Returns:
the to go message or null if should not be shown

hashCode

public int hashCode()
Specified by:
hashCode in class ReminderInstance

isNote

public boolean isNote()
Description copied from class: ReminderInstance
return true if the reminder is a note (is untimed)

Specified by:
isNote in class ReminderInstance

isTodo

public boolean isTodo()
Description copied from class: ReminderInstance
return true if the reminder is a todo - either an appointment todo or another type of todo, such as a task

Specified by:
isTodo in class ReminderInstance

reloadAndCheckForChanges

public boolean reloadAndCheckForChanges()
Description copied from class: ReminderInstance
reload the model entity from the db and check if it has changed.

Specified by:
reloadAndCheckForChanges in class ReminderInstance
Returns:
true if the entity has changed in a way that affects reminders

shouldBeShown

public boolean shouldBeShown()
Description copied from class: ReminderInstance
determine if an appointment popup should be shown for an appointment that doesn't yet have a popup associated with it

Specified by:
shouldBeShown in class ReminderInstance
Returns:
true, if successful


Generated December 30 2011 by mbb using Apache Ant(TM) version 1.8.2 compiled on December 20 2010 and Java version 1.6.0_30 from Sun Microsystems Inc. on Linux i386 3.0.0-14-generic-pae