public interface Tie extends InvokeHandler
A Tie serves as a CORBA Servant or implementation base. It is connected to
the ORB on a server side, providing the implementation of the required
functionality. ORB access this implementation using InvokeHandler
._invoke(..). All such calls are finally delegated to the object, returned by
getTarget()
.
Ties are generated from implementations (name pattern *Impl) and have the
name pattern _*Impl_Tie, for instance:
rmic -keep -iiop -poa -always gnu.testlet.java.rmi.Remote.CalculatorImpl
Ties should normally be derived from the
Servant
. Such ties are generated by
rmic
compiler using -poa
key. Ties can be also
derived from ObjectImpl
.
Modifier and Type | Method and Description |
---|---|
void |
deactivate()
Deactivate this Tie.
|
Remote |
getTarget()
Get the invocation target, where all method calls should be delegated.
|
ORB |
orb()
Get the ORB to that this Tie is connected.
|
void |
orb(ORB orb)
Connect this Tie to the given ORB.
|
void |
setTarget(Remote target)
Set the invocation target, where all method calls should be delegated.
|
Object |
thisObject()
Get the object that delegates calls to this tie.
|
_invoke
Remote getTarget()
void setTarget(Remote target)
target
- the object, implementing methods, defined in the interface
being served by this Tie. The code, produced by a typical rmic compiler
usually requires the target to be an instance of the implementation from
that the Tie was generated.ClassCastException
- if the passed parameter is not an instance of
the implementation from that the Tie was generated.ORB orb()
Servant._orb()
Object thisObject()
Servant._this_object()
void deactivate() throws NoSuchObjectException
Servant
deactivate themselves by
ORB.disconnect(org.omg.CORBA.Object)
.NoSuchObjectException
- if there are no objects served by this Tie,
or if the these objects are already deactivated.POAOperations.deactivate_object(byte[])