com.ibm.task.clientmodel.bean
Class EscalationBean

java.lang.Object
  extended bycom.ibm.task.clientmodel.bean.EscalationBean
All Implemented Interfaces:
com.ibm.task.api.Escalation, java.io.Serializable

public class EscalationBean
extends java.lang.Object
implements com.ibm.task.api.Escalation

Accesses the properties of the original Escalation object and adds metadata for national language support and converters.

An EscalationBean object can be instantiated from a QueryResultSet object.
Only the following properties are going to be loaded from the query result set:

If the property was not found in the query result set, the property will remain empty. Accessing an empty property requires the bean to load the missing information from the server.

Use the static method getLabel(String, Locale) to retrieve the localized label for a property. Use the static method getConverter(String) to retrieve a converter for a property. The return value may be null because converters are optional.

See Also:
Escalation, QueryResultSet, Serialized Form

Field Summary
static java.lang.String ACTION_PROPERTY
          Use the property name to determine labels and converters for the property action.
static java.lang.String ACTIVATIONSTATE_PROPERTY
          Use the property name to determine labels and converters for the property activiation state.
static java.lang.String ACTIVATIONTIME_PROPERTY
          Use the property name to determine labels and converters for the property activiation time.
static java.lang.String ATLEASTEXPECTEDSTATE_PROPERTY
          Use the property name to determine labels and converters for the property atLeastExpectedState.
static java.lang.String COPYRIGHT
          (C) Copyright IBM Corporation 2005.
static java.lang.String DESCRIPTION_PROPERTY
          Use the property name to determine labels and converters for the property description.
static java.lang.String DURATIONUNTILESCALATED_PROPERTY
          Use the property name to determine labels and converters for the property durationUntilEscalated.
static java.lang.String DURATIONUNTILREPEATED_PROPERTY
          Use the property name to determine labels and converters for the property durationUntilRepeated.
static java.lang.String ESCALATION_RECEIVER_PROPERTY
          Use the property name to determine labels and converters for the property escalationReceiver.
static java.lang.String NAME_PROPERTY
          Use the property name to determine labels and converters for the property name.
static java.lang.String PRIORITY_INCREASE_PROPERTY
          Use the property name to determine labels and converters for the property priorityIncrease.
static java.lang.String STATE_PROPERTY
          Use the property name to determine labels and converters for the property state.
static java.lang.String TASK_OWNER_PROPERTY
          Use the property name to determine labels and converters for the property taskOwner.
 
Fields inherited from interface com.ibm.task.api.Escalation
ACTION_CREATE_EVENT, ACTION_CREATE_WORK_ITEM, ACTION_SEND_EMAIL, ACTIVATION_STATE_CLAIMED, ACTIVATION_STATE_READY, ACTIVATION_STATE_RUNNING, ACTIVATION_STATE_WAITING_FOR_SUBTASK, AT_LEAST_EXPECTED_STATE_CLAIMED, AT_LEAST_EXPECTED_STATE_ENDED, AT_LEAST_EXPECTED_STATE_SUBTASKS_COMPLETED, INCREASE_PRIORITY_NO, INCREASE_PRIORITY_ONCE, INCREASE_PRIORITY_REPEATED, STATE_ESCALATED, STATE_INACTIVE, STATE_SUBTASKS_COMPLETED, STATE_SUPERFLUOUS, STATE_WAITING
 
Constructor Summary
EscalationBean(com.ibm.task.api.QueryResultSet resultSet, HTMConnection htmConnection)
          Constructs a new EscalationBean from a QueryResultSet.
 
Method Summary
 int getAction()
          Returns the property action.
 int getActivationState()
          Returns the property activationState.
 java.util.Calendar getActivationTime()
          Returns the property activationTime.
 int getAtLeastExpectedState()
          Returns the property atLeastExpectedState.
 com.ibm.bpe.api.OID getContainmentContextID()
          Returns the property containmentContextID.
static SimpleConverter getConverter(java.lang.String propertyName)
          Returns the default converter for a given property.
 com.ibm.bpc.clientcore.util.LocalisedString getDescription()
          Returns the localised description.
 java.lang.String getDescription(java.util.Locale arg0)
          Returns the property description.
 com.ibm.bpc.clientcore.util.LocalisedString getDisplayName()
          Returns the localised display name.
 java.lang.String getDisplayName(java.util.Locale arg0)
          Returns the property displayName.
 java.lang.String getDurationUntilEscalated()
          Returns the property durationUntilEscalated.
 java.lang.String getDurationUntilRepeated()
          Returns the property durationUntilRepeated.
 java.lang.String getEscalationReceiver()
          Returns the property escalationReceiver.
 com.ibm.task.api.ESTID getEscalationTemplateID()
          Returns the property escalationTemplateID.
 com.ibm.task.api.ESIID getFirstEscalationID()
          Returns the property firstEscalationID.
 com.ibm.task.api.ESIID getID()
          Returns the property ID.
static java.lang.String getLabel(java.lang.String propertyName)
          Returns the resource bundle key for a property
