Package org.eclipse.xsd

Examples of org.eclipse.xsd.XSDAttributeGroupDefinition


        if (defn == null) {
            return;
        }
        Node attributeGroupNode = null;
        if (defn.isAttributeGroupDefinitionReference()) {
            XSDAttributeGroupDefinition resolved = defn.getResolvedAttributeGroupDefinition();
            logger.debug("Attribute Group definition (ref): '{0}' in ns '{1}' ",
                         resolved.getName(),
                         resolved.getTargetNamespace());
            attributeGroupNode = parentNode.addNode(resolved.getName(), XsdLexicon.ATTRIBUTE_GROUP);
            setReference(attributeGroupNode,
                         XsdLexicon.REF,
                         ATTRIBUTE_GROUP_DEFINITIONS,
                         resolved.getTargetNamespace(),
                         resolved.getName());
        } else {
            logger.debug("Attribute Group definition: '{0}' in ns '{1}' ", defn.getName(), defn.getTargetNamespace());
            attributeGroupNode = parentNode.addNode(defn.getName(), XsdLexicon.ATTRIBUTE_GROUP);
            registerForSymbolSpace(ATTRIBUTE_GROUP_DEFINITIONS,
                                   defn.getTargetNamespace(),
View Full Code Here


        for (int i = 0; i < schemas.length; i++) {
            XSDSchema schema = schemas[i];

            for (Iterator g = schema.getAttributeGroupDefinitions().iterator(); g.hasNext();) {
                XSDAttributeGroupDefinition group = (XSDAttributeGroupDefinition) g.next();

                QName qName = new QName(group.getTargetNamespace(), group.getName());
                attributeGroupIndex.put(qName, group);
            }
        }
    }
View Full Code Here

                            //an attribute, add it to the list
                            XSDAttributeUse use = (XSDAttributeUse) content;
                            attributes.add(use.getAttributeDeclaration());
                        } else if (content instanceof XSDAttributeGroupDefinition) {
                            //attribute group, add all atts in group to list
                            XSDAttributeGroupDefinition attGrp = (XSDAttributeGroupDefinition) content;

                            if (attGrp.isAttributeGroupDefinitionReference()) {
                                attGrp = attGrp.getResolvedAttributeGroupDefinition();
                            }

                            List uses = attGrp.getAttributeUses();

                            for (Iterator aitr = uses.iterator(); aitr.hasNext();) {
                                XSDAttributeUse use = (XSDAttributeUse) aitr.next();
                                attributes.add(use.getAttributeDeclaration());
                            }
View Full Code Here

TOP

Related Classes of org.eclipse.xsd.XSDAttributeGroupDefinition

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.