Examples of POA


Examples of org.omg.PortableServer.POA

     */
    class ServantRegistryWithTransientPOAPerServant implements ServantRegistry {

        public ReferenceFactory bind(final String name, final Servant servant, final Policy[] policies) throws Exception {
            final Policy[] poaPolicies = concatPolicies(transientPoaPolicies, policies);
            final POA poa = rootPOA.getValue().create_POA(name, null, poaPolicies);
            transientPoaMap.put(name, poa);
            poa.set_servant(servant);
            poa.the_POAManager().activate();
            return new PoaReferenceFactory(poa); // no servantName: in this case
            // name is the POA name
        }
View Full Code Here

Examples of org.omg.PortableServer.POA

            return new PoaReferenceFactory(poa); // no servantName: in this case
            // name is the POA name
        }

        public ReferenceFactory bind(final String name, final Servant servant) throws Exception {
            final POA poa = rootPOA.getValue().create_POA(name, null, transientPoaPolicies);
            transientPoaMap.put(name, poa);
            poa.set_servant(servant);
            poa.the_POAManager().activate();
            return new PoaReferenceFactory(poa); // no servantName: in this case
            // name is the POA name
        }
View Full Code Here

Examples of org.omg.PortableServer.POA

            return new PoaReferenceFactory(poa); // no servantName: in this case
            // name is the POA name
        }

        public void unbind(final String name) throws Exception {
            final POA poa = transientPoaMap.remove(name);
            if (poa != null) {
                poa.the_POAManager().deactivate(false, true);
                poa.destroy(false, false);
            }
        }
View Full Code Here

Examples of org.omg.PortableServer.POA

     */
    class ServantRegistryWithPersistentPOAPerServant implements ServantRegistry {

        public ReferenceFactory bind(final String name, final Servant servant, final Policy[] policies) throws Exception {
            final Policy[] poaPolicies = concatPolicies(persistentPoaPolicies, policies);
            final POA poa = rootPOA.getValue().create_POA(name, null, poaPolicies);
            persistentPoaMap.put(name, poa);
            poa.set_servant(servant);
            poa.the_POAManager().activate();
            return new PoaReferenceFactory(poa); // no servantName: in this case
            // name is the POA name
        }
View Full Code Here

Examples of org.omg.PortableServer.POA

            return new PoaReferenceFactory(poa); // no servantName: in this case
            // name is the POA name
        }

        public ReferenceFactory bind(final String name, final Servant servant) throws Exception {
            final POA poa = rootPOA.getValue().create_POA(name, null, persistentPoaPolicies);
            persistentPoaMap.put(name, poa);
            poa.set_servant(servant);
            poa.the_POAManager().activate();
            return new PoaReferenceFactory(poa); // no servantName: in this case
            // name is the POA name
        }
View Full Code Here

Examples of org.omg.PortableServer.POA

            return new PoaReferenceFactory(poa); // no servantName: in this case
            // name is the POA name
        }

        public void unbind(final String name) throws Exception {
            final POA poa = persistentPoaMap.remove(name);
            if (poa != null) {
                poa.the_POAManager().deactivate(false, true);
                poa.destroy(false, false);
            }
        }
View Full Code Here

Examples of org.omg.PortableServer.POA

    /**
     * Unexport this object.
     */
    public void shutdown() {
        POA poa = getPOA();
        try {
            poa.deactivate_object(poa.reference_to_id(getReference()));
        } catch (UserException ex) {
            JacORBLogger.ROOT_LOGGER.warnCouldNotDeactivateIRObject(ex);
        }
    }
View Full Code Here

Examples of org.omg.PortableServer.POA

     * @exception TransientServiceException
     */
    public void initialize(ORB orb) throws TransientServiceException {
        try {
            // get the root POA.  We're going to re
            POA rootPOA = (POA) orb.resolve_initial_references("RootPOA");
            rootPOA.the_POAManager().activate();

            // we need to create a POA to manage this named instance, and then activate
            // a context on it.
            Policy[] policy = new Policy[3];
            policy[0] = rootPOA.create_lifespan_policy(LifespanPolicyValue.TRANSIENT);
            policy[1] = rootPOA.create_id_assignment_policy(IdAssignmentPolicyValue.SYSTEM_ID);
            policy[2] = rootPOA.create_servant_retention_policy(ServantRetentionPolicyValue.RETAIN);

            POA nameServicePOA = rootPOA.create_POA("TNameService", null, policy );
            nameServicePOA.the_POAManager().activate();

            // create our initial context, and register that with the ORB as the name service
            initialContext = new TransientNamingContext(orb, nameServicePOA);

            //
View Full Code Here

Examples of org.omg.PortableServer.POA

            {
                orb_.run();
            }
        };

        final POA _poa = POAHelper.narrow(orb_.resolve_initial_references("RootPOA"));
        _poa.the_POAManager().activate();

        _orbRunner.start();
    }
View Full Code Here

Examples of org.omg.PortableServer.POA

    public synchronized void deactivate()
    {
        if (thisServant_ != null)
        {
            final POA _poa = delegate_.getPOA();
            try
            {
                final byte[] _oid = _poa.servant_to_id(thisServant_);
                delegate_.getPOA().deactivate_object(_oid);
            }
            catch (WrongPolicy e)
            {
                throw new RuntimeException();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.