Package org.apache.xerces.impl.xs

Examples of org.apache.xerces.impl.xs.XSAnnotationImpl


             if (idReferStr != null) {
                idConsDomNode.setAttributeNS(null, "refer", idReferStr)
             }
            
             // add annotation to an ID constraint
             XSAnnotationImpl idConsAnnotation = (XSAnnotationImpl)
                                                   idCons.getAnnotations().item(0);
             if (idConsAnnotation != null) {
                addAnnotationToSchemaComponent(document,
                                               idConsDomNode,
                                               idConsAnnotation);
View Full Code Here


                                                   XSD_LANGUAGE_PREFIX +
                                                   "complexType");
           complxTypeDomNode.setAttributeNS(null, "name", ctName);
          
           // add annotation to complex type
           XSAnnotationImpl complexTypeAnnot = (XSAnnotationImpl)
                                                 complexTypeDecl.
                                                     getAnnotations().item(0);
           if (complexTypeAnnot != null) {
              addAnnotationToSchemaComponent(document,
                                             complxTypeDomNode,
View Full Code Here

           simpleTypeDomNode.setAttributeNS(null, "name", stName);
        }
        parentDomNode.appendChild(simpleTypeDomNode);
       
        // add annotation to a simple type
        XSAnnotationImpl simpleTypeAnnotation = (XSAnnotationImpl)
                                             simpleTypeDecl.getAnnotations().item(0);
        if (simpleTypeAnnotation != null) {
           addAnnotationToSchemaComponent(document,
                                          simpleTypeDomNode,
                                          simpleTypeAnnotation);
View Full Code Here

       
        Element groupDeclDomNode = document.createElementNS(XSD_LANGUAGE_URI,
                                                            XSD_LANGUAGE_PREFIX
                                                            + "group");
        // add annotation to a group declaration
        XSAnnotationImpl groupAnnotation = (XSAnnotationImpl) groupDecl.getAnnotation();
        if (groupAnnotation != null) {
           addAnnotationToSchemaComponent(document,
                                          groupDeclDomNode,
                                          groupAnnotation);
        }
View Full Code Here

                                                              + "attribute");
        attrDeclDomNode.setAttributeNS(null, "name", attrName);       
        parentDomNode.appendChild(attrDeclDomNode);
       
        // add annotation to attribute declaration
        XSAnnotationImpl attrAnnotation = (XSAnnotationImpl)
                                             attrDecl.getAnnotation();
        if (attrAnnotation != null) {
           addAnnotationToSchemaComponent(document,
                                          attrDeclDomNode,
                                          attrAnnotation);
View Full Code Here

       XSComplexTypeDecl complexTypeDecl = (XSComplexTypeDecl) typeDef;      
       Element complexTypeDomNode = document.createElementNS(XSD_LANGUAGE_URI,
                                                            XSD_LANGUAGE_PREFIX +
                                                            "complexType");
       // add annotation to a complex type
       XSAnnotationImpl cmplxTypeAnnotation = (XSAnnotationImpl)
                                            complexTypeDecl.getAnnotations().item(0);
       if (cmplxTypeAnnotation != null) {
          addAnnotationToSchemaComponent(document,
                                         complexTypeDomNode,
                                         cmplxTypeAnnotation);
View Full Code Here

            contentBuffer.append(contents.substring(annotationTokenEnd, contents.length()));
            final String annotation = contentBuffer.toString();
            if (fValidateAnnotations) {
                schemaDoc.addAnnotation(new XSAnnotationInfo(annotation, annotationDecl));
            }
            return new XSAnnotationImpl(annotation, grammar);
        } else {
            if (fValidateAnnotations) {
                schemaDoc.addAnnotation(new XSAnnotationInfo(contents, annotationDecl));
            }
            return new XSAnnotationImpl(contents, grammar);
        }
       
    }
View Full Code Here

            contentBuffer.append(contents.substring(annotationTokenEnd, contents.length()));
            final String annotation = contentBuffer.toString();
            if (fValidateAnnotations) {
                schemaDoc.addAnnotation(new XSAnnotationInfo(annotation, annotationParent));
            }
            return new XSAnnotationImpl(annotation, grammar);
        } else {
            if (fValidateAnnotations) {
                schemaDoc.addAnnotation(new XSAnnotationInfo(contents, annotationParent));
            }
            return new XSAnnotationImpl(contents, grammar);
        }
    }
View Full Code Here

                    break;
                    }
                }
               
                Element child = DOMUtil.getFirstChildElement( content );
                XSAnnotationImpl annotation = null;
                if (child != null &&
                    DOMUtil.getLocalName(child).equals(SchemaSymbols.ELT_ANNOTATION)) {
                    // traverse annotation if any
                    annotation = traverseAnnotationDecl(child, attrs, false, schemaDoc);
                    child = DOMUtil.getNextSiblingElement(child);
View Full Code Here

        QName refAtt = (QName) attrValues[XSAttributeChecker.ATTIDX_REF];
        XInt  minAtt = (XIntattrValues[XSAttributeChecker.ATTIDX_MINOCCURS];
        XInt  maxAtt = (XIntattrValues[XSAttributeChecker.ATTIDX_MAXOCCURS];
       
        XSElementDecl element = null;
        XSAnnotationImpl annotation = null;
        if (elmDecl.getAttributeNode(SchemaSymbols.ATT_REF) != null) {
            if (refAtt != null) {
                element = (XSElementDecl)fSchemaHandler.getGlobalDecl(schemaDoc, XSDHandler.ELEMENT_TYPE, refAtt, elmDecl);
               
                Element child = DOMUtil.getFirstChildElement(elmDecl);
View Full Code Here

TOP

Related Classes of org.apache.xerces.impl.xs.XSAnnotationImpl

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.