Package org.omg.CORBA

Examples of org.omg.CORBA.TypeCode.kind()


        TypeCode tc = CorbaUtils.getTypeCode(orb, idlType, typeMaps);
        if (CorbaUtils.isPrimitiveIdlType(idlType)) {
            LOG.log(Level.INFO, "Reading primitive type from XML reader");
            obj = readPrimitiveFromStax(reader, idlType, tc);
        } else {
            switch(tc.kind().value()) {
            case TCKind._tk_alias:
                LOG.log(Level.INFO, "Reading alias type from XML reader");
                obj = readAliasFromStax(reader, idlType, tc);
                break;
            case TCKind._tk_array:
View Full Code Here


                writePrimitiveToStax(obj, writer, factory);
            } else {
                startEl = factory.createStartElement(objName, null, null);
                writer.add(startEl);

                switch(tc.kind().value()) {
                // Aliases should never get to this point so we don't need a special alias writer
                case TCKind._tk_array:
                    LOG.log(Level.INFO, "Writing array type to XML writer");
                    writeArrayToStax(obj, writer, factory);
                    break;
View Full Code Here

                //    * signed & unsigned short
                //    * signed & unsigned long
                //    * signed & unsigned long long
                //    * char
                //    * boolean
                switch (discTC.kind().value()) {
                case TCKind._tk_short:
                    member.label.insert_short(Short.parseShort(cs.getLabel()));
                    break;
                case TCKind._tk_ushort:
                    member.label.insert_ushort(Short.parseShort(cs.getLabel()));
View Full Code Here

    {
        // First unmarshal the return value if it is not void
        if ( _result != null ) {
            Any returnAny = _result.value();
            TypeCode returnType = returnAny.type();
            if ( returnType.kind().value() != TCKind._tk_void )
                returnAny.read_value(is, returnType);
        }

        // Now unmarshal the out/inout args
        try {
View Full Code Here

    private TypeCode realType(TypeCode aType) {
        TypeCode realType = aType;
        try {
            // Note: Indirect types are handled in kind() method
            while (realType.kind().value() == TCKind._tk_alias) {
                realType = realType.content_type();
            }
        } catch (BadKind bad) { // impossible
            throw wrapper.badkindCannotOccur( bad ) ;
        }
View Full Code Here

        //    if (AnyImpl.isStreamed[realType.kind().value()]) {
        //        if (otherAny instanceof AnyImpl) {
        //            return ((AnyImpl)otherAny).stream.equals(stream);
        //        }
        //    }
        switch (realType.kind().value()) {
            // handle primitive types
            case TCKind._tk_null:
            case TCKind._tk_void:
                return true;
            case TCKind._tk_short:
View Full Code Here

    private boolean equalMember(TypeCode memberType, InputStream myStream, InputStream otherStream) {
        // Resolve aliases here
        TypeCode realType = realType(memberType);

        try {
            switch (realType.kind().value()) {
                // handle primitive types
                case TCKind._tk_null:
                case TCKind._tk_void:
                    return true;
                case TCKind._tk_short:
View Full Code Here

    private TypeCode realType(TypeCode aType) {
        TypeCode realType = aType;
        try {
            // Note: Indirect types are handled in kind() method
            while (realType.kind().value() == TCKind._tk_alias) {
                realType = realType.content_type();
            }
        } catch (BadKind bad) {
            // impossible
            throw wrapper.badkindCannotOccur() ;
View Full Code Here

        myRealType = realType(myRealType);
        TypeCode otherRealType = realType(tc);

        // If results of the kind operation on each typecode differ,
        // equivalent returns false.
        if (myRealType.kind().value() != otherRealType.kind().value()) {
            return false;
        }

        String myID = null;
        String otherID = null;
View Full Code Here

    }

    private boolean isCustomType(ValueHelper helper) {
        try{
            TypeCode tc = helper.get_type();
            int kind = tc.kind().value();
            if (kind == TCKind._tk_value) {
                return (tc.type_modifier() == org.omg.CORBA.VM_CUSTOM.value);
            }
        } catch(BadKind ex) {
            throw wrapper.badKind(ex) ;
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.