Methods Summary |
---|
public void | connect(org.omg.CORBA.Object objref)
// Store the objref and get a userkey allocated by the transient
// object manager.
byte[] key = servants.storeServant(objref, null);
// Find out the repository ID for this objref.
String id = StubAdapter.getTypeIds( objref )[0] ;
// Create the new objref
ObjectReferenceFactory orf = getCurrentFactory() ;
org.omg.CORBA.Object obj = orf.make_object( id, key ) ;
// Copy the delegate from the new objref to the argument
// XXX handle the case of an attempt to connect a local object.
org.omg.CORBA.portable.Delegate delegate = StubAdapter.getDelegate(
obj ) ;
CorbaContactInfoList ccil = (CorbaContactInfoList)
((ClientDelegate)delegate).getContactInfoList() ;
LocalClientRequestDispatcher lcs =
ccil.getLocalClientRequestDispatcher() ;
if (lcs instanceof JIDLLocalCRDImpl) {
JIDLLocalCRDImpl jlcs = (JIDLLocalCRDImpl)lcs ;
jlcs.setServant( objref ) ;
} else {
throw new RuntimeException(
"TOAImpl.connect can not be called on " + lcs ) ;
}
StubAdapter.setDelegate( objref, delegate ) ;
|
public void | disconnect(org.omg.CORBA.Object objref)
// Get the delegate, then ior, then transientKey, then delete servant
org.omg.CORBA.portable.Delegate del = StubAdapter.getDelegate(
objref ) ;
CorbaContactInfoList ccil = (CorbaContactInfoList)
((ClientDelegate)del).getContactInfoList() ;
LocalClientRequestDispatcher lcs =
ccil.getLocalClientRequestDispatcher() ;
if (lcs instanceof JIDLLocalCRDImpl) {
JIDLLocalCRDImpl jlcs = (JIDLLocalCRDImpl)lcs ;
byte[] oid = jlcs.getObjectId() ;
servants.deleteServant(oid);
jlcs.unexport() ;
} else {
throw new RuntimeException(
"TOAImpl.disconnect can not be called on " + lcs ) ;
}
|
public void | enter()
|
public void | exit()
|
public org.omg.CORBA.Policy | getEffectivePolicy(int type)
return null ;
|
public java.lang.String[] | getInterfaces(java.lang.Object servant, byte[] objectId)Return the most derived interface for the given servant and objectId.
return StubAdapter.getTypeIds( servant ) ;
|
public void | getInvocationServant(com.sun.corba.se.spi.oa.OAInvocationInfo info)Get the servant for the request given by the parameters.
This will update thread Current, so that subsequent calls to
returnServant and removeCurrent from the same thread are for the
same request.
java.lang.Object servant = servants.lookupServant( info.id() ) ;
if (servant == null)
// This is expected to result in an RMI-IIOP NoSuchObjectException.
// See bug 4973160.
servant = new NullServantImpl( lifecycleWrapper().nullServant() ) ;
info.setServant( servant ) ;
|
public org.omg.CORBA.Object | getLocalServant(byte[] objectId)
return (org.omg.CORBA.Object)(servants.lookupServant( objectId ) ) ;
|
public int | getManagerId()
return -1 ;
|
public com.sun.corba.se.spi.copyobject.ObjectCopierFactory | getObjectCopierFactory()
CopierManager cm = getORB().getCopierManager() ;
return cm.getDefaultObjectCopierFactory() ;
|
public short | getState()
return ACTIVE.value ;
|
public void | returnServant()
// NO-OP
|