org.omg.PortableServer.POAManager Java Examples
The following examples show how to use
org.omg.PortableServer.POAManager.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: POAFactory.java From openjdk-8-source with GNU General Public License v2.0 | 6 votes |
public void shutdown( boolean waitForCompletion ) { // It is important to copy the list of POAManagers first because // pm.deactivate removes itself from poaManagers! Iterator managers = null ; synchronized (this) { isShuttingDown = true ; managers = (new HashSet(poaManagers)).iterator(); } while ( managers.hasNext() ) { try { ((POAManager)managers.next()).deactivate(true, waitForCompletion); } catch ( org.omg.PortableServer.POAManagerPackage.AdapterInactive e ) {} } }
Example #2
Source File: POAFactory.java From JDKSourceCode1.8 with MIT License | 6 votes |
public void shutdown( boolean waitForCompletion ) { // It is important to copy the list of POAManagers first because // pm.deactivate removes itself from poaManagers! Iterator managers = null ; synchronized (this) { isShuttingDown = true ; managers = (new HashSet(poaManagers)).iterator(); } while ( managers.hasNext() ) { try { ((POAManager)managers.next()).deactivate(true, waitForCompletion); } catch ( org.omg.PortableServer.POAManagerPackage.AdapterInactive e ) {} } }
Example #3
Source File: POAFactory.java From openjdk-jdk9 with GNU General Public License v2.0 | 6 votes |
public void shutdown( boolean waitForCompletion ) { // It is important to copy the list of POAManagers first because // pm.deactivate removes itself from poaManagers! Iterator managers = null ; synchronized (this) { isShuttingDown = true ; managers = (new HashSet(poaManagers)).iterator(); } while ( managers.hasNext() ) { try { ((POAManager)managers.next()).deactivate(true, waitForCompletion); } catch ( org.omg.PortableServer.POAManagerPackage.AdapterInactive e ) {} } }
Example #4
Source File: StubAdapter.java From hottub with GNU General Public License v2.0 | 6 votes |
/** Use implicit activation to get an object reference for the servant. */ public static org.omg.CORBA.Object activateServant( Servant servant ) { POA poa = servant._default_POA() ; org.omg.CORBA.Object ref = null ; try { ref = poa.servant_to_reference( servant ) ; } catch (ServantNotActive sna) { throw wrapper.getDelegateServantNotActive( sna ) ; } catch (WrongPolicy wp) { throw wrapper.getDelegateWrongPolicy( wp ) ; } // Make sure that the POAManager is activated if no other // POAManager state management has taken place. POAManager mgr = poa.the_POAManager() ; if (mgr instanceof POAManagerImpl) { POAManagerImpl mgrImpl = (POAManagerImpl)mgr ; mgrImpl.implicitActivation() ; } return ref ; }
Example #5
Source File: StubAdapter.java From JDKSourceCode1.8 with MIT License | 6 votes |
/** Use implicit activation to get an object reference for the servant. */ public static org.omg.CORBA.Object activateServant( Servant servant ) { POA poa = servant._default_POA() ; org.omg.CORBA.Object ref = null ; try { ref = poa.servant_to_reference( servant ) ; } catch (ServantNotActive sna) { throw wrapper.getDelegateServantNotActive( sna ) ; } catch (WrongPolicy wp) { throw wrapper.getDelegateWrongPolicy( wp ) ; } // Make sure that the POAManager is activated if no other // POAManager state management has taken place. POAManager mgr = poa.the_POAManager() ; if (mgr instanceof POAManagerImpl) { POAManagerImpl mgrImpl = (POAManagerImpl)mgr ; mgrImpl.implicitActivation() ; } return ref ; }
Example #6
Source File: StubAdapter.java From openjdk-jdk9 with GNU General Public License v2.0 | 6 votes |
/** Use implicit activation to get an object reference for the servant. */ public static org.omg.CORBA.Object activateServant( Servant servant ) { POA poa = servant._default_POA() ; org.omg.CORBA.Object ref = null ; try { ref = poa.servant_to_reference( servant ) ; } catch (ServantNotActive sna) { throw wrapper.getDelegateServantNotActive( sna ) ; } catch (WrongPolicy wp) { throw wrapper.getDelegateWrongPolicy( wp ) ; } // Make sure that the POAManager is activated if no other // POAManager state management has taken place. POAManager mgr = poa.the_POAManager() ; if (mgr instanceof POAManagerImpl) { POAManagerImpl mgrImpl = (POAManagerImpl)mgr ; mgrImpl.implicitActivation() ; } return ref ; }
Example #7
Source File: POAFactory.java From hottub with GNU General Public License v2.0 | 6 votes |
public void shutdown( boolean waitForCompletion ) { // It is important to copy the list of POAManagers first because // pm.deactivate removes itself from poaManagers! Iterator managers = null ; synchronized (this) { isShuttingDown = true ; managers = (new HashSet(poaManagers)).iterator(); } while ( managers.hasNext() ) { try { ((POAManager)managers.next()).deactivate(true, waitForCompletion); } catch ( org.omg.PortableServer.POAManagerPackage.AdapterInactive e ) {} } }
Example #8
Source File: POAFactory.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
public void shutdown( boolean waitForCompletion ) { // It is important to copy the list of POAManagers first because // pm.deactivate removes itself from poaManagers! Iterator managers = null ; synchronized (this) { isShuttingDown = true ; managers = (new HashSet(poaManagers)).iterator(); } while ( managers.hasNext() ) { try { ((POAManager)managers.next()).deactivate(true, waitForCompletion); } catch ( org.omg.PortableServer.POAManagerPackage.AdapterInactive e ) {} } }
Example #9
Source File: StubAdapter.java From openjdk-8-source with GNU General Public License v2.0 | 6 votes |
/** Use implicit activation to get an object reference for the servant. */ public static org.omg.CORBA.Object activateServant( Servant servant ) { POA poa = servant._default_POA() ; org.omg.CORBA.Object ref = null ; try { ref = poa.servant_to_reference( servant ) ; } catch (ServantNotActive sna) { throw wrapper.getDelegateServantNotActive( sna ) ; } catch (WrongPolicy wp) { throw wrapper.getDelegateWrongPolicy( wp ) ; } // Make sure that the POAManager is activated if no other // POAManager state management has taken place. POAManager mgr = poa.the_POAManager() ; if (mgr instanceof POAManagerImpl) { POAManagerImpl mgrImpl = (POAManagerImpl)mgr ; mgrImpl.implicitActivation() ; } return ref ; }
Example #10
Source File: StubAdapter.java From openjdk-jdk8u with GNU General Public License v2.0 | 6 votes |
/** Use implicit activation to get an object reference for the servant. */ public static org.omg.CORBA.Object activateServant( Servant servant ) { POA poa = servant._default_POA() ; org.omg.CORBA.Object ref = null ; try { ref = poa.servant_to_reference( servant ) ; } catch (ServantNotActive sna) { throw wrapper.getDelegateServantNotActive( sna ) ; } catch (WrongPolicy wp) { throw wrapper.getDelegateWrongPolicy( wp ) ; } // Make sure that the POAManager is activated if no other // POAManager state management has taken place. POAManager mgr = poa.the_POAManager() ; if (mgr instanceof POAManagerImpl) { POAManagerImpl mgrImpl = (POAManagerImpl)mgr ; mgrImpl.implicitActivation() ; } return ref ; }
Example #11
Source File: StubAdapter.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
/** Use implicit activation to get an object reference for the servant. */ public static org.omg.CORBA.Object activateServant( Servant servant ) { POA poa = servant._default_POA() ; org.omg.CORBA.Object ref = null ; try { ref = poa.servant_to_reference( servant ) ; } catch (ServantNotActive sna) { throw wrapper.getDelegateServantNotActive( sna ) ; } catch (WrongPolicy wp) { throw wrapper.getDelegateWrongPolicy( wp ) ; } // Make sure that the POAManager is activated if no other // POAManager state management has taken place. POAManager mgr = poa.the_POAManager() ; if (mgr instanceof POAManagerImpl) { POAManagerImpl mgrImpl = (POAManagerImpl)mgr ; mgrImpl.implicitActivation() ; } return ref ; }
Example #12
Source File: StubAdapter.java From openjdk-8 with GNU General Public License v2.0 | 6 votes |
/** Use implicit activation to get an object reference for the servant. */ public static org.omg.CORBA.Object activateServant( Servant servant ) { POA poa = servant._default_POA() ; org.omg.CORBA.Object ref = null ; try { ref = poa.servant_to_reference( servant ) ; } catch (ServantNotActive sna) { throw wrapper.getDelegateServantNotActive( sna ) ; } catch (WrongPolicy wp) { throw wrapper.getDelegateWrongPolicy( wp ) ; } // Make sure that the POAManager is activated if no other // POAManager state management has taken place. POAManager mgr = poa.the_POAManager() ; if (mgr instanceof POAManagerImpl) { POAManagerImpl mgrImpl = (POAManagerImpl)mgr ; mgrImpl.implicitActivation() ; } return ref ; }
Example #13
Source File: POAFactory.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
public void shutdown( boolean waitForCompletion ) { // It is important to copy the list of POAManagers first because // pm.deactivate removes itself from poaManagers! Iterator managers = null ; synchronized (this) { isShuttingDown = true ; managers = (new HashSet(poaManagers)).iterator(); } while ( managers.hasNext() ) { try { ((POAManager)managers.next()).deactivate(true, waitForCompletion); } catch ( org.omg.PortableServer.POAManagerPackage.AdapterInactive e ) {} } }
Example #14
Source File: POAFactory.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
public void shutdown( boolean waitForCompletion ) { // It is important to copy the list of POAManagers first because // pm.deactivate removes itself from poaManagers! Iterator managers = null ; synchronized (this) { isShuttingDown = true ; managers = (new HashSet(poaManagers)).iterator(); } while ( managers.hasNext() ) { try { ((POAManager)managers.next()).deactivate(true, waitForCompletion); } catch ( org.omg.PortableServer.POAManagerPackage.AdapterInactive e ) {} } }
Example #15
Source File: POAFactory.java From openjdk-8 with GNU General Public License v2.0 | 6 votes |
public void shutdown( boolean waitForCompletion ) { // It is important to copy the list of POAManagers first because // pm.deactivate removes itself from poaManagers! Iterator managers = null ; synchronized (this) { isShuttingDown = true ; managers = (new HashSet(poaManagers)).iterator(); } while ( managers.hasNext() ) { try { ((POAManager)managers.next()).deactivate(true, waitForCompletion); } catch ( org.omg.PortableServer.POAManagerPackage.AdapterInactive e ) {} } }
Example #16
Source File: StubAdapter.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
/** Use implicit activation to get an object reference for the servant. */ public static org.omg.CORBA.Object activateServant( Servant servant ) { POA poa = servant._default_POA() ; org.omg.CORBA.Object ref = null ; try { ref = poa.servant_to_reference( servant ) ; } catch (ServantNotActive sna) { throw wrapper.getDelegateServantNotActive( sna ) ; } catch (WrongPolicy wp) { throw wrapper.getDelegateWrongPolicy( wp ) ; } // Make sure that the POAManager is activated if no other // POAManager state management has taken place. POAManager mgr = poa.the_POAManager() ; if (mgr instanceof POAManagerImpl) { POAManagerImpl mgrImpl = (POAManagerImpl)mgr ; mgrImpl.implicitActivation() ; } return ref ; }
Example #17
Source File: StubAdapter.java From jdk1.8-source-analysis with Apache License 2.0 | 6 votes |
/** Use implicit activation to get an object reference for the servant. */ public static org.omg.CORBA.Object activateServant( Servant servant ) { POA poa = servant._default_POA() ; org.omg.CORBA.Object ref = null ; try { ref = poa.servant_to_reference( servant ) ; } catch (ServantNotActive sna) { throw wrapper.getDelegateServantNotActive( sna ) ; } catch (WrongPolicy wp) { throw wrapper.getDelegateWrongPolicy( wp ) ; } // Make sure that the POAManager is activated if no other // POAManager state management has taken place. POAManager mgr = poa.the_POAManager() ; if (mgr instanceof POAManagerImpl) { POAManagerImpl mgrImpl = (POAManagerImpl)mgr ; mgrImpl.implicitActivation() ; } return ref ; }
Example #18
Source File: POAFactory.java From openjdk-jdk8u with GNU General Public License v2.0 | 6 votes |
public void shutdown( boolean waitForCompletion ) { // It is important to copy the list of POAManagers first because // pm.deactivate removes itself from poaManagers! Iterator managers = null ; synchronized (this) { isShuttingDown = true ; managers = (new HashSet(poaManagers)).iterator(); } while ( managers.hasNext() ) { try { ((POAManager)managers.next()).deactivate(true, waitForCompletion); } catch ( org.omg.PortableServer.POAManagerPackage.AdapterInactive e ) {} } }
Example #19
Source File: POAFactory.java From jdk1.8-source-analysis with Apache License 2.0 | 6 votes |
public void shutdown( boolean waitForCompletion ) { // It is important to copy the list of POAManagers first because // pm.deactivate removes itself from poaManagers! Iterator managers = null ; synchronized (this) { isShuttingDown = true ; managers = (new HashSet(poaManagers)).iterator(); } while ( managers.hasNext() ) { try { ((POAManager)managers.next()).deactivate(true, waitForCompletion); } catch ( org.omg.PortableServer.POAManagerPackage.AdapterInactive e ) {} } }
Example #20
Source File: StubAdapter.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
/** Use implicit activation to get an object reference for the servant. */ public static org.omg.CORBA.Object activateServant( Servant servant ) { POA poa = servant._default_POA() ; org.omg.CORBA.Object ref = null ; try { ref = poa.servant_to_reference( servant ) ; } catch (ServantNotActive sna) { throw wrapper.getDelegateServantNotActive( sna ) ; } catch (WrongPolicy wp) { throw wrapper.getDelegateWrongPolicy( wp ) ; } // Make sure that the POAManager is activated if no other // POAManager state management has taken place. POAManager mgr = poa.the_POAManager() ; if (mgr instanceof POAManagerImpl) { POAManagerImpl mgrImpl = (POAManagerImpl)mgr ; mgrImpl.implicitActivation() ; } return ref ; }
Example #21
Source File: POAImpl.java From TencentKona-8 with GNU General Public License v2.0 | 5 votes |
/** * <code>the_POAManager</code> * <b>Section 3.3.8.8</b> */ public POAManager the_POAManager() { try { lock() ; return manager; } finally { unlock() ; } }
Example #22
Source File: POAImpl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 5 votes |
/** * <code>the_POAManager</code> * <b>Section 3.3.8.8</b> */ public POAManager the_POAManager() { try { lock() ; return manager; } finally { unlock() ; } }
Example #23
Source File: POAImpl.java From openjdk-jdk9 with GNU General Public License v2.0 | 5 votes |
/** * <code>the_POAManager</code> * <b>Section 3.3.8.8</b> */ public POAManager the_POAManager() { try { lock() ; return manager; } finally { unlock() ; } }
Example #24
Source File: POAImpl.java From hottub with GNU General Public License v2.0 | 5 votes |
/** * <code>the_POAManager</code> * <b>Section 3.3.8.8</b> */ public POAManager the_POAManager() { try { lock() ; return manager; } finally { unlock() ; } }
Example #25
Source File: POAImpl.java From openjdk-8-source with GNU General Public License v2.0 | 5 votes |
/** * <code>the_POAManager</code> * <b>Section 3.3.8.8</b> */ public POAManager the_POAManager() { try { lock() ; return manager; } finally { unlock() ; } }
Example #26
Source File: POAImpl.java From openjdk-8 with GNU General Public License v2.0 | 5 votes |
/** * <code>the_POAManager</code> * <b>Section 3.3.8.8</b> */ public POAManager the_POAManager() { try { lock() ; return manager; } finally { unlock() ; } }
Example #27
Source File: Server.java From cxf with Apache License 2.0 | 5 votes |
static int run(ORB orb, String[] args) throws UserException { // // Resolve Root POA // POA poa = POAHelper.narrow(orb.resolve_initial_references("RootPOA")); // // Get a reference to the POA manager // POAManager manager = poa.the_POAManager(); // // Create implementation object // BankImpl bankImpl = new BankImpl(poa); byte[] oid = "Bank".getBytes(); poa.activate_object_with_id(oid, bankImpl); org.omg.CORBA.Object ref = poa.create_reference_with_id(oid, BankHelper.id()); // Register in NameService org.omg.CORBA.Object nsObj = orb.resolve_initial_references("NameService"); NamingContextExt rootContext = NamingContextExtHelper.narrow(nsObj); NameComponent[] nc = rootContext.to_name("Bank"); rootContext.rebind(nc, ref); // // Run implementation // manager.activate(); System.out.println("Server ready..."); orb.run(); return 0; }
Example #28
Source File: Server.java From cxf with Apache License 2.0 | 5 votes |
static int run(ORB orb, String[] args) throws UserException { // Resolve Root POA POA poa = POAHelper.narrow(orb.resolve_initial_references("RootPOA")); // Get a reference to the POA manager POAManager manager = poa.the_POAManager(); // Create implementation object HelloWorldImpl hwImpl = new HelloWorldImpl(poa); byte[] oid = "HelloWorld".getBytes(); poa.activate_object_with_id(oid, hwImpl); org.omg.CORBA.Object ref = poa.create_reference_with_id(oid, HelloWorldHelper.id()); // Register in NameService org.omg.CORBA.Object nsObj = orb.resolve_initial_references("NameService"); NamingContextExt rootContext = NamingContextExtHelper.narrow(nsObj); NameComponent[] nc = rootContext.to_name("HelloWorld"); rootContext.rebind(nc, ref); // Run implementation manager.activate(); System.out.println("Server ready..."); orb.run(); return 0; }
Example #29
Source File: CorbaDestination.java From cxf with Apache License 2.0 | 5 votes |
protected POA createPOA(String name, POA parentPOA, POAManager poaManager) { List<Policy> policies = new ArrayList<>(); policies.add(parentPOA .create_thread_policy(ThreadPolicyValue.ORB_CTRL_MODEL)); if (isPersistent) { policies.add(parentPOA .create_lifespan_policy(LifespanPolicyValue.PERSISTENT)); } else { policies.add(parentPOA .create_lifespan_policy(LifespanPolicyValue.TRANSIENT)); } if (serviceId != null) { policies.add(parentPOA .create_id_assignment_policy(IdAssignmentPolicyValue.USER_ID)); } policies.add(parentPOA.create_id_uniqueness_policy(IdUniquenessPolicyValue.MULTIPLE_ID)); RequestProcessingPolicyValue value = RequestProcessingPolicyValue.USE_DEFAULT_SERVANT; policies.add(parentPOA.create_request_processing_policy(value)); orbConfig.addPOAPolicies(orb, name, parentPOA, poaManager, policies); Policy[] policyList = policies.toArray(new Policy[0]); try { return parentPOA.create_POA(name, poaManager, policyList); } catch (Exception ex) { throw new CorbaBindingException( "Could not create POA during activation", ex); } }
Example #30
Source File: OrbConfig.java From cxf with Apache License 2.0 | 5 votes |
public void addPOAPolicies(ORB orb, String poaName, POA parentPOA, POAManager poaManager, List<Policy> policies) { //nothing }