Examples of XmlSchemaObject


Examples of org.apache.ws.commons.schema.XmlSchemaObject

        } else {
            // We need to get annotation information for the schema type we are about to pass in.
            // This is used to produce the correct object reference type.
            List<XmlSchema> schemaList = wsdlToCorbaBinding.getHelper().getXMLSchemaList();
            Iterator<XmlSchema> schemaIterator = schemaList.iterator();
            XmlSchemaObject schemaObj = null;
            while (schemaIterator.hasNext()) {
                XmlSchema s = schemaIterator.next();
                XmlSchemaObjectTable schemaTable = s.getElements();
                schemaObj = schemaTable.getItem(typeName);
                if (schemaObj != null) {
View Full Code Here

Examples of org.apache.ws.commons.schema.XmlSchemaObject

        List<MemberType> structMembers = structType.getMember();

        XmlSchemaObjectCollection attrs = null;
        XmlSchemaObjectCollection members = null;
           
        XmlSchemaObject stype = schemaType;
        QName qname = name;
        if (schemaType instanceof XmlSchemaElement) {
            XmlSchemaElement el = (XmlSchemaElement) schemaType;
            if (el.getQName() != null) {
                qname = el.getQName();
            }
            stype = el.getSchemaType();
            if (stype == null) {
                stype = CorbaUtils.getXmlSchemaType(serviceInfo, el.getRefName());
            }
        }
        if (stype instanceof XmlSchemaComplexType) {
            XmlSchemaComplexType ctype = (XmlSchemaComplexType) stype;
            if (ctype.getQName() != null) {
                qname = ctype.getQName();
            }
            attrs = ctype.getAttributes();
            stype = ctype.getParticle();
        }
        if (stype instanceof XmlSchemaGroupRef) {
            members = ((XmlSchemaGroupRef) stype).getParticle().getItems();
        } else if (stype instanceof XmlSchemaGroupBase) {
            members = ((XmlSchemaGroupBase) stype).getItems();
        }
        String nsURI = getNamespaceURI(serviceInfo, qname);
        int attrCount = 0;
        int memberCount = 0;
        for (int i = 0; i < structMembers.size(); ++i) {
            XmlSchemaObject schemaObj;
            if ((attrs != null) && (attrCount != attrs.getCount())) {
                schemaObj = attrs.getItem(attrCount++);
            } else {
                schemaObj = members.getItem(memberCount++);
            }
View Full Code Here

Examples of org.apache.ws.commons.schema.XmlSchemaObject

                                                             typeMaps,
                                                             serviceInfo);
        ((CorbaUnionHandler)obj).setDiscriminator(discObj);
        boolean isAttr = false;
        boolean isElementNil = false;
        XmlSchemaObject stype = schemaType;
        QName qname = name;
        if (schemaType instanceof XmlSchemaAttribute) {
            XmlSchemaAttribute attr = (XmlSchemaAttribute) schemaType;
            if (attr.getQName() != null) {
                qname = attr.getQName();
View Full Code Here

Examples of org.apache.ws.commons.schema.XmlSchemaObject

        return nsUri;
    }

    public static XmlSchemaElement getXmlSchemaSequenceElement(XmlSchemaObject schemaType,
                                                               ServiceInfo serviceInfo) {
        XmlSchemaObject stype = schemaType;
        XmlSchemaElement el = null;
        if (schemaType instanceof XmlSchemaElement) {
            stype = ((XmlSchemaElement) schemaType).getSchemaType();
            if (stype == null) {
                stype = CorbaUtils.getXmlSchemaType(serviceInfo, el.getRefName());
View Full Code Here

Examples of org.apache.ws.commons.schema.XmlSchemaObject

                                                   XmlSchemaObject schemaType)
        throws CorbaBindingException {
        if (schemaType == null) {
            throw new CorbaBindingException("Couldn't find xml schema object for : " + idlType);
        }
        XmlSchemaObject stype = schemaType;
        boolean readElement = true;
        QName elName = null;
        if (schemaType instanceof XmlSchemaAttribute) {
            readElement = false;
            elName = ((XmlSchemaAttribute) schemaType).getQName();
View Full Code Here

Examples of org.apache.ws.commons.schema.XmlSchemaObject

            throw new CorbaBindingException("Couldn't find xml schema object for : " + obj.getIdlType());
        }
        if (objName == null) {
            objName = obj.getName();
        }
        XmlSchemaObject stype = schemaType;
        boolean writeElement = true;
        QName elName = null;
        if (schemaType instanceof XmlSchemaAttribute) {
            writeElement = false;
        } else if (schemaType instanceof XmlSchemaElement) {
View Full Code Here

Examples of org.apache.ws.commons.schema.XmlSchemaObject

            XmlSchemaObjectCollection attrs = null;
            XmlSchemaObjectCollection members = null;
           
            boolean readElement = false;

            XmlSchemaObject stype = schemaType;
            if (schemaType instanceof XmlSchemaElement) {
                XmlSchemaElement el = (XmlSchemaElement) schemaType;
                stype = el.getSchemaType();
                if (stype == null) {
                    stype = CorbaUtils.getXmlSchemaType(serviceInfo, el.getRefName());
                }
                readElement = true;
            }
            if (stype instanceof XmlSchemaComplexType) {
                XmlSchemaComplexType ctype = (XmlSchemaComplexType) stype;
                attrs = ctype.getAttributes();
                stype = ctype.getParticle();
                readElement = true;
            }
            if (stype instanceof XmlSchemaGroupRef) {
                members = ((XmlSchemaGroupRef) stype).getParticle().getItems();
            } else if (stype instanceof XmlSchemaGroupBase) {
                members = ((XmlSchemaGroupBase) stype).getItems();
            }
            QName elName;
            if ((attrs != null) && (attrs.getCount() > 0)) {
                elName = reader.peek().asStartElement().getName();
            } else if (readElement) {
                elName = reader.nextEvent().asStartElement().getName();
            } else {
                elName = CorbaUtils.EMPTY_QNAME;
            }
            obj = new CorbaStructHandler(elName, idlType, tc, structType);

            List<MemberType> structMembers = structType.getMember();
            int attrCount = 0;
            int memberCount = 0;
            for (int i = 0; i < structMembers.size(); ++i) {
                XmlSchemaObject schemaObj;
                if ((attrs != null) && (attrCount < attrs.getCount())) {
                    schemaObj = attrs.getItem(attrCount++);
                } else {
                    schemaObj = members.getItem(memberCount++);
                }
View Full Code Here

Examples of org.apache.ws.commons.schema.XmlSchemaObject

        XmlSchemaObjectCollection attrs = null;
        XmlSchemaObjectCollection members = null;
           
        boolean writeElement = false;

        XmlSchemaObject stype = schemaType;
        if (schemaType instanceof XmlSchemaElement) {
            XmlSchemaElement el = (XmlSchemaElement) schemaType;
            stype = el.getSchemaType();
            if (stype == null) {
                stype = CorbaUtils.getXmlSchemaType(serviceInfo, el.getRefName());
            }
            writeElement = true;
        }
        if (stype instanceof XmlSchemaComplexType) {
            XmlSchemaComplexType ctype = (XmlSchemaComplexType) stype;
            attrs = ctype.getAttributes();
            stype = ctype.getParticle();
            writeElement = true;
        }
        if (stype instanceof XmlSchemaGroupRef) {
            members = ((XmlSchemaGroupRef) stype).getParticle().getItems();
        } else if (stype instanceof XmlSchemaGroupBase) {
            members = ((XmlSchemaGroupBase) stype).getItems();
        }
       
        if (writeElement) {
            StartElement startEl = factory.createStartElement(objName, null, null);
            writer.add(startEl);
        }
       
        CorbaStructHandler structHandler = (CorbaStructHandler)obj;
        List<CorbaObjectHandler> elements = structHandler.getMembers();
        int attrCount = 0;
        int memberCount = 0;
        for (Iterator<CorbaObjectHandler> elementsIter = elements.iterator(); elementsIter.hasNext();) {
            XmlSchemaObject schemaObj;
            if ((attrs != null) && (attrCount != attrs.getCount())) {
                schemaObj = attrs.getItem(attrCount++);
            } else {
                schemaObj = members.getItem(memberCount++);
            }
View Full Code Here

Examples of org.apache.ws.commons.schema.XmlSchemaObject

        XmlSchemaComplexType stype = (XmlSchemaComplexType)schema.getTypeByName("bean");
        boolean howdy = false;
        boolean bleh = false;
        for (int x = 0; x < stype.getAttributes().size(); x++) {
            XmlSchemaObject o = stype.getAttributes().get(x);
            if (o instanceof XmlSchemaAttribute) {
                XmlSchemaAttribute a = (XmlSchemaAttribute)o;
                if ("howdy".equals(a.getName())) {
                    howdy = true;
                }
View Full Code Here

Examples of org.apache.ws.commons.schema.XmlSchemaObject

                }
            }
        }

        for (int x = 0; x < stype.getAttributes().size(); x++) {
            XmlSchemaObject o = stype.getAttributes().get(x);
            if (o instanceof XmlSchemaAttribute) {
                XmlSchemaAttribute a = (XmlSchemaAttribute)o;
                if ("howdy".equals(a.getName())) {
                    howdy = true;
                }
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.