com.parctechnologies.eclipse
Interface EclipseMultitaskConnection

All Superinterfaces:
EclipseConnection

public interface EclipseMultitaskConnection
extends EclipseConnection

Interface of objects which provide a multitask aware connection to an ECLiPSe connection.

Classes implementing EclipseMultitaskConnection provide the same functionality as EclipseConnection except that this peer is registered as being interested in multitasking phases, and conceptualy the peer maintains control throughout a multitasking phase.

Objects implementing this interface can are returned from calls to registerMultitask in the EclipseConnection interface.

NOTE:The blocking semantics of RPC calls changes slightly for this object as compared to the standard EclipseConnection. Any thread may execute RPCs on this object (as with normal EclipseConnections) however if the thread does not "own" the EclipseConnection the RPC call will block until the thread can gain "ownership" (as with normal EclipseConnections) UNLESS ECLiPSe is in a multitasking phase. In such a case, the RPC will be serviced (during the multitask phase) and the thread un-blocked.

NOTE:As currently implemented it is ONLY RPC semantics that change. Writing to Queues are still subject to the same synchronization restrictions as with a normal EclipseConnection ie. only the "owner" thread can perform queue operations. This may be changed in a future release.

The intention is that GUI tools can perform simple RPCs whilst another peer has instigated a multitasking phase and/or GUI peers can use the multitasking phases to pause ECLiPSe and perform work whilst allowing other peers to do simple queries.

The registered MultitaskListener methods will be called when gaining/losing control because of entering/leaving multitasking phases.

calling regiterMultitask on an object of this class will return the same object, but will add the given MultitaskListener.

See Also:
MultitaskListener, EclipseConnection, EclipseConnection.registerMultitask(com.parctechnologies.eclipse.MultitaskListener)

Method Summary
 void multitaskConfirm()
          Indicates that this peer would like the multitask phase to begin.
 void multitaskTerminate()
          Indicates that this peer would like the multitask phase to terminate.
 
Methods inherited from interface com.parctechnologies.eclipse.EclipseConnection
compile, getAsyncEclipseQueue, getFromEclipseQueue, getPath, getPeerName, getToEclipseQueue, registerMultitask, rpc, rpc, rpc, rpc, rpc, rpc, rpc, rpc, rpc
 

Method Detail

multitaskConfirm

void multitaskConfirm()
                      throws EclipseException,
                             java.io.IOException
Indicates that this peer would like the multitask phase to begin.

Throws:
java.lang.IllegalStateException - If ECLiPSe is not in a multitask phase.
EclipseException
java.io.IOException

multitaskTerminate

void multitaskTerminate()
                        throws EclipseException,
                               java.io.IOException
Indicates that this peer would like the multitask phase to terminate.

Throws:
java.lang.IllegalStateException - If ECLiPSe is not in a multitask phase.
EclipseException
java.io.IOException