static java.lang.String getLabel(java.lang.String propertyName, java.util.Locale locale)
          Returns the label for a property from the resource bundle.
 java.util.List getLocalesOfDescriptions()
          Returns the property localesOfDescriptions.
 java.util.List getLocalesOfDisplayNames()
          Returns the property localesOfDisplayNames.
 java.lang.String getName()
          Returns the property name.
 com.ibm.task.api.ESIID getNextEscalationID()
          Returns the property nextEscalationID.
 com.ibm.task.api.ESIID getPreviousEscalationID()
          Returns the property previousEscalationID.
 int getPriorityIncrease()
          Returns the property priorityIncrease.
 int getState()
          Returns the property state.
 com.ibm.task.api.TKIID getTaskInstanceID()
          Returns the property taskInstanceID.
 java.lang.String getTaskName()
          Returns the property taskName.
 java.lang.String getTaskOwner()
          Returns the property taskOwner.
static boolean isValid(java.lang.String propertyName)
          Checks if the property is valid.
 void setName(java.lang.String arg0)
          Sets the property name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

COPYRIGHT

public static final java.lang.String COPYRIGHT
(C) Copyright IBM Corporation 2005.

See Also:
Constant Field Values

ACTION_PROPERTY

public static java.lang.String ACTION_PROPERTY
Use the property name to determine labels and converters for the property action.


ACTIVATIONSTATE_PROPERTY

public static java.lang.String ACTIVATIONSTATE_PROPERTY
Use the property name to determine labels and converters for the property activiation state.


ACTIVATIONTIME_PROPERTY

public static java.lang.String ACTIVATIONTIME_PROPERTY
Use the property name to determine labels and converters for the property activiation time.


ATLEASTEXPECTEDSTATE_PROPERTY

public static java.lang.String ATLEASTEXPECTEDSTATE_PROPERTY
Use the property name to determine labels and converters for the property atLeastExpectedState.


DESCRIPTION_PROPERTY

public static java.lang.String DESCRIPTION_PROPERTY
Use the property name to determine labels and converters for the property description.


NAME_PROPERTY

public static java.lang.String NAME_PROPERTY
Use the property name to determine labels and converters for the property name.


DURATIONUNTILESCALATED_PROPERTY

public static java.lang.String DURATIONUNTILESCALATED_PROPERTY
Use the property name to determine labels and converters for the property durationUntilEscalated.


DURATIONUNTILREPEATED_PROPERTY

public static java.lang.String DURATIONUNTILREPEATED_PROPERTY
Use the property name to determine labels and converters for the property durationUntilRepeated.


PRIORITY_INCREASE_PROPERTY

public static java.lang.String PRIORITY_INCREASE_PROPERTY
Use the property name to determine labels and converters for the property priorityIncrease.


STATE_PROPERTY

public static java.lang.String STATE_PROPERTY
Use the property name to determine labels and converters for the property state.


TASK_OWNER_PROPERTY

public static java.lang.String TASK_OWNER_PROPERTY
Use the property name to determine labels and converters for the property taskOwner.


ESCALATION_RECEIVER_PROPERTY

public static java.lang.String ESCALATION_RECEIVER_PROPERTY
Use the property name to determine labels and converters for the property escalationReceiver.

Constructor Detail

EscalationBean

public EscalationBean(com.ibm.task.api.QueryResultSet resultSet,
                      HTMConnection htmConnection)
Constructs a new EscalationBean from a QueryResultSet.

Parameters:
resultSet - The result object of a query.
htmConnection - The connection to the HumanTaskManagerService API.
Method Detail

getConverter

public static SimpleConverter getConverter(java.lang.String propertyName)
Returns the default converter for a given property.

Parameters:
propertyName - The name for the property.
Returns:
The converter instance if one has been registered with propertyName, null otherwise.

getLabel

public static java.lang.String getLabel(java.lang.String propertyName)
Returns the resource bundle key for a property

Parameters:
propertyName - The name for the property.
Returns:
The resource bundle key for the property.

getLabel

public static java.lang.String getLabel(java.lang.String propertyName,
                                        java.util.Locale locale)
Returns the label for a property from the resource bundle. If no label is found in the resource bundle the resource bundle key for the property is returned.

Parameters:
propertyName - The name for the property.
locale - The locale.
Returns:
The label or the resource bundle key for the property.

isValid

public static boolean isValid(java.lang.String propertyName)
Checks if the property is valid.

Parameters:
propertyName - The name of the property to be checked.
Returns:
True, if the propertyName is a known property for an object of this class.

getAction

public int getAction()
Returns the property action.

Specified by:
getAction in interface com.ibm.task.api.Escalation
See Also:
Escalation.getAction()

getActivationState

public int getActivationState()
Returns the property activationState.

Specified by:
getActivationState in interface com.ibm.task.api.Escalation
See Also:
Escalation.getActivationState()

getActivationTime

public java.util.Calendar getActivationTime()
Returns the property activationTime.

