Package org.omg.RTCORBA

Examples of org.omg.RTCORBA.ClientProtocolPolicy


    public void testClientProtocolPolicyWIOP() throws Exception
    {
        RTORB rtORB = RTORBHelper.narrow(clientOrb.resolve_initial_references("RTORB"));

        ClientProtocolPolicy policy = rtORB.create_client_protocol_policy(new Protocol[] {new Protocol(new WIOPFactories().profile_tag(), null, null)});

        basicServer._set_policy_override(new Policy[] {policy}, SetOverrideType.SET_OVERRIDE);

        basicServer.ping();
        assertTrue("should use WIOP as transport", WIOPFactories.isTransportInUse());
View Full Code Here


    public void testClientProtocolPolicyIIOP() throws Exception
    {
        RTORB rtORB = RTORBHelper.narrow(clientOrb.resolve_initial_references("RTORB"));

        ClientProtocolPolicy policy = rtORB.create_client_protocol_policy(new Protocol[] {new Protocol(ORBConstants.JAC_NOSSL_PROFILE_ID, null, null)});

        basicServer._set_policy_override(new Policy[] {policy}, SetOverrideType.SET_OVERRIDE);

        basicServer.ping();
View Full Code Here

    {
        if (protocols != null)
        {
            org.omg.CORBA.Object target = ri.effective_target ();

            ClientProtocolPolicy cpp = orb.create_client_protocol_policy(protocols);

            Policy[] policies = new Policy[] {cpp};

            org.omg.CORBA.Object rebindTo = target._set_policy_override (policies, SetOverrideType.SET_OVERRIDE);
View Full Code Here

    public void testClientProtocolPolicy()
    {
        Protocol[] protocols = new Protocol[] { };
        Any value = create_any();
        ProtocolListHelper.insert (value, protocols);
        ClientProtocolPolicy p = (ClientProtocolPolicy)create_policy
        (
            CLIENT_PROTOCOL_POLICY_TYPE.value,
            value
        );
        assertEquals (p.policy_type(), CLIENT_PROTOCOL_POLICY_TYPE.value);

        ClientProtocolPolicy p2 = (ClientProtocolPolicy)p.copy();

        // accessing the tag does not work when the protocols list is empty
        // assertEquals (((org.jacorb.orb.policies.ClientProtocolPolicy)p).tag(),
        //              ((org.jacorb.orb.policies.ClientProtocolPolicy)p2).tag());
        assertTrue ("Protocols do not match", p.protocols().equals(p2.protocols()));
        p.destroy();
        p2.destroy();
    }
View Full Code Here

    @Test
    public void testClientProtocolPolicyWIOP() throws Exception
    {
        RTORB rtORB = RTORBHelper.narrow(clientOrb.resolve_initial_references("RTORB"));

        ClientProtocolPolicy policy = rtORB.create_client_protocol_policy(new Protocol[] {new Protocol(new WIOPFactories().profile_tag(), null, null)});

        basicServer = BasicServerHelper.narrow (basicServer._set_policy_override
                (new Policy[] {policy}, SetOverrideType.SET_OVERRIDE));

        basicServer.ping();
View Full Code Here

    @Test
    public void testClientProtocolPolicyIIOP() throws Exception
    {
        RTORB rtORB = RTORBHelper.narrow(clientOrb.resolve_initial_references("RTORB"));

        ClientProtocolPolicy policy = rtORB.create_client_protocol_policy(new Protocol[] {new Protocol(ORBConstants.JAC_NOSSL_PROFILE_ID, null, null)});

        basicServer = BasicServerHelper.narrow (basicServer._set_policy_override
                (new Policy[] {policy}, SetOverrideType.SET_OVERRIDE));

        basicServer.ping();
View Full Code Here

TOP

Related Classes of org.omg.RTCORBA.ClientProtocolPolicy

Copyright © 2018 www.massapicom. 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.