|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.pronoic.cos.client.AbstractClientApp | +--org.davesag.tasktracker.client.ClientApp
This is a client aplication for entering and maintaining tasks. It is very simple and does not do any username/password authentication etc.
It is currently unfinished. Only task creation and listing is written so far.
TaskTrackerEntry
Field Summary | |
static String |
BUDDY_LIST_NAME
Constant list name for the list of users buddy names |
static String |
CATEGORY_LIST_NAME
Constant list name for the global list of categories |
Color |
mBackgroundColour
the background colour for panels in this application |
PropertyChangeSupport |
mBuddyListPCS
property change support for list of user's buddies |
PropertyChangeSupport |
mCategoriesPCS
property change support for list of categories |
Vector |
mCategoryCache
The local cache for the list of categories |
String |
mCaution
a caution message that fires a property change event if changed, allowing listeners to display cautions accordingly. |
PropertyChangeSupport |
mCautioner
property change support for cautioner |
Font |
mDisplayFont
the diaplay font for panels in this application |
Color |
mDisplayTextColour
the display text colour for panels in this application |
Vector |
mProjectCache
The local cache for the list of projects |
PropertyChangeSupport |
mProjectsPCS
property change support for list of projects |
Vector |
mTasksImWorkingOnCache
The local cache of tasks user is working on. |
PropertyChangeSupport |
mTasksImWorkingOnPCS
property change support for list of tasks user is working on |
Vector |
mTasksIReportedCache
The local cache of tasks user reported. |
PropertyChangeSupport |
mTasksIReportedPCS
property change support for list of tasks user reported |
Color |
mTitleColour
the title colour for panels in this application |
String |
mUser
the name of the logged in user. |
Vector |
mUserBuddiesCache
The local cache of user's buddies. |
static String |
PROJECT_LIST_NAME
Constant list name for the global list of projects |
static String |
TASKS_I_REPORTED
Constant list name for the list of tasks user reported |
static String |
TASKS_IM_WORKING_ON
Constant list name for the list of tasks user is working on |
Fields inherited from class org.pronoic.cos.client.AbstractClientApp |
mCosConnector |
Constructor Summary | |
ClientApp()
Constructor that sets up the Look and Feel. |
Method Summary | |
void |
authenticateUser(String username,
char[] password)
authenticates the user given a username and password. |
String[] |
getKnownCategories()
gets an array of categories known to the system. |
String[] |
getKnownCategories(Transaction tran)
gets an array of categories known to the system under a transaction. |
String[] |
getKnownProjects()
functionally equivalent to getKnownProjects below only without the use of a transaction. |
String[] |
getKnownProjects(Transaction tran)
gets an array of project names known to the system under cover of a transaction. |
Vector |
getTasksImWorkingOn()
gets the vector of TaskTrackerEntries the user is working on. |
Vector |
getTasksIReported()
gets the vector of TaskTrackerEntries the user reported. |
String[] |
getUserBuddies()
gets the users buddy list as an array of strings. |
String[] |
getUserBuddies(Transaction tran)
gets the users buddy list as an array of strings under a transaction. |
String |
getUsername()
gets the name of the currently logged in user. |
boolean |
login(String username,
char[] password)
Login will attempt to authenticate the user based on the values supplied. |
static void |
main(String[] args)
Let's see what this baby can do. |
boolean |
newTask(TaskTrackerEntry task)
newTask adds a TaskTrackerEntry report to the Cos. |
void |
resetUser(String username)
When an authenticated user first logs in we should load up the following list objects for them Their Buddy List. |
void |
setCategories(Vector c)
set the Categories list and fires a property change event. |
void |
setCaution(String c)
set the caution and fires a property change event. |
void |
setProjects(Vector p)
set the Projects list and fires a property change event. |
void |
setTasksImWorkingOn(Vector b)
set the TasksImWorkingOn List list and fires a property change event. |
void |
setTasksIReported(Vector b)
set the TasksIReported List list and fires a property change event. |
void |
setUserBuddies(Vector b)
set the UserBuddy List list and fires a property change event. |
void |
startup(SpaceConnectable connector,
Transaction tran)
|
boolean |
updateTask(TaskTrackerEntry oldTask,
TaskTrackerEntry newTask)
updateTask replaces the old task with the newly edited task, and reports that change to the COS. |
Methods inherited from class org.pronoic.cos.client.AbstractClientApp |
connect, disconnect, getApplicationName, getCosConnector, initialiseLookAndFeel, isConnected, isCosApplicationRunning, quit, setApplicationName, setConfigInfo |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final String TASKS_IM_WORKING_ON
public static final String TASKS_I_REPORTED
public static final String BUDDY_LIST_NAME
public static final String CATEGORY_LIST_NAME
public static final String PROJECT_LIST_NAME
public Vector mTasksImWorkingOnCache
null
if no user logged in.public Vector mTasksIReportedCache
null
if no user logged in.public Vector mUserBuddiesCache
null
if no user logged in.public PropertyChangeSupport mTasksImWorkingOnPCS
public PropertyChangeSupport mTasksIReportedPCS
public PropertyChangeSupport mBuddyListPCS
public Vector mCategoryCache
public Vector mProjectCache
public PropertyChangeSupport mCategoriesPCS
public PropertyChangeSupport mProjectsPCS
public final Color mBackgroundColour
public final Color mDisplayTextColour
public final Color mTitleColour
public final Font mDisplayFont
public String mUser
public String mCaution
public PropertyChangeSupport mCautioner
Constructor Detail |
public ClientApp()
Method Detail |
public boolean login(String username, char[] password)
username
- The username of the person you wish to log in.password
- The user's password.true
if the login was successful, false
if not.public boolean newTask(TaskTrackerEntry task)
task
- The TaskTrackerEntry to add to the Cos.true
if the task was entered, false
if not.NewTaskFrame
public boolean updateTask(TaskTrackerEntry oldTask, TaskTrackerEntry newTask)
Currently unimplemented.
there is a logical flow that needs specification here.
oldTask
- the original tasknewTask
- the task you are replacing it withpublic void authenticateUser(String username, char[] password) throws Exception
username
- The username of the person you wish to authenticate.password
- The password of the person you wish to authenticate as char[] not string.public void resetUser(String username)
Once the lists have been loaded we will use Notify events from the Cos to keep them updated.
public void setCaution(String c)
c
- The words of caution.public void setTasksImWorkingOn(Vector b)
b
- a filled out Vecotr of TaskTrackerEntries.public void setTasksIReported(Vector b)
b
- a filled out Vecotr of TaskTrackerEntries.public void setCategories(Vector c)
c
- a Vector of category names.public void setProjects(Vector p)
p
- a Vector of project names.public void setUserBuddies(Vector b)
b
- Vector of the user's buddy names.public static void main(String[] args)
args
- args[0] should be a URL of a suitable config file.public String getUsername()
public String[] getUserBuddies()
public String[] getUserBuddies(Transaction tran)
tran
- the transaction covering the retrieval.public Vector getTasksImWorkingOn()
public Vector getTasksIReported()
public String[] getKnownCategories()
public String[] getKnownCategories(Transaction tran)
tran
- the transacton under which to perform the retrieval.public String[] getKnownProjects()
getKnownProjects
below only without the use of a transaction.public String[] getKnownProjects(Transaction tran)
tran
- the transaction covering retrieval of the project list.public void startup(SpaceConnectable connector, Transaction tran) throws GeneralCosException
startup
in interface CosStartable
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |