Class AbstractTransferableGUIContext
- java.lang.Object
-
- de.aristaflow.adept2.ui.remotegui.AbstractTransferableGUIContext
-
- All Implemented Interfaces:
Localiser,GUIContext,de.aristaflow.adept2.model.runtimeenvironment.guicontext.TransferableGUIContext,Closeable,Serializable,AutoCloseable
- Direct Known Subclasses:
TransferredURLContext
public class AbstractTransferableGUIContext extends Object implements de.aristaflow.adept2.model.runtimeenvironment.guicontext.TransferableGUIContext
A basic implementation for aTransferableGUIContextjust enough to satisfy the interface. Subclasses should provide more information to allow for creating a local GUI context for a remote execution. This information also needs to be provided viagetGUIContextAttributes()so subclasses should override this method.- Author:
- Ulrich Kreher
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected EBPInstanceReferenceactivityTheEBPInstanceReferenceidentifying the process instance node this GUI context has been created for.protected ActivityInstanceactivityInstanceThe activity instance this GUI context has been created for.protected ExecutionContextexecutionContextThe execution context of the activity for which this GUI context has been created for.protected LocalelocaleThe locale of the agent requesting this GUI context.protected StringsessionIDThe ID of the execution session this GUI context has been created for uniquely identifying the component execution on the (remote) runtime manager).protected StringtransfrdGUIContextIDThe ID of transferred GUI context which may differ from that provided and requested by the activity instance.
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractTransferableGUIContext(ActivityInstance activityInstance, EBPInstanceReference activity, String sessionID, ExecutionContext executionContext, String transfrdGUIContextID)Creates a new instance of the base implementation of aTransferableGUIContexthaving the designated fields.protectedAbstractTransferableGUIContext(AbstractTransferableGUIContext context)Creates a new instance of the base implementation of aTransferableGUIContexthaving the fields of the designated GUI context.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()Closes the GUI for this context.ActivityInstancegetActivityInstance()EBPInstanceReferencegetEBPInstanceReference()ExecutionContextgetExecutionContext()Map<String,String>getGUIContextAttributes()Always returns the empty map.LocalegetLocale()Gets theLocalethat should be used or that is used for localisation of this object or a related object.StringgetSessionID()StringgetTransferredGUIContextID()
-
-
-
Field Detail
-
activityInstance
protected final ActivityInstance activityInstance
The activity instance this GUI context has been created for.
-
locale
protected final Locale locale
The locale of the agent requesting this GUI context. This will benullif the activity instance should not be localised.
-
activity
protected final EBPInstanceReference activity
TheEBPInstanceReferenceidentifying the process instance node this GUI context has been created for.
-
sessionID
protected final String sessionID
The ID of the execution session this GUI context has been created for uniquely identifying the component execution on the (remote) runtime manager).
-
executionContext
protected final ExecutionContext executionContext
The execution context of the activity for which this GUI context has been created for.
-
transfrdGUIContextID
protected final String transfrdGUIContextID
The ID of transferred GUI context which may differ from that provided and requested by the activity instance.
-
-
Constructor Detail
-
AbstractTransferableGUIContext
protected AbstractTransferableGUIContext(ActivityInstance activityInstance, EBPInstanceReference activity, String sessionID, ExecutionContext executionContext, String transfrdGUIContextID)
Creates a new instance of the base implementation of aTransferableGUIContexthaving the designated fields.- Parameters:
activityInstance- The activity instance this GUI context has been created for.activity- TheEBPInstanceReferenceidentifying the process instance node this GUI context has been created for.sessionID- The ID of the execution session this GUI context has been created for uniquely identifying the component execution on the (remote) runtime manager).executionContext- The execution context of the activity for which this GUI context has been created for.transfrdGUIContextID- The ID of transferred GUI context which may differ from that provided and requested by the activity instance.
-
AbstractTransferableGUIContext
protected AbstractTransferableGUIContext(AbstractTransferableGUIContext context)
Creates a new instance of the base implementation of aTransferableGUIContexthaving the fields of the designated GUI context.- Parameters:
context- The GUI context from which to retrieve the fields.
-
-
Method Detail
-
getActivityInstance
public ActivityInstance getActivityInstance()
- Specified by:
getActivityInstancein interfacede.aristaflow.adept2.model.runtimeenvironment.guicontext.TransferableGUIContext
-
getLocale
public Locale getLocale()
Description copied from interface:LocaliserGets theLocalethat should be used or that is used for localisation of this object or a related object.
-
getEBPInstanceReference
public EBPInstanceReference getEBPInstanceReference()
- Specified by:
getEBPInstanceReferencein interfacede.aristaflow.adept2.model.runtimeenvironment.guicontext.TransferableGUIContext
-
getSessionID
public String getSessionID()
- Specified by:
getSessionIDin interfacede.aristaflow.adept2.model.runtimeenvironment.guicontext.TransferableGUIContext
-
getExecutionContext
public ExecutionContext getExecutionContext()
- Specified by:
getExecutionContextin interfacede.aristaflow.adept2.model.runtimeenvironment.guicontext.TransferableGUIContext
-
getTransferredGUIContextID
public String getTransferredGUIContextID()
- Specified by:
getTransferredGUIContextIDin interfacede.aristaflow.adept2.model.runtimeenvironment.guicontext.TransferableGUIContext
-
getGUIContextAttributes
public Map<String,String> getGUIContextAttributes()
Always returns the empty map.- Specified by:
getGUIContextAttributesin interfacede.aristaflow.adept2.model.runtimeenvironment.guicontext.TransferableGUIContext
-
close
public void close()
Closes the GUI for this context. This method has to be called by the runtime manager whenever an application has terminated (finished, failed, aborted, killed,...).
It must be possible to call this method more than once, even if the GUIContext has already shut down. This especially applies to the disposal of SWT-widgets, that is, it is allowed to call this method after the disposal of the corresponding widgets. This is an empty implementation since subclasses are usually only used for transferring the GUI context from the executing runtime manager to the displaying client.- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Specified by:
closein interfaceGUIContext
-
-