Package org.exolab.castor.xml.schema

Examples of org.exolab.castor.xml.schema.AttributeDecl


            }
            if (result == null || result.length() <= 0) {

                Annotated temp = null;
                if (_annotated.getStructureType() == Structure.ATTRIBUTE) {
                     AttributeDecl att = (AttributeDecl)_annotated;
                     if (att.isReference()) {
                         temp = _annotated;
                         setView(att.getReference());
                         result = getJavaMemberName();
                         setView(temp);
                     }
                     att = null;
                }
View Full Code Here


        }
        //Note: the attributes are added to the complexType
        //since a simpleType does not contain attributes at all
        //-- attribute
    else if (SchemaNames.ATTRIBUTE.equals(name)) {
            AttributeDecl attrDecl =
                ((AttributeUnmarshaller)unmarshaller).getAttribute();

      /**@todo add the validation code later*/

      /*ComplexType baseType = (ComplexType)_complexType.getBaseType();
View Full Code Here

                throw new IllegalArgumentException(e.getMessage());
            }
        }
        //-- attribute declarations
        if (SchemaNames.ATTRIBUTE.equals(name)) {
            AttributeDecl attrDecl =
                ((AttributeUnmarshaller)unmarshaller).getAttribute();

            _complexType.addAttributeDecl(attrDecl);
        }
        //-- attribute groups
View Full Code Here

        this._schema = schema;

        setResolver(resolver);


        _attribute = new AttributeDecl(schema);

        //--@ref
        String attValue = atts.getValue(SchemaNames.REF_ATTR);
        if (attValue != null) {
            _attribute.setReference(attValue);
View Full Code Here

        }


        //-- attribute declarations
        else if (SchemaNames.ATTRIBUTE.equals(name)) {
            AttributeDecl attrDecl =
                ((AttributeUnmarshaller)unmarshaller).getAttribute();

            ((AttributeGroupDecl)_attributeGroup).addAttribute(attrDecl);
        }
        //-- attribute group references
View Full Code Here

                throw new IllegalArgumentException(e.getMessage());
            }
        }
    //-- attribute
    else if (SchemaNames.ATTRIBUTE.equals(name)) {
            AttributeDecl attrDecl =
                ((AttributeUnmarshaller)unmarshaller).getAttribute();

             /**@todo do the validation later*/
            _complexType.addAttributeDecl(attrDecl);
        }
View Full Code Here

          case Structure.ATTRIBUTE :
            if (result == null) {
                        //--handle reference: if the element referred a
                        //--global element then we use the global binding
                        AttributeDecl attribute = (AttributeDecl) annotated;
              if (attribute.isReference()) {
                xPath = getSchemaLocation(attribute.getReference());
                result = lookupComponentBindingType(xPath);
                        }
              attribute = null;
                    }
            break;
View Full Code Here

            }
        }

        //-- attribute declarations
        else if (SchemaNames.ATTRIBUTE.equals(name)) {
            AttributeDecl attrDecl =
                ((AttributeUnmarshaller)unmarshaller).getAttribute();

            _complexType.addAttributeDecl(attrDecl);
        }
        //-- attribute groups
View Full Code Here

        Schema schema = null;
        Form form = null;
       
        switch (_annotated.getStructureType()) {
            case Structure.ATTRIBUTE:
                AttributeDecl attribute = (AttributeDecl)_annotated;
                //-- resolve reference
                if (attribute.isReference())
                    attribute = attribute.getReference();
               
                schema = attribute.getSchema();
               
                //-- top-level (use targetNamespace of schema)
                if (attribute.getParent() == schema)
                    break;
               
                //-- check form (qualified or unqualified)
                form = attribute.getForm();
                if (form == null) {
                    form = schema.getAttributeFormDefault();
                }
                if ((form == null) || form.isUnqualified()) {
                    //-- no targetNamespace by default
View Full Code Here

        if (_schema == null) {

            switch (_annotated.getStructureType()) {
                case Structure.ATTRIBUTE:
                    //--resolve reference?
                    AttributeDecl attribute = (AttributeDecl)_annotated;
                    if (attribute.isReference())
                        attribute = attribute.getReference();
               
                    _schema = attribute.getSchema();
                    attribute = null;
                    break;
                case Structure.ELEMENT:
                    //--resolve reference?
                    ElementDecl element = (ElementDecl)_annotated;
View Full Code Here

TOP

Related Classes of org.exolab.castor.xml.schema.AttributeDecl

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.