Package org.jacorb.orb

Examples of org.jacorb.orb.CDROutputStream.write_string()


        try
        {
            if( type().kind().value() == org.omg.CORBA.TCKind._tk_except )
            {
                out.write_string( exceptionMsg );
            }

            for( int i = 0; i < members.length; i++)
            {
                out.write_value( members[i].value.type(),
View Full Code Here


        CDROutputStream out = new CDROutputStream();

        if( type().kind().value() == org.omg.CORBA.TCKind._tk_except )
        {
            out.write_string( exceptionMsg );
        }

        for( int i = 0; i < members.length; i++)
        {
            out.write_value( members[i].value.type(),
View Full Code Here

    {
        org.omg.CORBA.ORB myorb = setup.getClientOrb();

        CDROutputStream t1 = new CDROutputStream(myorb);

        t1.write_string(UNI1);

        CDRInputStream t2 = new CDRInputStream (myorb, t1.getBufferCopy());

        String result = t2.read_string();
View Full Code Here

    }

    private String marshal(String input)
    {
        CDROutputStream out = (CDROutputStream) orb.create_output_stream();
        out.write_string(input);

        byte[] buffer = out.getBufferCopy();

        CDRInputStream in = new CDRInputStream(buffer);
        String result = in.read_string();
View Full Code Here

        try
        {
            if( type().kind().value() == org.omg.CORBA.TCKind._tk_except )
            {
                out.write_string( exceptionMsg );
            }

            for( int i = 0; i < members.length; i++)
            {
                out.write_value( members[i].value.type(),
View Full Code Here

    }

    private String marshal(String input)
    {
        CDROutputStream out = (CDROutputStream) orb.create_output_stream();
        out.write_string(input);

        byte[] buffer = out.getBufferCopy();

        CDRInputStream in = new CDRInputStream(buffer);
        String result = in.read_string();
View Full Code Here

        try
        {
            if( type().kind().value() == org.omg.CORBA.TCKind._tk_except )
            {
                out.write_string( exceptionMsg );
            }

            for( int i = 0; i < members.length; i++)
            {
                out.write_value( members[i].value.type(),
View Full Code Here

        ExceptionHolder eh = new ExceptionHolderImpl ((org.jacorb.orb.ORB)setup.getClientOrb ());
        try
        {
            final Field fields[] = ExceptionHolder.class.getDeclaredFields();
            CDROutputStream cdr = new CDROutputStream (setup.getClientOrb ());
            cdr.write_string ("Dummy_id");

            for (int i = 0; i < fields.length; ++i)
            {
                if ("marshaled_exception".equals(fields[i].getName()))
                {
View Full Code Here

        String source = "\ud801\udc49";
        byte[] sourceMatch = { (byte) 0xf0, (byte) 0x90, (byte) 0x91, (byte) 0x89 };
        assertTrue(length(source) == sourceMatch.length);
        assertTrue(length(source) == source.getBytes(getORB().getTCSDefault().getName()).length);

        cdrOutputStream.write_string(source);

        byte[] bufferCopy = cdrOutputStream.getBufferCopy();
        byte[] toMatch = new byte[sourceMatch.length];
        System.arraycopy(bufferCopy, 4, toMatch, 0, sourceMatch.length);
View Full Code Here

    @Test
    public void testWriteNullString() throws Exception
    {
        CDROutputStream cdr = new CDROutputStream (orb);
        cdr.write_string(null);
        cdr.write_boolean(true);
        cdr.write_string(null);
        cdr.write_string("TEST");

        CDRInputStream read = (CDRInputStream)cdr.create_input_stream();
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.