Package org.omg.CORBA.portable

Examples of org.omg.CORBA.portable.InputStream.read_long()


        OutputStream oStream = new OutputStream(buf);
        CorbaObjectWriter writer =  new CorbaObjectWriter(oStream);
        writer.writeSequence(obj);
       
        InputStream iStream = oStream.create_input_stream();
        int length = iStream.read_long();
        for (int i = 0; i < length; ++i) {
            String val = iStream.read_string();
            assertTrue(val.equals(data[i]));
        }
    }
View Full Code Here


        OutputStream oStream = new OutputStream(buf);
        CorbaObjectWriter writer = new CorbaObjectWriter(oStream);
        writer.writeStruct(obj);
       
        InputStream iStream = oStream.create_input_stream();
        int readMember1 = iStream.read_long();
        assertTrue(readMember1 == member1);
        String readMember2 = iStream.read_string();
        assertTrue(readMember2.equals(member2));
        boolean readMember3 = iStream.read_boolean();
        assertTrue(readMember3 == member3);
View Full Code Here

        ServiceContextHelper.write( outputStream, service_context );
        inputStream = outputStream.create_input_stream();

        // Constructor expects id to already have been read from stream.
        coreServiceContext = new UnknownServiceContext(
            inputStream.read_long(),
            (org.omg.CORBA_2_3.portable.InputStream)inputStream );

        id = coreServiceContext.getId();

        if (serviceContexts.get(id) != null)
View Full Code Here

            input = any.create_input_stream();
        } catch (BAD_OPERATION e) {
            return false;
        }

        length = input.read_long();
        components = new DynAny[length];
        anys = new Any[length];

        for (int i=0; i<length; i++) {
            // _REVISIT_ Could use read_xxx_array() methods on InputStream for efficiency
View Full Code Here

        java.util.Set result = new java.util.HashSet() ;

        try {
            inStream = invoke( "list", null ) ;

            int count = inStream.read_long();
            for (int i=0; i < count; i++)
                result.add( inStream.read_string() ) ;

            // NOTE: do note trap and ignore errors.
            // Let them flow out.
View Full Code Here

        OutputStream ostr = StubAdapter.getORB( obj ).create_output_stream();
        ostr.write_Object(obj);
        InputStream istr = ostr.create_input_stream();

        // read the IOR components back from the stream
        int typeLength = istr.read_long();
        typeData = new byte[typeLength];
        istr.read_octet_array(typeData, 0, typeLength);
        int numProfiles = istr.read_long();
        profileTags = new int[numProfiles];
        profileData = new byte[numProfiles][];
View Full Code Here

        // read the IOR components back from the stream
        int typeLength = istr.read_long();
        typeData = new byte[typeLength];
        istr.read_octet_array(typeData, 0, typeLength);
        int numProfiles = istr.read_long();
        profileTags = new int[numProfiles];
        profileData = new byte[numProfiles][];
        for (int i = 0; i < numProfiles; i++) {
            profileTags[i] = istr.read_long();
            profileData[i] = new byte[istr.read_long()];
View Full Code Here

        istr.read_octet_array(typeData, 0, typeLength);
        int numProfiles = istr.read_long();
        profileTags = new int[numProfiles];
        profileData = new byte[numProfiles][];
        for (int i = 0; i < numProfiles; i++) {
            profileTags[i] = istr.read_long();
            profileData[i] = new byte[istr.read_long()];
            istr.read_octet_array(profileData[i], 0, profileData[i].length);
        }
    }
View Full Code Here

        int numProfiles = istr.read_long();
        profileTags = new int[numProfiles];
        profileData = new byte[numProfiles][];
        for (int i = 0; i < numProfiles; i++) {
            profileTags[i] = istr.read_long();
            profileData[i] = new byte[istr.read_long()];
            istr.read_octet_array(profileData[i], 0, profileData[i].length);
        }
    }

    public Delegate getDelegate( ORB orb )
View Full Code Here

        SystemException exception = null;
        Any any = ri.received_exception();
        InputStream strm = any.create_input_stream();
        String repId = ri.received_exception_id();
        strm.read_string(); // read repId
        int minorCode = strm.read_long(); // read minorCode
        CompletionStatus completionStatus = // read completionStatus
            CompletionStatus.from_int(strm.read_long());
        if (repId.indexOf("UNKNOWN") != -1) { // user exception ?
      if (minorCode == 1) { // read minorCode
                // user exception
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.