Specified by:
getActivationTime in interface com.ibm.task.api.Escalation
See Also:
Escalation.getActivationTime()

getAtLeastExpectedState

public int getAtLeastExpectedState()
Returns the property atLeastExpectedState.

Specified by:
getAtLeastExpectedState in interface com.ibm.task.api.Escalation
See Also:
Escalation.getAtLeastExpectedState()

getContainmentContextID

public com.ibm.bpe.api.OID getContainmentContextID()
Returns the property containmentContextID.

Specified by:
getContainmentContextID in interface com.ibm.task.api.Escalation
See Also:
Escalation.getContainmentContextID()

getDescription

public com.ibm.bpc.clientcore.util.LocalisedString getDescription()
Returns the localised description.

Returns:
The localised description.

getDescription

public java.lang.String getDescription(java.util.Locale arg0)
Returns the property description.

Specified by:
getDescription in interface com.ibm.task.api.Escalation
See Also:
Escalation.getDescription(java.util.Locale)

getDisplayName

public com.ibm.bpc.clientcore.util.LocalisedString getDisplayName()
Returns the localised display name.

Returns:
The localised display name.

getDisplayName

public java.lang.String getDisplayName(java.util.Locale arg0)
Returns the property displayName.

Specified by:
getDisplayName in interface com.ibm.task.api.Escalation
See Also:
Escalation.getDisplayName(java.util.Locale)

getDurationUntilEscalated

public java.lang.String getDurationUntilEscalated()
Returns the property durationUntilEscalated.

Specified by:
getDurationUntilEscalated in interface com.ibm.task.api.Escalation
See Also:
Escalation.getDurationUntilEscalated()

getDurationUntilRepeated

public java.lang.String getDurationUntilRepeated()
Returns the property durationUntilRepeated.

Specified by:
getDurationUntilRepeated in interface com.ibm.task.api.Escalation
See Also:
Escalation.getDurationUntilRepeated()

getEscalationReceiver

public java.lang.String getEscalationReceiver()
Returns the property escalationReceiver.

Returns:
the receiver of the escalation

getEscalationTemplateID

public com.ibm.task.api.ESTID getEscalationTemplateID()
Returns the property escalationTemplateID.

Specified by:
getEscalationTemplateID in interface com.ibm.task.api.Escalation
See Also:
Escalation.getEscalationTemplateID()

getFirstEscalationID

public com.ibm.task.api.ESIID getFirstEscalationID()
Returns the property firstEscalationID.

Specified by:
getFirstEscalationID in interface com.ibm.task.api.Escalation
See Also:
Escalation.getFirstEscalationID()

getID

public com.ibm.task.api.ESIID getID()
Returns the property ID.

Specified by:
getID in interface com.ibm.task.api.Escalation
See Also:
Escalation.getID()

getLocalesOfDescriptions

public java.util.List getLocalesOfDescriptions()
Returns the property localesOfDescriptions.

Specified by:
getLocalesOfDescriptions in interface com.ibm.task.api.Escalation
See Also:
Escalation.getLocalesOfDescriptions()

getLocalesOfDisplayNames

public java.util.List getLocalesOfDisplayNames()
Returns the property localesOfDisplayNames.

Specified by:
getLocalesOfDisplayNames in interface com.ibm.task.api.Escalation
See Also:
Escalation.getLocalesOfDisplayNames()

getName

public java.lang.String getName()
Returns the property name.

Specified by:
getName in interface com.ibm.task.api.Escalation
See Also:
Escalation.getName()

getNextEscalationID

public com.ibm.task.api.ESIID getNextEscalationID()
Returns the property nextEscalationID.

Specified by:
getNextEscalationID in interface com.ibm.task.api.Escalation
See Also:
Escalation.getNextEscalationID()

getPreviousEscalationID

public com.ibm.task.api.ESIID getPreviousEscalationID()
Returns the property previousEscalationID.

Specified by:
getPreviousEscalationID in interface com.ibm.task.api.Escalation
See Also:
Escalation.getPreviousEscalationID()

getPriorityIncrease

public int getPriorityIncrease()
Returns the property priorityIncrease.

Specified by:
getPriorityIncrease in interface com.ibm.task.api.Escalation
See Also:
Escalation.getPriorityIncrease()

getState

public int getState()
Returns the property state.

Specified by:
getState in interface com.ibm.task.api.Escalation
See Also:
Escalation.getState()

getTaskInstanceID

public com.ibm.task.api.TKIID getTaskInstanceID()
Returns the property taskInstanceID.

Specified by:
getTaskInstanceID in interface com.ibm.task.api.Escalation
See Also:
Escalation.getTaskInstanceID()

getTaskName

public java.lang.String getTaskName()
Returns the property taskName.

Returns:
name of the task instance

getTaskOwner

public java.lang.String getTaskOwner()
Returns the property taskOwner.

Returns:
the owner of the task instance

setName

public void setName(java.lang.String arg0)
Sets the property name.

Specified by:
setName in interface com.ibm.task.api.Escalation
See Also:
Escalation.setName(java.lang.String)