Package org.apache.ws.commons.schema

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


                idltype = wsdlToCorbaBinding.getHelper().createQNameCorbaNamespace(qname.getLocalPart()
                                                                                       + "_nil");
            } else {
                if (corbaTypeImpl == null) {
                    XmlSchemaObject schemaObj = getSchemaObject(wsdlToCorbaBinding, typeName);
                    XmlSchemaAnnotation annotation = null;
                    if (schemaObj instanceof XmlSchemaElement) {
                        XmlSchemaElement el = (XmlSchemaElement)schemaObj;
                        schemaType = el.getSchemaType();
                        annotation = ((XmlSchemaElement)schemaObj).getAnnotation();
                    }
                    idltype = getSchemaTypeName(wsdlToCorbaBinding, schemaType, annotation, typeName, nill);
                } else {
                    idltype = corbaTypeImpl.getQName();
                }
            }
        } 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.
            XmlSchemaElement schemaObj = getSchemaObject(wsdlToCorbaBinding, typeName);
            XmlSchemaAnnotation annotation = null;
            if (schemaObj != null) {
                annotation = schemaObj.getAnnotation();
            }
            idltype = getSchemaTypeName(wsdlToCorbaBinding, schemaType, annotation, typeName, nill);
        }
View Full Code Here


    private boolean isObjectReference(SchemaCollection schemaList, QName name) {
        for (XmlSchema schema : schemaList.getXmlSchemas()) {
            XmlSchemaElement element = schema.getElementByName(name);
            if (element != null) {
                XmlSchemaAnnotation annotation = element.getAnnotation();
                if (annotation != null) {
                    List<XmlSchemaAnnotationItem> annotationColl = annotation.getItems();
                    for (XmlSchemaAnnotationItem item : annotationColl) {
                        if (item instanceof XmlSchemaAppInfo) {
                            return true;
                        }
                    }
View Full Code Here

        XmlSchemaSimpleType simpleType =
            (XmlSchemaSimpleType)schemaCol.getTypeByQName(TYPE_QNAME);
        assertNotNull(simpleType);

        XmlSchemaAnnotation xsa = simpleType.getAnnotation();
        assertNotNull(xsa);

        XmlSchemaObjectCollection col = xsa.getItems();
        assertEquals(1, col.getCount());

        Set s = new HashSet();
        s.add(XmlSchemaDocumentation.class.getName());
        for (int i = 0; i < col.getCount(); i++) {
View Full Code Here

        s.add("teamMascot");
        s.add("teamLogo");
        for (Iterator i = xsot.getValues(); i.hasNext(); ) {
            XmlSchemaNotation xsn = (XmlSchemaNotation)i.next();
            String name = xsn.getName();
            XmlSchemaAnnotation xsa = xsn.getAnnotation();
            XmlSchemaObjectCollection col = xsa.getItems();
            assertEquals(1, col.getCount());
            XmlSchemaDocumentation xsd = null;
            for (int k = 0; k < col.getCount(); k++) {
                xsd = (XmlSchemaDocumentation)col.getItem(k);
            }
View Full Code Here

        XmlSchemaSimpleType simpleType =
            (XmlSchemaSimpleType)schemaCol.getTypeByQName(TYPE_QNAME);
        assertNotNull(simpleType);

        XmlSchemaAnnotation xsa = simpleType.getAnnotation();
        assertNotNull(xsa);

        XmlSchemaObjectCollection col = xsa.getItems();
        assertEquals(1, col.getCount());

        Set s = new HashSet();
        s.add(XmlSchemaAppInfo.class.getName());
        for (int i = 0; i < col.getCount(); i++) {
View Full Code Here

        XmlSchemaSimpleType simpleType =
            (XmlSchemaSimpleType)schemaCol.getTypeByQName(TYPE_QNAME);
        assertNotNull(simpleType);

        XmlSchemaAnnotation xsa = simpleType.getAnnotation();
        assertNotNull(xsa);

        XmlSchemaObjectCollection col = xsa.getItems();
        assertEquals(0, col.getCount());

    }
View Full Code Here

        XmlSchemaSimpleType simpleType =
            (XmlSchemaSimpleType)schemaCol.getTypeByQName(TYPE_QNAME);
        assertNotNull(simpleType);

        XmlSchemaAnnotation xsa = simpleType.getAnnotation();
        assertNotNull(xsa);

        XmlSchemaObjectCollection col = xsa.getItems();
        assertEquals(2, col.getCount());

        Set s = new HashSet();
        s.add(XmlSchemaAppInfo.class.getName());
        s.add(XmlSchemaDocumentation.class.getName());
View Full Code Here

        InputStream is = new FileInputStream(Resources.asURI("annotation.xsd"));
        XmlSchemaCollection schemaCol = new XmlSchemaCollection();
        XmlSchema schema = schemaCol.read(new StreamSource(is), null);
       
        XmlSchemaAnnotation xsa = schema.getAnnotation();
        XmlSchemaObjectCollection col = xsa.getItems();
        assertEquals(2, col.getCount());

        Set s = new HashSet();
        s.add(XmlSchemaAppInfo.class.getName());
        s.add(XmlSchemaDocumentation.class.getName());
View Full Code Here

        schemaCol.read(new StreamSource(is));

        XmlSchemaSimpleType simpleType = (XmlSchemaSimpleType)schemaCol.getTypeByQName(typeQName);
        assertNotNull(simpleType);

        XmlSchemaAnnotation xsa = simpleType.getAnnotation();
        assertNotNull(xsa);

        List<XmlSchemaAnnotationItem> col = xsa.getItems();
        assertEquals(1, col.size());

        Set<String> s = new HashSet<String>();
        s.add(XmlSchemaDocumentation.class.getName());
        for (int i = 0; i < col.size(); i++) {
View Full Code Here

        schemaCol.read(new StreamSource(is));

        XmlSchemaSimpleType simpleType = (XmlSchemaSimpleType)schemaCol.getTypeByQName(typeQName);
        assertNotNull(simpleType);

        XmlSchemaAnnotation xsa = simpleType.getAnnotation();
        assertNotNull(xsa);

        List<XmlSchemaAnnotationItem> col = xsa.getItems();
        assertEquals(1, col.size());

        Set<String> s = new HashSet<String>();
        s.add(XmlSchemaAppInfo.class.getName());
        for (int i = 0; i < col.size(); i++) {
View Full Code Here

TOP

Related Classes of org.apache.ws.commons.schema.XmlSchemaAnnotation

Copyright © 2018 www.massapicom. 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.