uk.org.ogsadai.client.toolkit.activity.misc
Class NotificationType

java.lang.Object
  |
  +--uk.org.ogsadai.client.toolkit.activity.misc.NotificationType

public final class NotificationType
extends java.lang.Object

A notification type - notify on commencement, completion or do not notify.

Author:
The OGSA-DAI Project Team

Field Summary
static NotificationType COMMENCED
          Notify on commencement of processing.
static NotificationType COMPLETE
          Notify on completion of processing.
static NotificationType NONE
          Do not notify.
 
Method Summary
 java.lang.String getAsString()
          Return the notification type as a string - either "none", "commenced" or "complete".
 boolean isCommenced()
          Is the current notification type notification on commencement of processing?
 boolean isComplete()
          Is the current notification type notification on completion of processing?
 boolean isNone()
          Is the current notification type no notification?
 void setCommenced()
          Set the notification type to be notification on commencement of processing.
 void setComplete()
          Set the notification type to be notification on completion of processing.
 void setNone()
          Set the notification type to be no notification.
 void setType(java.lang.String type)
          Set the notification type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NONE

public static final NotificationType NONE
Do not notify.


COMMENCED

public static final NotificationType COMMENCED
Notify on commencement of processing.


COMPLETE

public static final NotificationType COMPLETE
Notify on completion of processing.

Method Detail

setType

public void setType(java.lang.String type)
Set the notification type.

Parameters:
type - with value NotificationType.NONE_STRING for no notification, NotificationType.COMMENCED_STRING for notification on commencement of processing or NotificationType.COMPLETE_STRING for notification on completion of processing.
Throws:
java.lang.IllegalArgumentException - If type is neither NotificationType.NONE_STRING, NotificationType.COMMENCED_STRING or NotificationType.COMPLETE_STRING

setNone

public void setNone()
Set the notification type to be no notification.


setCommenced

public void setCommenced()
Set the notification type to be notification on commencement of processing.


setComplete

public void setComplete()
Set the notification type to be notification on completion of processing.


isNone

public boolean isNone()
Is the current notification type no notification?

Returns:
true if type is NONE_STRING.

isCommenced

public boolean isCommenced()
Is the current notification type notification on commencement of processing?

Returns:
true if type is COMMENCED_STRING.

isComplete

public boolean isComplete()
Is the current notification type notification on completion of processing?

Returns:
true if type is COMPLETE_STRING.

getAsString

public java.lang.String getAsString()
Return the notification type as a string - either "none", "commenced" or "complete".

Returns:
String