org.jcreme.processing
Interface RemoteTaskActivityMonitor

All Superinterfaces:
java.rmi.Remote
All Known Implementing Classes:
RemoteTaskActivityMonitorImpl

public interface RemoteTaskActivityMonitor
extends java.rmi.Remote

This interface enables to monitor a remote task.

Version:
$Revision: 1.2 $
Author:
$Author: dbregeon $

Nested Class Summary
static interface RemoteTaskActivityMonitor.RemoteListener
          An interface to describe Remote change listeners.
 
Method Summary
 void addPropertyChangeListener(RemoteTaskActivityMonitor.RemoteListener l)
          This method should be called to register distant listeners.
 java.lang.Double getCompletionPercentage()
          Gives access to the completion percentage of the task.
 java.lang.Long getElapsedTime()
          Provides the elapsed time since the task started.
 java.util.Date getEndDate()
          Gives access to the task's completion date.
 java.util.Date getStartDate()
          Gives access to the date when the task started.
 java.lang.String getTaskName()
          Gives access to the task's name.
 void removePropertyChangeListener(RemoteTaskActivityMonitor.RemoteListener l)
          This method should be called to unregister distant listeners.
 

Method Detail

getTaskName

public java.lang.String getTaskName()
                             throws java.rmi.RemoteException
Gives access to the task's name.

Returns:
a name associated to the task.
Throws:
java.rmi.RemoteException - if an error occurs during communication.

getCompletionPercentage

public java.lang.Double getCompletionPercentage()
                                         throws java.rmi.RemoteException
Gives access to the completion percentage of the task.

Returns:
A percentage of completion for the task.
Throws:
java.rmi.RemoteException - if an error occurs during communication.

getStartDate

public java.util.Date getStartDate()
                            throws java.rmi.RemoteException
Gives access to the date when the task started.

Returns:
the date when the task was started or null if the task has not started.
Throws:
java.rmi.RemoteException - if an error occurs during communication.

getEndDate

public java.util.Date getEndDate()
                          throws java.rmi.RemoteException
Gives access to the task's completion date.

Returns:
the date when the task was finished or null if the task is not finished.
Throws:
java.rmi.RemoteException - if an error occurs during communication.

getElapsedTime

public java.lang.Long getElapsedTime()
                              throws java.rmi.RemoteException
Provides the elapsed time since the task started.

Returns:
the difference between the start date and the end date. Null when the getStartDate method returns null. The difference between a newly created Date and the start date if the getEndDate method returns null and the getStartDate does not.
Throws:
java.rmi.RemoteException - if an error occurs during communication.

addPropertyChangeListener

public void addPropertyChangeListener(RemoteTaskActivityMonitor.RemoteListener l)
                               throws java.rmi.RemoteException
This method should be called to register distant listeners.

Parameters:
l - the listener to be notified.
Throws:
java.rmi.RemoteException - if an error occurs during communication.

removePropertyChangeListener

public void removePropertyChangeListener(RemoteTaskActivityMonitor.RemoteListener l)
                                  throws java.rmi.RemoteException
This method should be called to unregister distant listeners.

Parameters:
l - the listener to be removed.
Throws:
java.rmi.RemoteException - if an error occurs during communication.


Copyright 2006 null. All Rights Reserved.