de.danet.an.workflow.api
Class ActivityUniqueKey

java.lang.Object
  extended byde.danet.an.workflow.api.ActivityUniqueKey
All Implemented Interfaces:
java.io.Serializable

public class ActivityUniqueKey
extends java.lang.Object
implements java.io.Serializable

This class implements a unique activity key. The OMG interface defines the key returned by the key() method as unique within the scope of the containing process only. The key of a process in turn is unique only among the processes with a common process manager.

This class therefore combines the activity key, the process key and the process manager name to a unique activity key.

Version:
$Revision: 1.2 $
Author:
Michael N. Lipp
See Also:
Serialized Form

Constructor Summary
ActivityUniqueKey(java.lang.String managerName, java.lang.String processKey, java.lang.String activityKey)
          Creates an instance of ActivityUniqueKey from the given partial keys.
ActivityUniqueKey(WfActivity activity)
          Creates an instance of ActivityUniqueKey for the given activity.
 
Method Summary
 java.lang.String activityKey()
          Return the activity key.
 boolean equals(java.lang.Object other)
          Two ActivityUniqueKeys are equal, if all attributes are equal.
 int hashCode()
          Calculate a hash code for a ActivityUniqueKey object.
 java.lang.String managerName()
          Return the process manager name.
 java.lang.String processKey()
          Return the process key.
 java.lang.String toString()
          Generate a string representation for debugging purposes.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ActivityUniqueKey

public ActivityUniqueKey(WfActivity activity)
                  throws java.rmi.RemoteException
Creates an instance of ActivityUniqueKey for the given activity.

Parameters:
activity - the WfActivity.
Throws:
java.rmi.RemoteException - if a system-level error occurs.

ActivityUniqueKey

public ActivityUniqueKey(java.lang.String managerName,
                         java.lang.String processKey,
                         java.lang.String activityKey)
Creates an instance of ActivityUniqueKey from the given partial keys.

Parameters:
managerName - the process manager name.
processKey - the process key.
activityKey - the activity key.
Method Detail

equals

public boolean equals(java.lang.Object other)
Two ActivityUniqueKeys are equal, if all attributes are equal.

Parameters:
other - a ActivityUniqueKey value
Returns:
true if objects are equal.

hashCode

public int hashCode()
Calculate a hash code for a ActivityUniqueKey object.

Returns:
the hash code.

activityKey

public java.lang.String activityKey()
Return the activity key.

Returns:
the activity key.

processKey

public java.lang.String processKey()
Return the process key.

Returns:
the process key.

managerName

public java.lang.String managerName()
Return the process manager name.

Returns:
the process manager name.

toString

public java.lang.String toString()
Generate a string representation for debugging purposes.

Returns:
a string representation.