orb.setObjectKeyFactory( IORFactories.makeObjectKeyFactory(orb) ) ;
}
private void initRequestDispatcherRegistry( ORB orb )
{
RequestDispatcherRegistry scr = orb.getRequestDispatcherRegistry() ;
// register client subcontracts
ClientRequestDispatcher csub =
RequestDispatcherDefault.makeClientRequestDispatcher() ;
scr.registerClientRequestDispatcher( csub,
ORBConstants.TOA_SCID ) ;
scr.registerClientRequestDispatcher( csub,
ORBConstants.TRANSIENT_SCID ) ;
scr.registerClientRequestDispatcher( csub,
ORBConstants.PERSISTENT_SCID ) ;
scr.registerClientRequestDispatcher( csub,
ORBConstants.SC_TRANSIENT_SCID ) ;
scr.registerClientRequestDispatcher( csub,
ORBConstants.SC_PERSISTENT_SCID ) ;
scr.registerClientRequestDispatcher( csub,
ORBConstants.IISC_TRANSIENT_SCID ) ;
scr.registerClientRequestDispatcher( csub,
ORBConstants.IISC_PERSISTENT_SCID ) ;
scr.registerClientRequestDispatcher( csub,
ORBConstants.MINSC_TRANSIENT_SCID ) ;
scr.registerClientRequestDispatcher( csub,
ORBConstants.MINSC_PERSISTENT_SCID ) ;
// register server delegates
CorbaServerRequestDispatcher sd =
RequestDispatcherDefault.makeServerRequestDispatcher( orb );
scr.registerServerRequestDispatcher( sd,
ORBConstants.TOA_SCID ) ;
scr.registerServerRequestDispatcher( sd,
ORBConstants.TRANSIENT_SCID ) ;
scr.registerServerRequestDispatcher( sd,
ORBConstants.PERSISTENT_SCID ) ;
scr.registerServerRequestDispatcher( sd,
ORBConstants.SC_TRANSIENT_SCID ) ;
scr.registerServerRequestDispatcher( sd,
ORBConstants.SC_PERSISTENT_SCID ) ;
scr.registerServerRequestDispatcher( sd,
ORBConstants.IISC_TRANSIENT_SCID ) ;
scr.registerServerRequestDispatcher( sd,
ORBConstants.IISC_PERSISTENT_SCID ) ;
scr.registerServerRequestDispatcher( sd,
ORBConstants.MINSC_TRANSIENT_SCID ) ;
scr.registerServerRequestDispatcher( sd,
ORBConstants.MINSC_PERSISTENT_SCID ) ;
orb.setINSDelegate(
RequestDispatcherDefault.makeINSServerRequestDispatcher( orb ) ) ;
// register local client subcontracts
LocalClientRequestDispatcherFactory lcsf =
RequestDispatcherDefault.makeJIDLLocalClientRequestDispatcherFactory(
orb ) ;
scr.registerLocalClientRequestDispatcherFactory( lcsf,
ORBConstants.TOA_SCID ) ;
lcsf =
RequestDispatcherDefault.makePOALocalClientRequestDispatcherFactory(
orb ) ;
scr.registerLocalClientRequestDispatcherFactory( lcsf,
ORBConstants.TRANSIENT_SCID ) ;
scr.registerLocalClientRequestDispatcherFactory( lcsf,
ORBConstants.PERSISTENT_SCID ) ;
lcsf = RequestDispatcherDefault.
makeFullServantCacheLocalClientRequestDispatcherFactory( orb ) ;
scr.registerLocalClientRequestDispatcherFactory( lcsf,
ORBConstants.SC_TRANSIENT_SCID ) ;
scr.registerLocalClientRequestDispatcherFactory( lcsf,
ORBConstants.SC_PERSISTENT_SCID ) ;
lcsf = RequestDispatcherDefault.
makeInfoOnlyServantCacheLocalClientRequestDispatcherFactory( orb ) ;
scr.registerLocalClientRequestDispatcherFactory( lcsf,
ORBConstants.IISC_TRANSIENT_SCID ) ;
scr.registerLocalClientRequestDispatcherFactory( lcsf,
ORBConstants.IISC_PERSISTENT_SCID ) ;
lcsf = RequestDispatcherDefault.
makeMinimalServantCacheLocalClientRequestDispatcherFactory( orb ) ;
scr.registerLocalClientRequestDispatcherFactory( lcsf,
ORBConstants.MINSC_TRANSIENT_SCID ) ;
scr.registerLocalClientRequestDispatcherFactory( lcsf,
ORBConstants.MINSC_PERSISTENT_SCID ) ;
/* Register the server delegate that implements the ancient bootstrap
* naming protocol. This takes an object key of either "INIT" or
* "TINI" to allow for big or little endian implementations.
*/
CorbaServerRequestDispatcher bootsd =
RequestDispatcherDefault.makeBootstrapServerRequestDispatcher(
orb ) ;
scr.registerServerRequestDispatcher( bootsd, "INIT" ) ;
scr.registerServerRequestDispatcher( bootsd, "TINI" ) ;
// Register object adapter factories
ObjectAdapterFactory oaf = OADefault.makeTOAFactory( orb ) ;
scr.registerObjectAdapterFactory( oaf, ORBConstants.TOA_SCID ) ;
oaf = OADefault.makePOAFactory( orb ) ;
scr.registerObjectAdapterFactory( oaf, ORBConstants.TRANSIENT_SCID ) ;
scr.registerObjectAdapterFactory( oaf, ORBConstants.PERSISTENT_SCID ) ;
scr.registerObjectAdapterFactory( oaf, ORBConstants.SC_TRANSIENT_SCID ) ;
scr.registerObjectAdapterFactory( oaf, ORBConstants.SC_PERSISTENT_SCID ) ;
scr.registerObjectAdapterFactory( oaf, ORBConstants.IISC_TRANSIENT_SCID ) ;
scr.registerObjectAdapterFactory( oaf, ORBConstants.IISC_PERSISTENT_SCID ) ;
scr.registerObjectAdapterFactory( oaf, ORBConstants.MINSC_TRANSIENT_SCID ) ;
scr.registerObjectAdapterFactory( oaf, ORBConstants.MINSC_PERSISTENT_SCID ) ;
}