dcp = dcp.substring(index + 1).trim();
rootOid = dcp.trim().trim();
XComponentContext ctx = com.sun.star.comp.helper.Bootstrap.createInitialComponentContext( null );
XMultiComponentFactory smgr = ctx.getServiceManager();
XMultiServiceFactory oldsmgr =
UnoRuntime.queryInterface( XMultiServiceFactory.class, smgr );
// prepare servicemanager
XSet set = UnoRuntime.queryInterface(XSet.class, smgr);
Object o = com.sun.star.comp.bridge.TestComponent.__getServiceFactory(
"com.sun.star.comp.bridge.TestComponent$_TestObject", oldsmgr,null );
set.insert(o);
XAcceptor xAcceptor = Acceptor.create(ctx);
while( true )
{
System.err.println("waiting for connect...");
XConnection xConnection = xAcceptor.accept(conDcp);
XBridgeFactory xBridgeFactory = UnoRuntime.queryInterface(
XBridgeFactory.class,
smgr.createInstanceWithContext("com.sun.star.bridge.BridgeFactory",ctx));
XBridge xBridge = xBridgeFactory.createBridge(
"", protDcp, xConnection, new InstanceProvider(ctx));
if (singleaccept) {