Package com.arjuna.mw.wsas.activity
Interface HLS
- All Known Subinterfaces:
SagasHLS
,TwoPhaseHLS
public interface HLS
An HLS is registered with activities to be informed of their lifecycle
and to augment the basic notion of what an activity is.
Currently each HLS is registered globally so that all activities on
all threads know about them. However, we may want to have finer
granularity such that an HLS may only be registered with a specific
thread.
- Since:
- 1.0.
- Version:
- $Id: HLS.java,v 1.2 2005/05/19 12:13:16 nmcl Exp $
- Author:
- Mark Little (mark.little@arjuna.com)
-
Method Summary
Modifier and TypeMethodDescriptionvoid
begun()
An activity has begun and is active on the current thread.The current activity is completing with the specified completion status.void
The activity has completed and is still active on the current thread.context()
Return the context augmentation for this HLS, if any on the current activity, i.e., the activity active on the current thread.identity()
The HLS name.int
priority()
The activity service maintains a priority ordered list of HLS implementations.void
resumed()
The activity has been resumed on the current thread and is active on that thread.void
The activity is being suspended, but is still active on the current thread.
-
Method Details
-
begun
An activity has begun and is active on the current thread.- Throws:
SystemException
- Thrown if an error occurs. Any error will cause the activity to be failed.
-
complete
The current activity is completing with the specified completion status.- Parameters:
cs
- The completion status to use.- Returns:
- The result of terminating the relationship of this HLS and the current activity.
- Throws:
SystemException
- Thrown if an error occurs. Any error will cause the activity to be failed.
-
suspended
The activity is being suspended, but is still active on the current thread.- Throws:
SystemException
-
resumed
The activity has been resumed on the current thread and is active on that thread.- Throws:
SystemException
-
completed
The activity has completed and is still active on the current thread.- Throws:
SystemException
-
identity
The HLS name.- Throws:
SystemException
-
priority
The activity service maintains a priority ordered list of HLS implementations. If an HLS wishes to be ordered based on priority then it can return a non-negative value: the higher the value, the higher the priority and hence the earlier in the list of HLSes it will appear (and be used in).- Returns:
- a positive value for the priority for this HLS, or zero/negative if the order is not important.
- Throws:
SystemException
-
context
Return the context augmentation for this HLS, if any on the current activity, i.e., the activity active on the current thread.- Returns:
- a context object or null if no augmentation is necessary.
- Throws:
SystemException
-