Package org.omg.CORBA

Examples of org.omg.CORBA.Any.insert_Streamable()


    {
        BooleanDiscUnion testValue = new BooleanDiscUnion();
        testValue.s("foo");

        Any outAny = setup.getClientOrb().create_any();
        outAny.insert_Streamable(new BooleanDiscUnionHolder(testValue));

        Any inAny = server.bounce_any(outAny);
        assertTrue(outAny.equal(inAny));
    }
View Full Code Here


    {
        CharDiscUnion testValue = new CharDiscUnion();
        testValue.s("foo");

        Any outAny = setup.getClientOrb().create_any();
        outAny.insert_Streamable(new CharDiscUnionHolder(testValue));

        Any inAny = server.bounce_any(outAny);
        assertTrue(outAny.equal(inAny));
    }
View Full Code Here

    {
        EnumDiscUnion testValue = new EnumDiscUnion();
        testValue.s("foo");

        Any outAny = setup.getClientOrb().create_any();
        outAny.insert_Streamable(new EnumDiscUnionHolder(testValue));

        Any inAny = server.bounce_any(outAny);
        assertTrue(outAny.equal(inAny));
    }
View Full Code Here

    public void test_extract_streamable()
    {
        String testValue = "hello world";

        Any outAny = setup.getClientOrb().create_any();
        outAny.insert_Streamable(new StringHolder(testValue));
        Streamable s = outAny.extract_Streamable();
        assertEquals (testValue, ((StringHolder)s).value);

        Any inAny = server.bounce_any(outAny);
        assertTrue (outAny.equal(inAny));
View Full Code Here

        throws Exception
    {
        byte testValue = (byte) 0xFF;

        Any outAny = setup.getClientOrb().create_any();
        outAny.insert_Streamable(new ByteHolder(testValue));
        assertEquals(testValue, outAny.extract_octet());

        Any inAny = server.bounce_any(outAny);

        assertEquals(testValue, inAny.extract_octet());
View Full Code Here

    {
        Any testValue = setup.getClientOrb().create_any();
        testValue.insert_string("foo");

        Any outAny = setup.getClientOrb().create_any();
        outAny.insert_Streamable(new AnyHolder(testValue));
        assertEquals(testValue, outAny.extract_any());

        Any inAny = server.bounce_any(outAny);

        assertEquals(testValue, inAny.extract_any());
View Full Code Here

        throws Exception
    {
        String testValue = "foo";

        Any outAny = setup.getClientOrb().create_any();
        outAny.insert_Streamable(new StringHolder(testValue));
        assertEquals(testValue, outAny.extract_string());

        Any inAny = server.bounce_any(outAny);

        assertEquals(testValue, inAny.extract_string());
View Full Code Here

        throws Exception
    {
        BigDecimal testValue = new BigDecimal("471.1");

        Any outAny = setup.getClientOrb().create_any();
        outAny.insert_Streamable(new FixedHolder(testValue));
        assertEquals(testValue, outAny.extract_fixed());

        Any inAny = server.bounce_any(outAny);

        assertEquals(testValue, inAny.extract_fixed());
View Full Code Here

    @Test
    public void test_object_streamable()
        throws Exception
    {
        Any outAny = setup.getClientOrb().create_any();
        outAny.insert_Streamable(new AnyServerHolder(server));
        assertEquals(server, outAny.extract_Object());

        Any inAny = server.bounce_any(outAny);

        //can't readily test equality of object references
View Full Code Here

        throws Exception
    {
        TypeCode testValue = AnyServerHelper.type();

        Any outAny = setup.getClientOrb().create_any();
        outAny.insert_Streamable(new TypeCodeHolder(testValue));
        assertEquals(testValue, outAny.extract_TypeCode());

        Any inAny = server.bounce_any(outAny);

        assertTrue(testValue.equal(inAny.extract_TypeCode()));
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.