axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject cvs commit: xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema ValidationEvent.java ValidationEventHandler.java XmlSchema.java XmlSchemaAll.java XmlSchemaAnnotated.java XmlSchemaAnnotation.java XmlSchemaAny.java XmlSchemaAnyAttribute.java XmlSchemaAppInfo.java XmlSchemaAttribute.java XmlSchemaAttributeGroup.java XmlSchemaAttributeGroupRef.java XmlSchemaChoice.java XmlSchemaCollection.java XmlSchemaCollectionEnumerator.java XmlSchemaComplexContent.java XmlSchemaComplexContentExtension.java XmlSchemaComplexContentRestriction.java XmlSchemaComplexType.java XmlSchemaContent.java XmlSchemaContentModel.java XmlSchemaContentProcessing.java XmlSchemaContentType.java XmlSchemaDatatype.java XmlSchemaDerivationMethod.java XmlSchemaDocumentation.java XmlSchemaElement.java XmlSchemaEnumerationFacet.java XmlSchemaException.java XmlSchemaExternal.java XmlSchemaFacet.java XmlSchemaForm.java XmlSchemaFractionDigitsFacet.java XmlSchemaGroup.java XmlSchemaGroupBase.java XmlSchemaGroupRef.java XmlSchemaIdentityConstraint.java XmlSchemaImport.java XmlSchemaInclude.java XmlSchemaKey.java XmlSchemaKeyref.java XmlSchemaLengthFacet.java XmlSchemaMaxExclusiveFacet.java XmlSchemaMaxInclusiveFacet.java XmlSchemaMaxLengthFacet.java XmlSchemaMinExclusiveFacet.java XmlSchemaMinInclusiveFacet.java XmlSchemaMinLengthFacet.java XmlSchemaNotation.java XmlSchemaNumericFacet.java XmlSchemaObject.java XmlSchemaObjectCollection.java XmlSchemaObjectEnumerator.java XmlSchemaObjectTable.java XmlSchemaParticle.java XmlSchemaPatternFacet.java XmlSchemaRedefine.java XmlSchemaSequence.java XmlSchemaSerializer.java XmlSchemaSimpleContent.java XmlSchemaSimpleContentExtension.java XmlSchemaSimpleContentRestriction.java XmlSchemaSimpleType.java XmlSchemaSimpleTypeContent.java XmlSchemaSimpleTypeList.java XmlSchemaSimpleTypeRestriction.java XmlSchemaSimpleTypeUnion.java XmlSchemaTotalDigitsFacet.java XmlSchemaType.java XmlSchemaUnique.java XmlSchemaUse.java XmlSchemaWhiteSpaceFacet.java XmlSchemaXPath.java XmlSeverityType.java
Date Sun, 17 Nov 2002 23:53:22 GMT
dims        2002/11/17 15:53:22

  Modified:    proposals/XmlSchema/src/org/apache/axis/xsd/enum Enum.java
               proposals/XmlSchema/src/org/apache/axis/xsd/str
                        Tokenizer.java
               proposals/XmlSchema/src/org/apache/axis/xsd/xml DOMUtil.java
                        QualifiedName.java XDOMUtil.java
                        XmlTokenizedType.java
               proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema
                        ValidationEvent.java ValidationEventHandler.java
                        XmlSchema.java XmlSchemaAll.java
                        XmlSchemaAnnotated.java XmlSchemaAnnotation.java
                        XmlSchemaAny.java XmlSchemaAnyAttribute.java
                        XmlSchemaAppInfo.java XmlSchemaAttribute.java
                        XmlSchemaAttributeGroup.java
                        XmlSchemaAttributeGroupRef.java
                        XmlSchemaChoice.java XmlSchemaCollection.java
                        XmlSchemaCollectionEnumerator.java
                        XmlSchemaComplexContent.java
                        XmlSchemaComplexContentExtension.java
                        XmlSchemaComplexContentRestriction.java
                        XmlSchemaComplexType.java XmlSchemaContent.java
                        XmlSchemaContentModel.java
                        XmlSchemaContentProcessing.java
                        XmlSchemaContentType.java XmlSchemaDatatype.java
                        XmlSchemaDerivationMethod.java
                        XmlSchemaDocumentation.java XmlSchemaElement.java
                        XmlSchemaEnumerationFacet.java
                        XmlSchemaException.java XmlSchemaExternal.java
                        XmlSchemaFacet.java XmlSchemaForm.java
                        XmlSchemaFractionDigitsFacet.java
                        XmlSchemaGroup.java XmlSchemaGroupBase.java
                        XmlSchemaGroupRef.java
                        XmlSchemaIdentityConstraint.java
                        XmlSchemaImport.java XmlSchemaInclude.java
                        XmlSchemaKey.java XmlSchemaKeyref.java
                        XmlSchemaLengthFacet.java
                        XmlSchemaMaxExclusiveFacet.java
                        XmlSchemaMaxInclusiveFacet.java
                        XmlSchemaMaxLengthFacet.java
                        XmlSchemaMinExclusiveFacet.java
                        XmlSchemaMinInclusiveFacet.java
                        XmlSchemaMinLengthFacet.java XmlSchemaNotation.java
                        XmlSchemaNumericFacet.java XmlSchemaObject.java
                        XmlSchemaObjectCollection.java
                        XmlSchemaObjectEnumerator.java
                        XmlSchemaObjectTable.java XmlSchemaParticle.java
                        XmlSchemaPatternFacet.java XmlSchemaRedefine.java
                        XmlSchemaSequence.java XmlSchemaSerializer.java
                        XmlSchemaSimpleContent.java
                        XmlSchemaSimpleContentExtension.java
                        XmlSchemaSimpleContentRestriction.java
                        XmlSchemaSimpleType.java
                        XmlSchemaSimpleTypeContent.java
                        XmlSchemaSimpleTypeList.java
                        XmlSchemaSimpleTypeRestriction.java
                        XmlSchemaSimpleTypeUnion.java
                        XmlSchemaTotalDigitsFacet.java XmlSchemaType.java
                        XmlSchemaUnique.java XmlSchemaUse.java
                        XmlSchemaWhiteSpaceFacet.java XmlSchemaXPath.java
                        XmlSeverityType.java
  Log:
  - Added license header
  - cleanup imports
  - format the source code a bit.
  
  Revision  Changes    Path
  1.2       +83 -28    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/enum/Enum.java
  
  Index: Enum.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/enum/Enum.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- Enum.java	17 Nov 2002 23:25:57 -0000	1.1
  +++ Enum.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * Enum.java
    *
    * Created on October 12, 2001, 3:25 PM
  @@ -12,15 +67,15 @@
    */
   
   public abstract class Enum {
  -    
  +
       public static String NULL = "NULL";
   
       protected Enum(String value) {
  -	setValue(value);
  +        setValue(value);
       }
   
       protected Enum() {
  -	this(NULL);
  +        this(NULL);
       }
   
       protected abstract String[] getValues();
  @@ -28,43 +83,43 @@
       protected String value = NULL;
   
       public void setValue(String value) {
  -	if( value.equals(Enum.NULL) )
  -	    this.value = Enum.NULL;
  -	else {
  -	    String values[] = getValues();
  -	    for( int i = 0; i < values.length; i++ ) {
  -		if( values[i].equals(value) ) {
  -		    this.value = value;
  -		    break;
  -		}
  -		if( i == values.length - 1 )
  -		    throw new EnumValueException("Bad Enumeration value");
  -	    }
  -	}
  +        if (value.equals(Enum.NULL))
  +            this.value = Enum.NULL;
  +        else {
  +            String values[] = getValues();
  +            for (int i = 0; i < values.length; i++) {
  +                if (values[i].equals(value)) {
  +                    this.value = value;
  +                    break;
  +                }
  +                if (i == values.length - 1)
  +                    throw new EnumValueException("Bad Enumeration value");
  +            }
  +        }
       }
   
       public String getValue() {
  -	return value;
  +        return value;
       }
   
       public String toString() {
  -	return value;
  +        return value;
       }
  -    
  +
       public boolean equals(Object what) {
  -        return what.getClass().equals(this.getClass()) && 
  -			((Enum)what).getValue().equals(this.getValue());
  +        return what.getClass().equals(this.getClass()) &&
  +                ((Enum) what).getValue().equals(this.getValue());
       }
  -    
  +
       public static class EnumValueException extends RuntimeException {
  -	public EnumValueException(String mesg) {
  -	    super(mesg);
  -	}
  +        public EnumValueException(String mesg) {
  +            super(mesg);
  +        }
       }
  -    
  +
       protected static final int index(String value, String values[]) {
  -        for( int i = 0; i < values.length; i++ ) {
  -            if( value.equals(values[i]) )
  +        for (int i = 0; i < values.length; i++) {
  +            if (value.equals(values[i]))
                   return i;
           }
           return -1;
  
  
  
  1.2       +75 -20    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/str/Tokenizer.java
  
  Index: Tokenizer.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/str/Tokenizer.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- Tokenizer.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ Tokenizer.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * Tokenizer.java
    *
    * Created on November 8, 2001, 5:13 PM
  @@ -6,8 +61,8 @@
   
   package org.apache.axis.xsd.str;
   
  -import java.util.Vector;
   import java.util.StringTokenizer;
  +import java.util.Vector;
   
   /**
    *
  @@ -19,31 +74,31 @@
       /** Cannot create new Tokenizer */
       private Tokenizer() {
       }
  -    
  +
       public static final String[] tokenize(String in, String delim) {
  -		Vector tmp = new Vector();
  -		StringTokenizer stk = new StringTokenizer(in, delim);
  -		while( stk.hasMoreTokens() ) {
  -			String str = stk.nextToken();
  -			if( str.trim().length() != 0 )
  -				tmp.addElement(str);
  -		}
  -		return (String[])tmp.toArray(new String[tmp.size()]);
  +        Vector tmp = new Vector();
  +        StringTokenizer stk = new StringTokenizer(in, delim);
  +        while (stk.hasMoreTokens()) {
  +            String str = stk.nextToken();
  +            if (str.trim().length() != 0)
  +                tmp.addElement(str);
  +        }
  +        return (String[]) tmp.toArray(new String[tmp.size()]);
       }
  -    
  +
       public static final String[] firstToken(String in, String delim) {
           int x = in.indexOf(delim);
  -        if( x == -1 )
  -            return new String[] { in, "" };
  -        return new String[] { in.substring(0, x), 
  -							  in.substring(x + delim.length(), in.length()) };
  +        if (x == -1)
  +            return new String[]{in, ""};
  +        return new String[]{in.substring(0, x),
  +                            in.substring(x + delim.length(), in.length())};
       }
  -    
  +
       public static final String[] lastToken(String in, String delim) {
           int x = in.lastIndexOf(delim);
  -        if( x == -1 )
  -            return new String[] { "", in };
  -        return new String[] { in.substring(0, x), 
  -							  in.substring(x + delim.length(), in.length()) };
  +        if (x == -1)
  +            return new String[]{"", in};
  +        return new String[]{in.substring(0, x),
  +                            in.substring(x + delim.length(), in.length())};
       }
   }
  
  
  
  1.2       +51 -54    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/DOMUtil.java
  
  Index: DOMUtil.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/DOMUtil.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DOMUtil.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ DOMUtil.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -2,7 +2,7 @@
    * The Apache Software License, Version 1.1
    *
    *
  - * Copyright (c) 1999-2002 The Apache Software Foundation.  All rights
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
    * reserved.
    *
    * Redistribution and use in source and binary forms, with or without
  @@ -20,11 +20,11 @@
    * 3. The end-user documentation included with the redistribution,
    *    if any, must include the following acknowledgment:
    *       "This product includes software developed by the
  - *        Apache Software Foundation (http://www.apache.org/)."
  + *    Apache Software Foundation (http://www.apache.org/)."
    *    Alternately, this acknowledgment may appear in the software itself,
    *    if and wherever such third-party acknowledgments normally appear.
    *
  - * 4. The names "Xerces" and "Apache Software Foundation" must
  + * 4. The names "Axis" and "Apache Software Foundation" must
    *    not be used to endorse or promote products derived from this
    *    software without prior written permission. For written
    *    permission, please contact apache@apache.org.
  @@ -48,9 +48,7 @@
    * ====================================================================
    *
    * This software consists of voluntary contributions made by many
  - * individuals on behalf of the Apache Software Foundation and was
  - * originally based on software copyright (c) 1999, International
  - * Business Machines, Inc., http://www.apache.org.  For more
  + * individuals on behalf of the Apache Software Foundation.  For more
    * information on the Apache Software Foundation, please see
    * <http://www.apache.org/>.
    */
  @@ -59,7 +57,6 @@
   
   import org.w3c.dom.Attr;
   import org.w3c.dom.Document;
  -import org.w3c.dom.DOMException;
   import org.w3c.dom.Element;
   import org.w3c.dom.NamedNodeMap;
   import org.w3c.dom.Node;
  @@ -82,7 +79,8 @@
       //
   
       /** This class cannot be instantiated. */
  -    protected DOMUtil() {}
  +    protected DOMUtil() {
  +    }
   
       //
       // Public static methods
  @@ -95,7 +93,7 @@
           Node child = parent.getFirstChild();
           while (child != null) {
               if (child.getNodeType() == Node.ELEMENT_NODE) {
  -                return (Element)child;
  +                return (Element) child;
               }
               child = child.getNextSibling();
           }
  @@ -112,7 +110,7 @@
           Node child = parent.getLastChild();
           while (child != null) {
               if (child.getNodeType() == Node.ELEMENT_NODE) {
  -                return (Element)child;
  +                return (Element) child;
               }
               child = child.getPreviousSibling();
           }
  @@ -130,7 +128,7 @@
           Node sibling = node.getNextSibling();
           while (sibling != null) {
               if (sibling.getNodeType() == Node.ELEMENT_NODE) {
  -                return (Element)sibling;
  +                return (Element) sibling;
               }
               sibling = sibling.getNextSibling();
           }
  @@ -148,7 +146,7 @@
           while (child != null) {
               if (child.getNodeType() == Node.ELEMENT_NODE) {
                   if (child.getNodeName().equals(elemName)) {
  -                    return (Element)child;
  +                    return (Element) child;
                   }
               }
               child = child.getNextSibling();
  @@ -167,7 +165,7 @@
           while (child != null) {
               if (child.getNodeType() == Node.ELEMENT_NODE) {
                   if (child.getNodeName().equals(elemName)) {
  -                    return (Element)child;
  +                    return (Element) child;
                   }
               }
               child = child.getPreviousSibling();
  @@ -186,7 +184,7 @@
           while (sibling != null) {
               if (sibling.getNodeType() == Node.ELEMENT_NODE) {
                   if (sibling.getNodeName().equals(elemName)) {
  -                    return (Element)sibling;
  +                    return (Element) sibling;
                   }
               }
               sibling = sibling.getNextSibling();
  @@ -207,8 +205,8 @@
               if (child.getNodeType() == Node.ELEMENT_NODE) {
                   String childURI = child.getNamespaceURI();
                   if (childURI != null && childURI.equals(uri) &&
  -                    child.getLocalName().equals(localpart)) {
  -                    return (Element)child;
  +                        child.getLocalName().equals(localpart)) {
  +                    return (Element) child;
                   }
               }
               child = child.getNextSibling();
  @@ -229,8 +227,8 @@
               if (child.getNodeType() == Node.ELEMENT_NODE) {
                   String childURI = child.getNamespaceURI();
                   if (childURI != null && childURI.equals(uri) &&
  -                    child.getLocalName().equals(localpart)) {
  -                    return (Element)child;
  +                        child.getLocalName().equals(localpart)) {
  +                    return (Element) child;
                   }
               }
               child = child.getPreviousSibling();
  @@ -251,8 +249,8 @@
               if (sibling.getNodeType() == Node.ELEMENT_NODE) {
                   String siblingURI = sibling.getNamespaceURI();
                   if (siblingURI != null && siblingURI.equals(uri) &&
  -                    sibling.getLocalName().equals(localpart)) {
  -                    return (Element)sibling;
  +                        sibling.getLocalName().equals(localpart)) {
  +                    return (Element) sibling;
                   }
               }
               sibling = sibling.getNextSibling();
  @@ -272,7 +270,7 @@
               if (child.getNodeType() == Node.ELEMENT_NODE) {
                   for (int i = 0; i < elemNames.length; i++) {
                       if (child.getNodeName().equals(elemNames[i])) {
  -                        return (Element)child;
  +                        return (Element) child;
                       }
                   }
               }
  @@ -293,7 +291,7 @@
               if (child.getNodeType() == Node.ELEMENT_NODE) {
                   for (int i = 0; i < elemNames.length; i++) {
                       if (child.getNodeName().equals(elemNames[i])) {
  -                        return (Element)child;
  +                        return (Element) child;
                       }
                   }
               }
  @@ -314,7 +312,7 @@
               if (sibling.getNodeType() == Node.ELEMENT_NODE) {
                   for (int i = 0; i < elemNames.length; i++) {
                       if (sibling.getNodeName().equals(elemNames[i])) {
  -                        return (Element)sibling;
  +                        return (Element) sibling;
                       }
                   }
               }
  @@ -337,8 +335,8 @@
                   for (int i = 0; i < elemNames.length; i++) {
                       String uri = child.getNamespaceURI();
                       if (uri != null && uri.equals(elemNames[i][0]) &&
  -                        child.getLocalName().equals(elemNames[i][1])) {
  -                        return (Element)child;
  +                            child.getLocalName().equals(elemNames[i][1])) {
  +                        return (Element) child;
                       }
                   }
               }
  @@ -361,8 +359,8 @@
                   for (int i = 0; i < elemNames.length; i++) {
                       String uri = child.getNamespaceURI();
                       if (uri != null && uri.equals(elemNames[i][0]) &&
  -                        child.getLocalName().equals(elemNames[i][1])) {
  -                        return (Element)child;
  +                            child.getLocalName().equals(elemNames[i][1])) {
  +                        return (Element) child;
                       }
                   }
               }
  @@ -385,8 +383,8 @@
                   for (int i = 0; i < elemNames.length; i++) {
                       String uri = sibling.getNamespaceURI();
                       if (uri != null && uri.equals(elemNames[i][0]) &&
  -                        sibling.getLocalName().equals(elemNames[i][1])) {
  -                        return (Element)sibling;
  +                            sibling.getLocalName().equals(elemNames[i][1])) {
  +                        return (Element) sibling;
                       }
                   }
               }
  @@ -402,7 +400,7 @@
        * Finds and returns the first child node with the given name and
        * attribute name, value pair.
        */
  -    public static Element getFirstChildElement(Node   parent,
  +    public static Element getFirstChildElement(Node parent,
                                                  String elemName,
                                                  String attrName,
                                                  String attrValue) {
  @@ -411,9 +409,9 @@
           Node child = parent.getFirstChild();
           while (child != null) {
               if (child.getNodeType() == Node.ELEMENT_NODE) {
  -                Element element = (Element)child;
  +                Element element = (Element) child;
                   if (element.getNodeName().equals(elemName) &&
  -                    element.getAttribute(attrName).equals(attrValue)) {
  +                        element.getAttribute(attrName).equals(attrValue)) {
                       return element;
                   }
               }
  @@ -429,18 +427,18 @@
        * Finds and returns the last child node with the given name and
        * attribute name, value pair.
        */
  -    public static Element getLastChildElement(Node   parent,
  -                                               String elemName,
  -                                               String attrName,
  -                                               String attrValue) {
  +    public static Element getLastChildElement(Node parent,
  +                                              String elemName,
  +                                              String attrName,
  +                                              String attrValue) {
   
           // search for node
           Node child = parent.getLastChild();
           while (child != null) {
               if (child.getNodeType() == Node.ELEMENT_NODE) {
  -                Element element = (Element)child;
  +                Element element = (Element) child;
                   if (element.getNodeName().equals(elemName) &&
  -                    element.getAttribute(attrName).equals(attrValue)) {
  +                        element.getAttribute(attrName).equals(attrValue)) {
                       return element;
                   }
               }
  @@ -457,7 +455,7 @@
        * attribute name, value pair. Since only elements have attributes,
        * the node returned will be of type Node.ELEMENT_NODE.
        */
  -    public static Element getNextSiblingElement(Node   node,
  +    public static Element getNextSiblingElement(Node node,
                                                   String elemName,
                                                   String attrName,
                                                   String attrValue) {
  @@ -466,9 +464,9 @@
           Node sibling = node.getNextSibling();
           while (sibling != null) {
               if (sibling.getNodeType() == Node.ELEMENT_NODE) {
  -                Element element = (Element)sibling;
  +                Element element = (Element) sibling;
                   if (element.getNodeName().equals(elemName) &&
  -                    element.getAttribute(attrName).equals(attrValue)) {
  +                        element.getAttribute(attrName).equals(attrValue)) {
                       return element;
                   }
               }
  @@ -503,8 +501,7 @@
               short type = child.getNodeType();
               if (type == Node.TEXT_NODE) {
                   str.append(child.getNodeValue());
  -            }
  -            else if (type == Node.CDATA_SECTION_NODE) {
  +            } else if (type == Node.CDATA_SECTION_NODE) {
                   str.append(getChildText(child));
               }
               child = child.getNextSibling();
  @@ -521,17 +518,17 @@
       } // getLocalName(Element):  String
   
       /** returns local name of this element if not null, otherwise
  -        returns the name of the node
  -    */
  +     returns the name of the node
  +     */
       public static String getLocalName(Node node) {
           String name = node.getLocalName();
  -        return (name!=null)? name:node.getNodeName();
  +        return (name != null)? name:node.getNodeName();
       } // getLocalName(Element):  String
   
       public static Element getParent(Element elem) {
           Node parent = elem.getParentNode();
           if (parent instanceof Element)
  -            return (Element)parent;
  +            return (Element) parent;
           return null;
       } // getParent(Element):Element
   
  @@ -543,9 +540,9 @@
       // return this Document's root node
       public static Element getRoot(Document doc) {
           return doc.getDocumentElement();
  -     } // getRoot(Document(:  Element
  +    } // getRoot(Document(:  Element
   
  -   // some methods for handling attributes:
  +    // some methods for handling attributes:
   
       // return the right attribute node
       public static Attr getAttr(Element elem, String name) {
  @@ -554,16 +551,16 @@
   
       // return the right attribute node
       public static Attr getAttrNS(Element elem, String nsUri,
  -            String localName) {
  +                                 String localName) {
           return elem.getAttributeNodeNS(nsUri, localName);
       } // getAttrNS(Element, String):Attr
   
       // get all the attributes for an Element
       public static Attr[] getAttrs(Element elem) {
           NamedNodeMap attrMap = elem.getAttributes();
  -        Attr [] attrArray = new Attr[attrMap.getLength()];
  -        for (int i=0; i<attrMap.getLength(); i++)
  -            attrArray[i] = (Attr)attrMap.item(i);
  +        Attr[] attrArray = new Attr[attrMap.getLength()];
  +        for (int i = 0; i < attrMap.getLength(); i++)
  +            attrArray[i] = (Attr) attrMap.item(i);
           return attrArray;
       } // getAttrs(Element):  Attr[]
   
  @@ -586,7 +583,7 @@
       // return the value of the attribute of the given element
       // with the given name
       public static String getAttrValueNS(Element elem, String nsUri,
  -            String localName) {
  +                                        String localName) {
           return elem.getAttributeNS(nsUri, localName);
       } // getAttrValueNS(Element, String):Attr
   
  
  
  
  1.2       +86 -31    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/QualifiedName.java
  
  Index: QualifiedName.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/QualifiedName.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- QualifiedName.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ QualifiedName.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,3 +1,58 @@
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.axis.xsd.xml;
   
   
  @@ -9,37 +64,37 @@
   
   public class QualifiedName {
   
  -	String name, namespace;
  -	
  +    String name, namespace;
  +
       public QualifiedName() {
       }
  -	
  -	public QualifiedName(String name) {
  -		this.name = name;
  -	}
  -	
  -	public QualifiedName(String name, String namespace) {
  -		this.name = name;
  -		this.namespace = namespace;
  -	}
  -	
  -	
  -	public boolean isEmpty() {
  -		return (name == null);
  -	}
  -	
  -	public String getName() {
  -            if (name.indexOf(":")<0)
  -		return name;
  -            else
  -                return (name.substring(name.indexOf(":")+1));
  -	}
  -
  -	public String getNameSpace() {
  -		return namespace;
  -	}
  -	
  -	public String toString() {
  -		return name;
  -	}
  +
  +    public QualifiedName(String name) {
  +        this.name = name;
  +    }
  +
  +    public QualifiedName(String name, String namespace) {
  +        this.name = name;
  +        this.namespace = namespace;
  +    }
  +
  +
  +    public boolean isEmpty() {
  +        return (name == null);
  +    }
  +
  +    public String getName() {
  +        if (name.indexOf(":") < 0)
  +            return name;
  +        else
  +            return (name.substring(name.indexOf(":") + 1));
  +    }
  +
  +    public String getNameSpace() {
  +        return namespace;
  +    }
  +
  +    public String toString() {
  +        return name;
  +    }
   }
  
  
  
  1.2       +67 -11    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/XDOMUtil.java
  
  Index: XDOMUtil.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/XDOMUtil.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XDOMUtil.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XDOMUtil.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XDOMUtil.java
    *
    * Created on February 21, 2002, 12:33 AM
  @@ -6,18 +61,19 @@
   
   package org.apache.axis.xsd.xml;
   
  -import org.w3c.dom.*;
  +import org.w3c.dom.Element;
  +import org.w3c.dom.Node;
   
   /**
    *
    * @author  mukund
    */
   public class XDOMUtil extends DOMUtil {
  -    
  +
       /** Creates a new instance of XDOMUtil */
       private XDOMUtil() {
       }
  -    
  +
       public static Element getFirstChildElementNS(Node parent, String uri) {
   
           // search for node
  @@ -25,8 +81,8 @@
           while (child != null) {
               if (child.getNodeType() == Node.ELEMENT_NODE) {
                   String childURI = child.getNamespaceURI();
  -                if (childURI != null && childURI.equals(uri) ) {
  -                    return (Element)child;
  +                if (childURI != null && childURI.equals(uri)) {
  +                    return (Element) child;
                   }
               }
               child = child.getNextSibling();
  @@ -34,17 +90,17 @@
   
           // not found
           return null;
  -        
  +
       }
  -    
  +
       public static Element getNextSiblingElementNS(Node node, String uri) {
           // search for node
           Node sibling = node.getNextSibling();
           while (sibling != null) {
               if (sibling.getNodeType() == Node.ELEMENT_NODE) {
                   String siblingURI = sibling.getNamespaceURI();
  -                if (siblingURI != null && siblingURI.equals(uri) ) {
  -                    return (Element)sibling;
  +                if (siblingURI != null && siblingURI.equals(uri)) {
  +                    return (Element) sibling;
                   }
               }
               sibling = sibling.getNextSibling();
  @@ -52,7 +108,7 @@
   
           // not found
           return null;
  -        
  +
       }
  -    
  +
   }
  
  
  
  1.2       +68 -12    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/XmlTokenizedType.java
  
  Index: XmlTokenizedType.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/XmlTokenizedType.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlTokenizedType.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlTokenizedType.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,6 +1,62 @@
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.axis.xsd.xml;
   
   import org.apache.axis.xsd.enum.Enum;
  +
   /**
    * @author momo 
    */
  @@ -9,18 +65,18 @@
   
   public class XmlTokenizedType extends Enum {
   
  -	static String[] members = new String[] { "CDATA", "IDREF", "IDREFS", 
  -											 "ENTITY", "ENTITIES", "NMTOKEN", 
  -											 "NMTOKENS", "NOTATION", "ENUMERATION",
  -											 "QName", "NCName", "None"};
  -		
  +    static String[] members = new String[]{"CDATA", "IDREF", "IDREFS",
  +                                           "ENTITY", "ENTITIES", "NMTOKEN",
  +                                           "NMTOKENS", "NOTATION", "ENUMERATION",
  +                                           "QName", "NCName", "None"};
  +
       /** Creates new XmlSchemaForm */
  -	public XmlTokenizedType(String value) {
  -		super(value);
  -	}
  -	
  -	public String[] getValues() {
  -		return members;
  -	}
  +    public XmlTokenizedType(String value) {
  +        super(value);
  +    }
  +
  +    public String[] getValues() {
  +        return members;
  +    }
   
   }
  
  
  
  1.2       +56 -1     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/ValidationEvent.java
  
  Index: ValidationEvent.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/ValidationEvent.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ValidationEvent.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ ValidationEvent.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * ValidationEvent.java
    *
    * Created on September 27, 2001, 3:03 AM
  @@ -17,7 +72,7 @@
   
       /** Creates new ValidationEvent */
       public ValidationEvent(Object source) {
  -		super(source);
  +        super(source);
       }
   
   }
  
  
  
  1.2       +55 -0     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/ValidationEventHandler.java
  
  Index: ValidationEventHandler.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/ValidationEventHandler.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ValidationEventHandler.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ ValidationEventHandler.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * ValidationEventHandler.java
    *
    * Created on September 27, 2001, 3:00 AM
  
  
  
  1.2       +1661 -1631xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchema.java
  
  Index: XmlSchema.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchema.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchema.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchema.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchema.java
    *
    * Created on September 27, 2001, 2:27 AM
  @@ -7,45 +62,38 @@
   package org.apache.axis.xsd.xml.schema;
   
   
  -import org.apache.axis.xsd.xml.XDOMUtil;
  -import org.apache.axis.xsd.enum.Enum;
   import org.apache.axis.xsd.str.Tokenizer;
   import org.apache.axis.xsd.xml.QualifiedName;
  -
  -import java.io.Reader;
  -import java.io.Writer;
  -import java.io.OutputStream;
  -import java.io.OutputStreamWriter;
  -import java.io.IOException;
  -import java.io.ByteArrayInputStream;
  -import java.io.ByteArrayOutputStream;
  -import java.util.Hashtable;
  -import java.util.Vector;
  -import java.util.StringTokenizer;
  +import org.apache.axis.xsd.xml.XDOMUtil;
  +import org.w3c.dom.Attr;
   import org.w3c.dom.Document;
  -import org.w3c.dom.DocumentFragment;
   import org.w3c.dom.Element;
   import org.w3c.dom.NamedNodeMap;
  -import org.w3c.dom.Node;
   import org.w3c.dom.NodeList;
  -import org.w3c.dom.Attr;
  +import org.xml.sax.InputSource;
  +import org.xml.sax.SAXException;
   
  -import javax.xml.parsers.DocumentBuilderFactory;
   import javax.xml.parsers.DocumentBuilder;
  +import javax.xml.parsers.DocumentBuilderFactory;
   import javax.xml.parsers.ParserConfigurationException;
  -import javax.xml.transform.TransformerFactory;
  +import javax.xml.transform.OutputKeys;
  +import javax.xml.transform.Result;
  +import javax.xml.transform.Source;
   import javax.xml.transform.TransformerConfigurationException;
   import javax.xml.transform.TransformerException;
  -import javax.xml.transform.Source;
  -import javax.xml.transform.Result;
  -import javax.xml.transform.OutputKeys;
  +import javax.xml.transform.TransformerFactory;
   import javax.xml.transform.dom.DOMSource;
  -import javax.xml.transform.dom.DOMResult;
   import javax.xml.transform.stream.StreamResult;
  -import javax.xml.transform.stream.StreamSource;
  -
  -import org.xml.sax.InputSource;
  -import org.xml.sax.SAXException;
  +import java.io.ByteArrayInputStream;
  +import java.io.ByteArrayOutputStream;
  +import java.io.IOException;
  +import java.io.OutputStream;
  +import java.io.OutputStreamWriter;
  +import java.io.Reader;
  +import java.io.Writer;
  +import java.util.Hashtable;
  +import java.util.StringTokenizer;
  +import java.util.Vector;
   
   
   /**
  @@ -72,14 +120,14 @@
   
       // notation is global elements, all XmlSchemaObjectTable are READ-ONLY
       XmlSchemaObjectTable attributeGroups, attributes, elements, groups, 
  -        notations, schemaTypes;
  +    notations, schemaTypes;
       XmlSchemaDerivationMethod blockDefault, finalDefault;
       XmlSchemaObjectCollection includes, items;
       boolean isCompiled;
  -    String targetNamespace="DEFAULT", version;
  +    String targetNamespace = "DEFAULT", version;
       Hashtable namespaces;
       String schema_ns_prefix = "";
  -	
  +
       /** Creates new XmlSchema */
       public XmlSchema() {
           attributeFormDefault = new XmlSchemaForm("Qualified");
  @@ -96,52 +144,52 @@
           notations = new XmlSchemaObjectTable();
           schemaTypes = new XmlSchemaObjectTable();
       }
  -	
  +
       protected String getNamespace(String prefix) {
           return "" + namespaces.get(prefix);
       }
   
   
       public static XmlSchema read(Reader r, ValidationEventHandler veh) {
  -		return read( new InputSource(r), veh );
  +        return read(new InputSource(r), veh);
  +    }
  +
  +    public static XmlSchema read(InputSource inputSource, ValidationEventHandler veh) {
  +        try {
  +            DocumentBuilderFactory docFac = DocumentBuilderFactory.newInstance();
  +            docFac.setNamespaceAware(true);
  +            DocumentBuilder builder = docFac.newDocumentBuilder();
  +            Document doc = builder.parse(inputSource);
  +            return read(doc, veh);
  +        } catch (ParserConfigurationException e) {
  +            throw new XmlSchemaException(e.getMessage());
  +        } catch (IOException e) {
  +            throw new XmlSchemaException(e.getMessage());
  +        } catch (SAXException e) {
  +            throw new XmlSchemaException(e.getMessage());
  +        }
       }
   
  -	public static XmlSchema read(InputSource inputSource, ValidationEventHandler veh) {
  -		try{    
  -			DocumentBuilderFactory docFac = DocumentBuilderFactory.newInstance();            
  -			docFac.setNamespaceAware(true);
  -			DocumentBuilder builder = docFac.newDocumentBuilder();
  -			Document doc = builder.parse(inputSource);
  -			return read(doc, veh);
  -		}catch( ParserConfigurationException e ){
  -			throw new XmlSchemaException(e.getMessage());	
  -		}catch(IOException e){
  -			throw new XmlSchemaException(e.getMessage());
  -		}catch(SAXException e){
  -			throw new XmlSchemaException(e.getMessage());
  -		}
  -	}
  -
  -	public static XmlSchema read(Source source, ValidationEventHandler veh){
  -		try {
  -			TransformerFactory trFac = TransformerFactory.newInstance();
  -			ByteArrayOutputStream out = new ByteArrayOutputStream();
  -			StreamResult result = new StreamResult(out);
  -			javax.xml.transform.Transformer tr = trFac.newTransformer();
  +    public static XmlSchema read(Source source, ValidationEventHandler veh) {
  +        try {
  +            TransformerFactory trFac = TransformerFactory.newInstance();
  +            ByteArrayOutputStream out = new ByteArrayOutputStream();
  +            StreamResult result = new StreamResult(out);
  +            javax.xml.transform.Transformer tr = trFac.newTransformer();
               tr.setOutputProperty(OutputKeys.METHOD, "xml");
  -			tr.setOutputProperty(OutputKeys.OMIT_XML_DECLARATION, "yes");
  -			tr.transform(source, result);
  -			ByteArrayInputStream in = new ByteArrayInputStream( out.toByteArray());
  -			return read(new InputSource( in), veh);
  -		}catch( TransformerException e ){
  -			throw new XmlSchemaException(e.getMessage());
  -		}
  -	}
  -
  -	static XmlSchema read(Document doc, ValidationEventHandler veh){
  -		SchemaBuilder builder = new SchemaBuilder();
  -		return builder.build( doc, veh);
  -	}
  +            tr.setOutputProperty(OutputKeys.OMIT_XML_DECLARATION, "yes");
  +            tr.transform(source, result);
  +            ByteArrayInputStream in = new ByteArrayInputStream(out.toByteArray());
  +            return read(new InputSource(in), veh);
  +        } catch (TransformerException e) {
  +            throw new XmlSchemaException(e.getMessage());
  +        }
  +    }
  +
  +    static XmlSchema read(Document doc, ValidationEventHandler veh) {
  +        SchemaBuilder builder = new SchemaBuilder();
  +        return builder.build(doc, veh);
  +    }
   
       public XmlSchemaForm getAttributeFormDefault() {
           return attributeFormDefault;
  @@ -149,8 +197,8 @@
   
       public void setAttributeFormDefault(XmlSchemaForm value) {
           attributeFormDefault = value;
  -    }	
  -	
  +    }
  +
       public XmlSchemaObjectTable getAttributeGroups() {
           return attributeGroups;
       }
  @@ -187,7 +235,7 @@
           this.finalDefault = finalDefault;
       }
   
  -    public XmlSchemaObjectTable  getGroups() {
  +    public XmlSchemaObjectTable getGroups() {
           return groups;
       }
   
  @@ -221,7 +269,7 @@
       }
   
       public String getVersion() {
  -		return version;
  +        return version;
       }
   
       public void compile(ValidationEventHandler eh) {
  @@ -229,60 +277,60 @@
       }
   
       public void write(OutputStream out) {
  -		write(new OutputStreamWriter(out));
  +        write(new OutputStreamWriter(out));
       }
   
       public void write(Writer writer) {
  -		serialize_internal( this, writer);
  +        serialize_internal(this, writer);
       }
   
       private static void serialize_internal(XmlSchema schema, Writer out) {
           try {
  -			Document[] serializedSchemas = XmlSchemaSerializer.serializeSchema(schema, true);
  -			TransformerFactory trFac = TransformerFactory.newInstance();
  +            Document[] serializedSchemas = XmlSchemaSerializer.serializeSchema(schema, true);
  +            TransformerFactory trFac = TransformerFactory.newInstance();
               Source source = new DOMSource(serializedSchemas[0]);
               Result result = new StreamResult(out);
               javax.xml.transform.Transformer tr = trFac.newTransformer();
               tr.setOutputProperty(OutputKeys.OMIT_XML_DECLARATION, "yes");
  -			tr.setOutputProperty(OutputKeys.INDENT, "yes");			
  +            tr.setOutputProperty(OutputKeys.INDENT, "yes");
               tr.transform(source, result);
               out.flush();
           } catch (TransformerConfigurationException e) {
  -			throw new XmlSchemaException( e.getMessage() );
  +            throw new XmlSchemaException(e.getMessage());
           } catch (TransformerException e) {
  -			throw new XmlSchemaException( e.getMessage());
  -        }catch (XmlSchemaSerializer.XmlSchemaSerializerException e) {
  -			throw new XmlSchemaException( e.getMessage());
  -        }catch (IOException e) {
  -			throw new XmlSchemaException( e.getMessage());
  -        }
  -    }	
  -	
  -	public Hashtable getPrefixToNamespaceMap(){
  -		return namespaces;
  -	}
  -	
  -	public void setPrefixToNamespaceMap(Hashtable map){
  -		this.namespaces=map;
  -	}
  +            throw new XmlSchemaException(e.getMessage());
  +        } catch (XmlSchemaSerializer.XmlSchemaSerializerException e) {
  +            throw new XmlSchemaException(e.getMessage());
  +        } catch (IOException e) {
  +            throw new XmlSchemaException(e.getMessage());
  +        }
  +    }
   
  +    public Hashtable getPrefixToNamespaceMap() {
  +        return namespaces;
  +    }
  +
  +    public void setPrefixToNamespaceMap(Hashtable map) {
  +        this.namespaces = map;
  +    }
   
   
       static class SchemaBuilder {
           Document doc;
           XmlSchema schema;
  -		
  -		DocumentBuilderFactory docFac;
   
  -        SchemaBuilder(){
  +        DocumentBuilderFactory docFac;
  +
  +        SchemaBuilder() {
               schema = new XmlSchema();
           }
   
  -		XmlSchema build( Document doc, ValidationEventHandler veh){
  +        XmlSchema build(Document doc, ValidationEventHandler veh) {
               Element schemaEl = doc.getDocumentElement();
  -            return handleXmlSchemaElement( schemaEl );
  -		}
  -		/*
  +            return handleXmlSchemaElement(schemaEl);
  +        }
  +
  +        /*
   		  XmlSchema build(Reader r, ValidationEventHandler veh) {
   		  try{    
   		  DocumentBuilderFactory docFac = DocumentBuilderFactory.newInstance();            
  @@ -299,16 +347,16 @@
   		  }
   		  }
   		*/
  -        XmlSchema handleXmlSchemaElement( Element schemaEl ) {
  -			// get all the attributes along with the namespace declns
  +        XmlSchema handleXmlSchemaElement(Element schemaEl) {
  +            // get all the attributes along with the namespace declns
   
  -            setNamespaceAttributes( schema, schemaEl );
  -            schema.setElementFormDefault( this.getFormDefault(schemaEl, 
  -															  "elementFormDefault" ));
  -            schema.setAttributeFormDefault( this.getFormDefault(schemaEl, 
  -																"attributeFormDefault" ));
  -            schema.setBlockDefault(this.getDerivation(schemaEl,"blockDefault"));
  -            schema.setFinalDefault(this.getDerivation(schemaEl,"finalDefault"));
  +            setNamespaceAttributes(schema, schemaEl);
  +            schema.setElementFormDefault(this.getFormDefault(schemaEl,
  +                                                             "elementFormDefault"));
  +            schema.setAttributeFormDefault(this.getFormDefault(schemaEl,
  +                                                               "attributeFormDefault"));
  +            schema.setBlockDefault(this.getDerivation(schemaEl, "blockDefault"));
  +            schema.setFinalDefault(this.getDerivation(schemaEl, "finalDefault"));
   
               /***********
                * for ( each childElement) 
  @@ -334,790 +382,780 @@
                *			handleNotation
                */
   
  -            for( Element el = XDOMUtil.getFirstChildElementNS(
  -															  schemaEl,SCHEMA_NS); el != null; 
  -				 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  +            for (Element el = XDOMUtil.getFirstChildElementNS(
  +                    schemaEl, SCHEMA_NS); el != null;
  +                 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
   
  -				// String elPrefix = el.getPrefix() == null ? "" : el.getPrefix();
  +                // String elPrefix = el.getPrefix() == null ? "" : el.getPrefix();
                   //if(elPrefix.equals(schema.schema_ns_prefix)) {
  -                if( el.getLocalName().equals( "simpleType") ) {
  +                if (el.getLocalName().equals("simpleType")) {
                       XmlSchemaType type = handleSimpleType(schema, el, schemaEl);
  -                    schema.schemaTypes.collection.put( type.qualifiedName,type);
  -                    schema.items.add( type );
  -                }else if( el.getLocalName().equals( "complexType") ) {
  -                    XmlSchemaType type = handleComplexType(schema, el,schemaEl);
  -                    schema.schemaTypes.collection.put( type.qualifiedName,type);
  -                    schema.items.add( type );
  -                }else if( el.getLocalName().equals( "element") ) {
  -                    XmlSchemaElement element =handleElement(schema,el,schemaEl);						
  -                    if(element.qualifiedName != null)
  +                    schema.schemaTypes.collection.put(type.qualifiedName, type);
  +                    schema.items.add(type);
  +                } else if (el.getLocalName().equals("complexType")) {
  +                    XmlSchemaType type = handleComplexType(schema, el, schemaEl);
  +                    schema.schemaTypes.collection.put(type.qualifiedName, type);
  +                    schema.items.add(type);
  +                } else if (el.getLocalName().equals("element")) {
  +                    XmlSchemaElement element = handleElement(schema, el, schemaEl);
  +                    if (element.qualifiedName != null)
                           schema.elements.collection.put(
  -													   element.qualifiedName,element);
  -                    else if(element.refName != null)
  +                                element.qualifiedName, element);
  +                    else if (element.refName != null)
                           schema.elements.collection.put(
  -													   element.refName, element);
  -                    schema.items.add( element );
  -                }else if( el.getLocalName().equals( "include") ) {
  -                    XmlSchemaInclude include = handleInclude( schema, 
  -															  el, schemaEl);
  -                    schema.includes.add( include );
  -                    schema.items.add( include );
  -                }else if( el.getLocalName().equals( "import") ) {
  -                    XmlSchemaImport schemaImport = handleImport( schema, 
  -																 el, schemaEl);
  -                    schema.includes.add( schemaImport);
  -                    schema.items.add( schemaImport);
  -                }else if( el.getLocalName().equals( "group") ){
  -                    XmlSchemaGroup group = handleGroup( schema, el, schemaEl);
  -                    schema.groups.collection.put( group.name, group);
  -                    schema.items.add( group );
  -                }else if( el.getLocalName().equals( "attributeGroup" ) ){                    
  +                                element.refName, element);
  +                    schema.items.add(element);
  +                } else if (el.getLocalName().equals("include")) {
  +                    XmlSchemaInclude include = handleInclude(schema,
  +                                                             el, schemaEl);
  +                    schema.includes.add(include);
  +                    schema.items.add(include);
  +                } else if (el.getLocalName().equals("import")) {
  +                    XmlSchemaImport schemaImport = handleImport(schema,
  +                                                                el, schemaEl);
  +                    schema.includes.add(schemaImport);
  +                    schema.items.add(schemaImport);
  +                } else if (el.getLocalName().equals("group")) {
  +                    XmlSchemaGroup group = handleGroup(schema, el, schemaEl);
  +                    schema.groups.collection.put(group.name, group);
  +                    schema.items.add(group);
  +                } else if (el.getLocalName().equals("attributeGroup")) {
                       XmlSchemaAttributeGroup group = handleAttributeGroup(schema,
  -																		 el, schemaEl);
  -                    schema.attributeGroups.collection.put( group.name, group);
  -                    schema.items.add( group );
  -                }else if( el.getLocalName().equals( "attribute" ) ){
  -                    XmlSchemaAttribute attr = handleAttribute( schema, 
  -															   el, schemaEl);
  -                    schema.attributes.collection.put( attr.qualifiedName, attr);
  -                    schema.items.add( attr);
  -                }else if( el.getLocalName().equals( "redefine" ) ){
  -                    XmlSchemaRedefine redefine = handleRedefine(schema, 
  -																el, schemaEl);
  -                    schema.includes.add( redefine );
  -                }else if( el.getLocalName().equals( "notation" ) ){
  +                                                                         el, schemaEl);
  +                    schema.attributeGroups.collection.put(group.name, group);
  +                    schema.items.add(group);
  +                } else if (el.getLocalName().equals("attribute")) {
  +                    XmlSchemaAttribute attr = handleAttribute(schema,
  +                                                              el, schemaEl);
  +                    schema.attributes.collection.put(attr.qualifiedName, attr);
  +                    schema.items.add(attr);
  +                } else if (el.getLocalName().equals("redefine")) {
  +                    XmlSchemaRedefine redefine = handleRedefine(schema,
  +                                                                el, schemaEl);
  +                    schema.includes.add(redefine);
  +                } else if (el.getLocalName().equals("notation")) {
                       //TODO: implement Notation
  -                }else if( el.getLocalName().equals( "annotation" ) ){
  -					// Vidyanand : added this part
  -					XmlSchemaAnnotation annotation = handleAnnotation( schema, el, schemaEl);
  -					schema.setAnnotation(annotation);
  -				}
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    // Vidyanand : added this part
  +                    XmlSchemaAnnotation annotation = handleAnnotation(schema, el, schemaEl);
  +                    schema.setAnnotation(annotation);
  +                }
                   //}
               }
               return schema;
           }
   
  -		private XmlSchemaAnnotation handleAnnotation(XmlSchema schema, 
  -													 Element annotEl, Element schemaEl) {
  -			XmlSchemaAnnotation annotation = new XmlSchemaAnnotation();
  -			XmlSchemaObjectCollection collection = annotation.getItems();
  -			for( Element el = XDOMUtil.getFirstChildElement(annotEl);
  -				 el != null; el = XDOMUtil.getFirstChildElement(el)) {
  -				
  -				if( el.getLocalName().equals( "documentation")){
  -					XmlSchemaDocumentation doc = new XmlSchemaDocumentation();
  -					doc.setMarkup( el.getChildNodes());
  -					collection.add( doc );
  -				}
  -			}
  -			return annotation;	
  -		}
  -            
  -		
  -        private XmlSchemaRedefine handleRedefine(XmlSchema schema, 
  -												 Element redefineEl, Element schemaEl) {
  -            
  -			XmlSchemaRedefine redefine = new XmlSchemaRedefine();
  -			redefine.schemaLocation = 
  -				redefineEl.getAttribute("schemaLocation");
  -                
  -			redefine.schema = 
  -				getXmlSchemaFromLocation( redefine.schemaLocation);
  +        private XmlSchemaAnnotation handleAnnotation(XmlSchema schema,
  +                                                     Element annotEl, Element schemaEl) {
  +            XmlSchemaAnnotation annotation = new XmlSchemaAnnotation();
  +            XmlSchemaObjectCollection collection = annotation.getItems();
  +            for (Element el = XDOMUtil.getFirstChildElement(annotEl);
  +                 el != null; el = XDOMUtil.getFirstChildElement(el)) {
  +
  +                if (el.getLocalName().equals("documentation")) {
  +                    XmlSchemaDocumentation doc = new XmlSchemaDocumentation();
  +                    doc.setMarkup(el.getChildNodes());
  +                    collection.add(doc);
  +                }
  +            }
  +            return annotation;
  +        }
   
  -			for( Element el = XDOMUtil.getFirstChildElementNS(redefineEl, 
  -															  SCHEMA_NS) 
  -					 ;el != null; 
  -				 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -
  -				//                    String elPrefix = el.getPrefix() == null ? "" : el.getPrefix();
  -				//                    if(elPrefix.equals(schema.schema_ns_prefix)) {
  -				if( el.getLocalName().equals( "simpleType") ) {
  -					XmlSchemaType type = 
  -						handleSimpleType(schema, el, schemaEl);
  -                        
  -					redefine.schemaTypes.collection.put(type.qualifiedName, 
  -														type );
  -					redefine.items.add( type );
  -				} 
  -				else if( el.getLocalName().equals( "complexType") ) {
  -                        
  -					XmlSchemaType type = handleComplexType(schema, el, 
  -														   schemaEl);
   
  -					redefine.schemaTypes.collection.put(type.qualifiedName, 
  -														type );
  -					redefine.items.add( type );
  -				} 
  -				else if( el.getLocalName().equals( "group") ){
  -					XmlSchemaGroup group = handleGroup(schema, el, 
  -													   schemaEl);
  -					redefine.groups.collection.put( group.name, group);
  -					redefine.items.add( group );
  -				}
  -				else if( el.getLocalName().equals( "attributeGroup" ) ){
  -					XmlSchemaAttributeGroup group = 
  -						handleAttributeGroup( schema, el, schemaEl);
  -                        
  -					redefine.attributeGroups.collection.put( 
  -															group.name, group);
  -					redefine.items.add( group );
  -				}
  -				else if(el.getLocalName().equals("annotation")){
  -					XmlSchemaAnnotation annotation = handleAnnotation(el);
  -					redefine.setAnnotation(annotation);
  -				}
  -				//                  }
  -			}
  -			return redefine;
  -        }
  -
  -        void setNamespaceAttributes( XmlSchema schema, Element schemaEl ) {
  -			NamedNodeMap map = schemaEl.getAttributes();
  -			for( int i = 0 ; i<map.getLength(); i++ ) {
  -				if( map.item(i).getNodeName().startsWith("xmlns:") ) {
  -					schema.namespaces.put( map.item(i).getLocalName(),
  -										   map.item(i).getNodeValue());
  -
  -					if(map.item(i).getNodeValue().equals(SCHEMA_NS))
  -						schema.schema_ns_prefix = map.item(i).getLocalName();
  -				}else if( map.item(i).getNodeName().startsWith("xmlns") ){
  -					schema.namespaces.put("",map.item(i).getNodeValue());
  -				}
  -			}
  -			if( schemaEl.getAttributeNode( "targetNamespace")!= null) {
  -                    
  -				String contain = schemaEl.getAttribute("targetNamespace");
  -                    
  -				if(!schema.namespaces.containsValue(contain))
  -					putNamespace("",contain);
  -                    
  -				if (!contain.equals(""))
  -					schema.targetNamespace = contain;
  -                   
  -			}else{
  -				//schema.targetNamespace = "";
  -				putNamespace("", schema.targetNamespace);
  -			}
  -                    
  +        private XmlSchemaRedefine handleRedefine(XmlSchema schema,
  +                                                 Element redefineEl, Element schemaEl) {
  +
  +            XmlSchemaRedefine redefine = new XmlSchemaRedefine();
  +            redefine.schemaLocation =
  +                    redefineEl.getAttribute("schemaLocation");
  +
  +            redefine.schema =
  +                    getXmlSchemaFromLocation(redefine.schemaLocation);
  +
  +            for (Element el = XDOMUtil.getFirstChildElementNS(redefineEl,
  +                                                              SCHEMA_NS)
  +                    ; el != null;
  +                 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                //                    String elPrefix = el.getPrefix() == null ? "" : el.getPrefix();
  +                //                    if(elPrefix.equals(schema.schema_ns_prefix)) {
  +                if (el.getLocalName().equals("simpleType")) {
  +                    XmlSchemaType type =
  +                            handleSimpleType(schema, el, schemaEl);
  +
  +                    redefine.schemaTypes.collection.put(type.qualifiedName,
  +                                                        type);
  +                    redefine.items.add(type);
  +                } else if (el.getLocalName().equals("complexType")) {
  +
  +                    XmlSchemaType type = handleComplexType(schema, el,
  +                                                           schemaEl);
  +
  +                    redefine.schemaTypes.collection.put(type.qualifiedName,
  +                                                        type);
  +                    redefine.items.add(type);
  +                } else if (el.getLocalName().equals("group")) {
  +                    XmlSchemaGroup group = handleGroup(schema, el,
  +                                                       schemaEl);
  +                    redefine.groups.collection.put(group.name, group);
  +                    redefine.items.add(group);
  +                } else if (el.getLocalName().equals("attributeGroup")) {
  +                    XmlSchemaAttributeGroup group =
  +                            handleAttributeGroup(schema, el, schemaEl);
  +
  +                    redefine.attributeGroups.collection.put(
  +                            group.name, group);
  +                    redefine.items.add(group);
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    XmlSchemaAnnotation annotation = handleAnnotation(el);
  +                    redefine.setAnnotation(annotation);
  +                }
  +                //                  }
  +            }
  +            return redefine;
           }
  -        private void putNamespace(String prefix, String namespace){
  -			if(!schema.namespaces.containsKey(prefix)){
  -				schema.namespaces.put(prefix, namespace);
  -			}
  -			else{
  -				String genPrefix = "gen" + 
  -                    new java.util.Random().nextInt(999);
  -				schema.namespaces.put(prefix, namespace);
  -			}
  +
  +        void setNamespaceAttributes(XmlSchema schema, Element schemaEl) {
  +            NamedNodeMap map = schemaEl.getAttributes();
  +            for (int i = 0; i < map.getLength(); i++) {
  +                if (map.item(i).getNodeName().startsWith("xmlns:")) {
  +                    schema.namespaces.put(map.item(i).getLocalName(),
  +                                          map.item(i).getNodeValue());
  +
  +                    if (map.item(i).getNodeValue().equals(SCHEMA_NS))
  +                        schema.schema_ns_prefix = map.item(i).getLocalName();
  +                } else if (map.item(i).getNodeName().startsWith("xmlns")) {
  +                    schema.namespaces.put("", map.item(i).getNodeValue());
  +                }
  +            }
  +            if (schemaEl.getAttributeNode("targetNamespace") != null) {
  +
  +                String contain = schemaEl.getAttribute("targetNamespace");
  +
  +                if (!schema.namespaces.containsValue(contain))
  +                    putNamespace("", contain);
  +
  +                if (!contain.equals(""))
  +                    schema.targetNamespace = contain;
  +
  +            } else {
  +                //schema.targetNamespace = "";
  +                putNamespace("", schema.targetNamespace);
  +            }
  +
           }
   
  -        XmlSchemaSimpleType handleSimpleType( XmlSchema schema, 
  -											  Element simpleEl, Element schemaEl ){
  -            
  -			XmlSchemaSimpleType simpleType = new XmlSchemaSimpleType();
  -			if( simpleEl.hasAttribute("name")){
  -				String name = simpleEl.getAttribute("name") ;
  -                    
  -				simpleType.name = simpleEl.getAttribute("name");
  -				simpleType.qualifiedName = new QualifiedName( name, 
  -															  schema.targetNamespace);
  -			}
  +        private void putNamespace(String prefix, String namespace) {
  +            if (!schema.namespaces.containsKey(prefix)) {
  +                schema.namespaces.put(prefix, namespace);
  +            } else {
  +                String genPrefix = "gen" +
  +                        new java.util.Random().nextInt(999);
  +                schema.namespaces.put(prefix, namespace);
  +            }
  +        }
   
  -			if( simpleEl.hasAttribute( "final") ) {
  -				String finalstr= simpleEl.getAttribute("final");
  -                    
  -				if(finalstr.equalsIgnoreCase("all")| 
  -				   finalstr.equalsIgnoreCase("#all"))
  -                        
  -					simpleType.setFinal(
  -										new XmlSchemaDerivationMethod("All"));
  -				else
  -					simpleType.setFinal(
  -										new XmlSchemaDerivationMethod(finalstr));
  -			}
  -
  -			Element simpleTypeAnnotationEl = 
  -				XDOMUtil.getFirstChildElementNS(simpleEl,
  -												SCHEMA_NS,"annotation");
  -
  -			if(simpleTypeAnnotationEl != null){
  -				XmlSchemaAnnotation simpleTypeAnnotation = 
  -					handleAnnotation(simpleTypeAnnotationEl);
  -                    
  -				simpleType.setAnnotation(simpleTypeAnnotation);
  -			}
  +        XmlSchemaSimpleType handleSimpleType(XmlSchema schema,
  +                                             Element simpleEl, Element schemaEl) {
   
  -			Element unionEl, listEl, restrictionEl;
  -                
  -			if((restrictionEl = 
  -				XDOMUtil.getFirstChildElementNS(
  -												simpleEl,SCHEMA_NS,"restriction"))!= null ) {
  -                    
  -				XmlSchemaSimpleTypeRestriction restriction = 
  -					new XmlSchemaSimpleTypeRestriction();
  +            XmlSchemaSimpleType simpleType = new XmlSchemaSimpleType();
  +            if (simpleEl.hasAttribute("name")) {
  +                String name = simpleEl.getAttribute("name");
  +
  +                simpleType.name = simpleEl.getAttribute("name");
  +                simpleType.qualifiedName = new QualifiedName(name,
  +                                                             schema.targetNamespace);
  +            }
   
  -				Element restAnnotationEl = 
  -					XDOMUtil.getFirstChildElementNS(restrictionEl, 
  -													SCHEMA_NS,"annotation");
  -                    
  -				if(restAnnotationEl != null){
  -					XmlSchemaAnnotation restAnnotation =  
  -						handleAnnotation(restAnnotationEl);
  -					restriction.setAnnotation(restAnnotation);
  -				}
  -				/** if (restriction has a base attribute ) 
  -				 *		set the baseTypeName and look up the base type
  -				 *	else if( restricion has a SimpleType Element as child) 
  -				 *		get that element and do a handleSimpleType;
  -				 *	get the children of restriction other than annotation 
  -				 * and simpleTypes and construct facets from it;
  -				 * 
  -				 *	set the restriction has the content of the simpleType
  -				 * 
  -				 **/
  -                    
  -				Element inlineSimpleType = 
  -					XDOMUtil.getFirstChildElementNS(restrictionEl,
  -													SCHEMA_NS,"simpleType");
  -                    
  -				if( restrictionEl.hasAttribute( "base") ) {
  -					String name = restrictionEl.getAttribute("base");
  -					String[] temp = Tokenizer.tokenize(name, ":");
  -					String namespace = "";
  -
  -					if(temp.length != 1) {
  -						namespace = temp[0];
  -					}
  +            if (simpleEl.hasAttribute("final")) {
  +                String finalstr = simpleEl.getAttribute("final");
  +
  +                if (finalstr.equalsIgnoreCase("all") |
  +                        finalstr.equalsIgnoreCase("#all"))
  +
  +                    simpleType.setFinal(
  +                            new XmlSchemaDerivationMethod("All"));
  +                else
  +                    simpleType.setFinal(
  +                            new XmlSchemaDerivationMethod(finalstr));
  +            }
  +
  +            Element simpleTypeAnnotationEl =
  +                    XDOMUtil.getFirstChildElementNS(simpleEl,
  +                                                    SCHEMA_NS, "annotation");
  +
  +            if (simpleTypeAnnotationEl != null) {
  +                XmlSchemaAnnotation simpleTypeAnnotation =
  +                        handleAnnotation(simpleTypeAnnotationEl);
  +
  +                simpleType.setAnnotation(simpleTypeAnnotation);
  +            }
  +
  +            Element unionEl, listEl, restrictionEl;
  +
  +            if ((restrictionEl =
  +                    XDOMUtil.getFirstChildElementNS(
  +                            simpleEl, SCHEMA_NS, "restriction")) != null) {
  +
  +                XmlSchemaSimpleTypeRestriction restriction =
  +                        new XmlSchemaSimpleTypeRestriction();
  +
  +                Element restAnnotationEl =
  +                        XDOMUtil.getFirstChildElementNS(restrictionEl,
  +                                                        SCHEMA_NS, "annotation");
  +
  +                if (restAnnotationEl != null) {
  +                    XmlSchemaAnnotation restAnnotation =
  +                            handleAnnotation(restAnnotationEl);
  +                    restriction.setAnnotation(restAnnotation);
  +                }
  +                /** if (restriction has a base attribute ) 
  +                 *		set the baseTypeName and look up the base type
  +                 *	else if( restricion has a SimpleType Element as child) 
  +                 *		get that element and do a handleSimpleType;
  +                 *	get the children of restriction other than annotation 
  +                 * and simpleTypes and construct facets from it;
  +                 * 
  +                 *	set the restriction has the content of the simpleType
  +                 * 
  +                 **/
  +                    
  +                Element inlineSimpleType =
  +                        XDOMUtil.getFirstChildElementNS(restrictionEl,
  +                                                        SCHEMA_NS, "simpleType");
  +
  +                if (restrictionEl.hasAttribute("base")) {
  +                    String name = restrictionEl.getAttribute("base");
  +                    String[] temp = Tokenizer.tokenize(name, ":");
  +                    String namespace = "";
  +
  +                    if (temp.length != 1) {
  +                        namespace = temp[0];
  +                    }
                                     
  -					//let it crash because its mean being refered
  -					//to unregistered namespace
  -					namespace = schema.namespaces.get(namespace).toString();
  -                        
  -					restriction.baseTypeName = 
  -						new QualifiedName(name ,namespace);
  -				}
  -				else if (inlineSimpleType != null){
  -					XmlSchemaSimpleType baseType = 
  -						handleSimpleType(schema, inlineSimpleType,schemaEl);	
  -                        
  -					restriction.baseType = baseType;
  -				}
  -				for(Element el = XDOMUtil.getFirstChildElementNS(
  -																 restrictionEl,SCHEMA_NS)
  -                        ;el != null; 
  -					el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -                            
  -					if(!el.getLocalName().equals("annotation") 
  -					   && 
  -					   !el.getLocalName().equals("simpleType")){
  -
  -						XmlSchemaFacet facet =XmlSchemaFacet.construct( el);
  -						Element annotation = 
  -							XDOMUtil.getFirstChildElementNS(el, SCHEMA_NS,
  -															"annotation");
  -
  -						if(annotation != null){
  -							XmlSchemaAnnotation facetAnnotation =  
  -								handleAnnotation(annotation);
  -							facet.setAnnotation(facetAnnotation);
  -						}
  -						restriction.facets.add(facet);
  -					}
  -                    
  -				}
  -				simpleType.content = restriction;
  -                
  -			}else if((listEl = XDOMUtil.getFirstChildElementNS(simpleEl, 
  -															   SCHEMA_NS,"list"))!=null) {
  -                                                         
  -				XmlSchemaSimpleTypeList list = new XmlSchemaSimpleTypeList();
  -
  -				/******
  -				 * if( list has an itemType attribute ) 
  -				 *		set the baseTypeName and look up the base type
  -				 * else if( list has a SimpleTypeElement as child)
  -				 *		get that element and do a handleSimpleType
  -				 * 
  -				 * set the list has the content of the simpleType
  -				 */
  -				Element inlineListType, listAnnotationEl;
  -				if( listEl.hasAttribute( "itemType")) {
  -					String name = listEl.getAttribute("itemType");
  +                    //let it crash because its mean being refered
  +                    //to unregistered namespace
  +                    namespace = schema.namespaces.get(namespace).toString();
  +
  +                    restriction.baseTypeName =
  +                            new QualifiedName(name, namespace);
  +                } else if (inlineSimpleType != null) {
  +                    XmlSchemaSimpleType baseType =
  +                            handleSimpleType(schema, inlineSimpleType, schemaEl);
   
  -					String[] namespaceFromEl = Tokenizer.tokenize(name, ":");
  -					String namespace;
  -                        
  -					if(namespaceFromEl.length > 1){
  -						Object result = 
  -							schema.namespaces.get(namespaceFromEl[0]);
  -						if(result ==null)
  -							throw new XmlSchemaException("No namespace "
  -														 + "found in given itemType");
  -                            
  -						namespace = result.toString();
  -					}
  -					else
  -						namespace = schema.targetNamespace;
  -                        
  -					//Object nsFromEl = schema.namespaces.get(namespaceFromEl[0]); 
  -					//namespace = (nsFromEl==null)?  "": nsFromEl.toString();
  -                        
  -					list.itemTypeName = 
  -						new QualifiedName(name ,namespace);
  -                        
  -				}
  -				else if((inlineListType = 
  -						 XDOMUtil.getFirstChildElementNS(listEl, SCHEMA_NS, 
  -														 "simpleType"))!= null){
  -                                                          
  -					XmlSchemaSimpleType baseType = 
  -						handleSimpleType(schema, inlineListType, schemaEl);	
  -					list.itemType = baseType;
  -				}
  -
  -				if((listAnnotationEl = 
  -					XDOMUtil.getFirstChildElementNS(listEl, SCHEMA_NS,
  -													"annotation"))!=null){
  -                                                            
  -					XmlSchemaAnnotation listAnnotation = 
  -						handleAnnotation(listAnnotationEl);
  -                        
  -					list.setAnnotation(listAnnotation);
  -				} 
  -				simpleType.content = list;
  -
  -			}else if((unionEl = 
  -					  XDOMUtil.getFirstChildElementNS(simpleEl, SCHEMA_NS,
  -													  "union"))!=null) {
  -                    
  -				XmlSchemaSimpleTypeUnion union = 
  -					new XmlSchemaSimpleTypeUnion();
  +                    restriction.baseType = baseType;
  +                }
  +                for (Element el = XDOMUtil.getFirstChildElementNS(
  +                        restrictionEl, SCHEMA_NS)
  +                        ; el != null;
  +                     el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                    if (!el.getLocalName().equals("annotation")
  +                            &&
  +                            !el.getLocalName().equals("simpleType")) {
  +
  +                        XmlSchemaFacet facet = XmlSchemaFacet.construct(el);
  +                        Element annotation =
  +                                XDOMUtil.getFirstChildElementNS(el, SCHEMA_NS,
  +                                                                "annotation");
  +
  +                        if (annotation != null) {
  +                            XmlSchemaAnnotation facetAnnotation =
  +                                    handleAnnotation(annotation);
  +                            facet.setAnnotation(facetAnnotation);
  +                        }
  +                        restriction.facets.add(facet);
  +                    }
   
  -				/******
  -				 * if( union has a memberTypes attribute ) 
  -				 *		add the memberTypeSources string
  -				 *		for (each memberType in the list )
  -				 *			lookup(memberType)
  -				 *	for( all SimpleType child Elements) 
  -				 *		add the simpleTypeName (if any) to the memberType Sources	
  -				 *		do a handleSimpleType with the simpleTypeElement
  -				 */
  -				if( unionEl.hasAttribute( "memberTypes")){
  -					String memberTypes = unionEl.getAttribute("memberTypes");
  -					union.memberTypesSource = memberTypes;
  -					Vector v = new Vector();
  -					StringTokenizer tokenizer = new StringTokenizer(memberTypes," ");
  -					while (tokenizer.hasMoreTokens()){
  -						String member = tokenizer.nextToken();
  -						int pos = member.indexOf(":");
  -						String prefix = "";
  -						String localName="" ;
  -						if (pos == -1){
  -							localName = member;
  -						}
  -						else{
  -							prefix = member.substring(0,pos);
  -							localName=member.substring(pos+1);
  -						}
  -						v.add(new QualifiedName(localName,(String)schema.namespaces.get(prefix)));
  -					}
  -					union.memberTypesQNames = new QualifiedName[v.size()];
  -					v.copyInto(union.memberTypesQNames);                            
  -				}
  -                    
  -				Element inlineUnionType = 
  -					XDOMUtil.getFirstChildElementNS(unionEl, SCHEMA_NS,
  -													"simpleType");
  -				while(inlineUnionType != null){
  -                                                                
  -					XmlSchemaSimpleType unionSimpleType = 
  -						handleSimpleType(schema,inlineUnionType,
  -										 schemaEl);
  -                        
  -					union.baseTypes.add( unionSimpleType);
  -                        
  -					union.memberTypesSource += " " + unionSimpleType.name;
  -                        
  -					inlineUnionType = 
  -						XDOMUtil.getNextSiblingElementNS(inlineUnionType, 
  -														 SCHEMA_NS, 
  -														 "simpleType");
  -				}
  -
  -				//NodeList annotations = unionEl.getElementsByTagNameNS(
  -				//SCHEMA_NS, "annotation");
  -				Element unionAnnotationEl = 
  -					XDOMUtil.getFirstChildElementNS(unionEl, SCHEMA_NS,
  -													"annotation");
  -                    
  -				if(unionAnnotationEl != null){
  -					XmlSchemaAnnotation unionAnnotation = 
  -						handleAnnotation(unionAnnotationEl);
  -                        
  -					union.setAnnotation(unionAnnotation);
  -				}
  -				simpleType.content = union;
  -			}
  -			return simpleType;	
  +                }
  +                simpleType.content = restriction;
  +
  +            } else if ((listEl = XDOMUtil.getFirstChildElementNS(simpleEl,
  +                                                                 SCHEMA_NS, "list")) != null) {
  +
  +                XmlSchemaSimpleTypeList list = new XmlSchemaSimpleTypeList();
  +
  +                /******
  +                 * if( list has an itemType attribute ) 
  +                 *		set the baseTypeName and look up the base type
  +                 * else if( list has a SimpleTypeElement as child)
  +                 *		get that element and do a handleSimpleType
  +                 * 
  +                 * set the list has the content of the simpleType
  +                 */
  +                Element inlineListType, listAnnotationEl;
  +                if (listEl.hasAttribute("itemType")) {
  +                    String name = listEl.getAttribute("itemType");
  +
  +                    String[] namespaceFromEl = Tokenizer.tokenize(name, ":");
  +                    String namespace;
  +
  +                    if (namespaceFromEl.length > 1) {
  +                        Object result =
  +                                schema.namespaces.get(namespaceFromEl[0]);
  +                        if (result == null)
  +                            throw new XmlSchemaException("No namespace "
  +                                                         + "found in given itemType");
  +
  +                        namespace = result.toString();
  +                    } else
  +                        namespace = schema.targetNamespace;
  +                        
  +                    //Object nsFromEl = schema.namespaces.get(namespaceFromEl[0]); 
  +                    //namespace = (nsFromEl==null)?  "": nsFromEl.toString();
  +                        
  +                    list.itemTypeName =
  +                            new QualifiedName(name, namespace);
  +
  +                } else if ((inlineListType =
  +                        XDOMUtil.getFirstChildElementNS(listEl, SCHEMA_NS,
  +                                                        "simpleType")) != null) {
  +
  +                    XmlSchemaSimpleType baseType =
  +                            handleSimpleType(schema, inlineListType, schemaEl);
  +                    list.itemType = baseType;
  +                }
  +
  +                if ((listAnnotationEl =
  +                        XDOMUtil.getFirstChildElementNS(listEl, SCHEMA_NS,
  +                                                        "annotation")) != null) {
  +
  +                    XmlSchemaAnnotation listAnnotation =
  +                            handleAnnotation(listAnnotationEl);
  +
  +                    list.setAnnotation(listAnnotation);
  +                }
  +                simpleType.content = list;
  +
  +            } else if ((unionEl =
  +                    XDOMUtil.getFirstChildElementNS(simpleEl, SCHEMA_NS,
  +                                                    "union")) != null) {
  +
  +                XmlSchemaSimpleTypeUnion union =
  +                        new XmlSchemaSimpleTypeUnion();
  +
  +                /******
  +                 * if( union has a memberTypes attribute ) 
  +                 *		add the memberTypeSources string
  +                 *		for (each memberType in the list )
  +                 *			lookup(memberType)
  +                 *	for( all SimpleType child Elements) 
  +                 *		add the simpleTypeName (if any) to the memberType Sources	
  +                 *		do a handleSimpleType with the simpleTypeElement
  +                 */
  +                if (unionEl.hasAttribute("memberTypes")) {
  +                    String memberTypes = unionEl.getAttribute("memberTypes");
  +                    union.memberTypesSource = memberTypes;
  +                    Vector v = new Vector();
  +                    StringTokenizer tokenizer = new StringTokenizer(memberTypes, " ");
  +                    while (tokenizer.hasMoreTokens()) {
  +                        String member = tokenizer.nextToken();
  +                        int pos = member.indexOf(":");
  +                        String prefix = "";
  +                        String localName = "";
  +                        if (pos == -1) {
  +                            localName = member;
  +                        } else {
  +                            prefix = member.substring(0, pos);
  +                            localName = member.substring(pos + 1);
  +                        }
  +                        v.add(new QualifiedName(localName, (String) schema.namespaces.get(prefix)));
  +                    }
  +                    union.memberTypesQNames = new QualifiedName[v.size()];
  +                    v.copyInto(union.memberTypesQNames);
  +                }
  +
  +                Element inlineUnionType =
  +                        XDOMUtil.getFirstChildElementNS(unionEl, SCHEMA_NS,
  +                                                        "simpleType");
  +                while (inlineUnionType != null) {
  +
  +                    XmlSchemaSimpleType unionSimpleType =
  +                            handleSimpleType(schema, inlineUnionType,
  +                                             schemaEl);
  +
  +                    union.baseTypes.add(unionSimpleType);
  +
  +                    union.memberTypesSource += " " + unionSimpleType.name;
  +
  +                    inlineUnionType =
  +                            XDOMUtil.getNextSiblingElementNS(inlineUnionType,
  +                                                             SCHEMA_NS,
  +                                                             "simpleType");
  +                }
  +
  +                //NodeList annotations = unionEl.getElementsByTagNameNS(
  +                //SCHEMA_NS, "annotation");
  +                Element unionAnnotationEl =
  +                        XDOMUtil.getFirstChildElementNS(unionEl, SCHEMA_NS,
  +                                                        "annotation");
  +
  +                if (unionAnnotationEl != null) {
  +                    XmlSchemaAnnotation unionAnnotation =
  +                            handleAnnotation(unionAnnotationEl);
  +
  +                    union.setAnnotation(unionAnnotation);
  +                }
  +                simpleType.content = union;
  +            }
  +            return simpleType;
           }
   
  -        XmlSchemaComplexType handleComplexType( XmlSchema schema, 
  -												Element complexEl, Element schemaEl ){
  -                
  -			/******
  -			 * set the complexTypeName if any
  -			 * for( eachChildNode)
  -			 * if ( simpleContent) 
  -			 *		if( restrcition)
  -			 *			handle_simple_content_restriction
  -			 *		else if( extension)
  -			 *			handle_simple_content_extension
  -			 *		break; // it has to be the only child 
  -			 * else if( complexContent)
  -			 *		if( restriction) 
  -			 *			handle_complex_content_restriction
  -			 *		else if( extension) 
  -			 *			handle_complex_content_extension
  -			 *		break; // it has to be the only child 
  -			 * else if( group) 
  -			 *		if( group has ref)
  -			 *			store the group name
  -			 *		else
  -			 *			handleGroup
  -			 * else if( sequence )
  -			 *		handleSequence
  -			 * else if( all )
  -			 *		handleAll
  -			 * else if(choice)
  -			 *		handleChoice
  -			 * else if(attribute)
  -			 *		handleAttribute
  -			 * else if(attributeGroup)
  -			 *		handleAttributeGroup	
  -			 *  else if(anyAttribute)
  -			 *		handleAnyAttribute
  -			 */		
  +        XmlSchemaComplexType handleComplexType(XmlSchema schema,
  +                                               Element complexEl, Element schemaEl) {
   
  -			XmlSchemaComplexType ct = new XmlSchemaComplexType();
  +            /******
  +             * set the complexTypeName if any
  +             * for( eachChildNode)
  +             * if ( simpleContent) 
  +             *		if( restrcition)
  +             *			handle_simple_content_restriction
  +             *		else if( extension)
  +             *			handle_simple_content_extension
  +             *		break; // it has to be the only child 
  +             * else if( complexContent)
  +             *		if( restriction) 
  +             *			handle_complex_content_restriction
  +             *		else if( extension) 
  +             *			handle_complex_content_extension
  +             *		break; // it has to be the only child 
  +             * else if( group) 
  +             *		if( group has ref)
  +             *			store the group name
  +             *		else
  +             *			handleGroup
  +             * else if( sequence )
  +             *		handleSequence
  +             * else if( all )
  +             *		handleAll
  +             * else if(choice)
  +             *		handleChoice
  +             * else if(attribute)
  +             *		handleAttribute
  +             * else if(attributeGroup)
  +             *		handleAttributeGroup	
  +             *  else if(anyAttribute)
  +             *		handleAnyAttribute
  +             */		
  +
  +            XmlSchemaComplexType ct = new XmlSchemaComplexType();
   
  -			if( complexEl.hasAttribute( "name") ) {
  -				String name = complexEl.getAttribute("name");
  +            if (complexEl.hasAttribute("name")) {
  +                String name = complexEl.getAttribute("name");
                    
  -				//String namespace = (schema.targetNamespace==null)?
  -				//                  "":schema.targetNamespace;
  +                //String namespace = (schema.targetNamespace==null)?
  +                //                  "":schema.targetNamespace;
                                           
  -				ct.name = name;
  -				ct.qualifiedName = new QualifiedName(name , 
  -													 schema.targetNamespace);
  -			}
  -			for(Element el = XDOMUtil.getFirstChildElementNS(complexEl, 
  -															 SCHEMA_NS)
  -                    ;el != null; 
  -				el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -                    
  -				//String elPrefix = el.getPrefix() == null ? "" :
  -				//el.getPrefix();
  -				//if(elPrefix.equals(schema.schema_ns_prefix)) {
  -				if( el.getLocalName().equals( "sequence") ) {
  -					XmlSchemaSequence sequence = handleSequence(schema, 
  -																el, schemaEl);
  -                            
  -					ct.particle = sequence;
  -				} else if(el.getLocalName().equals("choice")) {
  -					XmlSchemaChoice choice = handleChoice(schema, 
  -														  el, schemaEl);
  -                            
  -					ct.particle = choice;
  -				} else if(el.getLocalName().equals("all")) {
  -					XmlSchemaAll all = handleAll(schema, el, schemaEl);
  -					ct.particle = all;
  -				} else if(el.getLocalName().equals("attribute")) {
  -					XmlSchemaAttribute attr = handleAttribute(schema, 
  -															  el, schemaEl);
  -					ct.attributes.add(attr);
  -				} else if(el.getLocalName().equals("attributeGroup")) {
  -					XmlSchemaAttributeGroupRef attrGroup = 
  -						handleAttributeGroupRef(schema, el,  schemaEl);
  -					ct.attributes.add(attrGroup);
  -				} else if(el.getLocalName().equals("group")) {
  -					XmlSchemaGroupRef group = 
  -						handleGroupRef(schema, el, schemaEl);
  -					ct.particle = (group.particle == null)? 
  -						(XmlSchemaParticle)group : group.particle;
  -				} else if(el.getLocalName().equals("simpleContent")) {
  -					XmlSchemaSimpleContent simpleContent = 
  -						handleSimpleContent(schema, el, schemaEl);
  -					ct.contentModel = simpleContent;
  -				}else if(el.getLocalName().equals("complexContent")) {
  -					XmlSchemaComplexContent complexContent = 
  -						handleComplexContent(schema, el, schemaEl);
  -					ct.contentModel = complexContent;
  -				}else if(el.getLocalName().equals("annotation")){
  -					XmlSchemaAnnotation ann = handleAnnotation(el);
  -					ct.setAnnotation(ann);
  -				}
  -				//}
  -			}
  -			if( complexEl.hasAttribute( "block") ) {
  -				String blockStr = complexEl.getAttribute("block");
  -				if(blockStr.equalsIgnoreCase("all")|
  -				   blockStr.equalsIgnoreCase("#all")){
  -                        
  -					ct.setBlock(new XmlSchemaDerivationMethod("All"));
  -				}
  -				else
  -					ct.setBlock(new XmlSchemaDerivationMethod(blockStr));
  -				//ct.setBlock(new XmlSchemaDerivationMethod(block));
  -			}
  -			if( complexEl.hasAttribute( "final") ) {
  -				String finalstr= complexEl.getAttribute("final");
  -				if(finalstr.equalsIgnoreCase("all")|
  -				   finalstr.equalsIgnoreCase("#all")){
  -                            
  -					ct.setFinal(new XmlSchemaDerivationMethod("All"));
  -				}
  -				else
  -					ct.setFinal(new XmlSchemaDerivationMethod(finalstr));
  -			}
  -			if( complexEl.hasAttribute( "abstract") ) {
  -				String abs= complexEl.getAttribute("abstract");
  -				if (abs.equalsIgnoreCase("true"))
  -					ct.setAbstract(true);
  -				else
  -					ct.setAbstract(false);
  -			}
  -			if( complexEl.hasAttribute( "mixed") ) {
  -				String mixed= complexEl.getAttribute("mixed");
  -				if (mixed.equalsIgnoreCase("true"))
  -					ct.setMixed(true);
  -				else
  -					ct.setMixed(false);
  -			}
  -			return ct;
  -        }
  -
  -        private XmlSchemaSimpleContent 
  -            handleSimpleContent(XmlSchema schema, Element simpleEl, 
  -								Element schemaEl) {
  -            
  -			XmlSchemaSimpleContent simpleContent = 
  -				new XmlSchemaSimpleContent();
  -                
  -			for(Element el = XDOMUtil.getFirstChildElementNS(simpleEl, 
  -															 SCHEMA_NS)
  -                    ;el != null; 
  -				el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -                        
  -				if( el.getLocalName().equals( "restriction") ) {
  -					XmlSchemaSimpleContentRestriction restriction = 
  -						handleSimpleContentRestriction(schema,el, schemaEl);
  -                            
  -					simpleContent.content = restriction;
  -				} else if( el.getLocalName().equals( "extension") ){
  -					XmlSchemaSimpleContentExtension ext = 
  -						handleSimpleContentExtension(schema, el, schemaEl);
  -					simpleContent.content = ext;
  -				}else if( el.getLocalName().equals( "annotation") ) {
  -					XmlSchemaAnnotation ann = handleAnnotation(el);
  -					simpleContent.setAnnotation(ann);
  -				}
  -			}
  -			return simpleContent;
  +                ct.name = name;
  +                ct.qualifiedName = new QualifiedName(name,
  +                                                     schema.targetNamespace);
  +            }
  +            for (Element el = XDOMUtil.getFirstChildElementNS(complexEl,
  +                                                              SCHEMA_NS)
  +                    ; el != null;
  +                 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                //String elPrefix = el.getPrefix() == null ? "" :
  +                //el.getPrefix();
  +                //if(elPrefix.equals(schema.schema_ns_prefix)) {
  +                if (el.getLocalName().equals("sequence")) {
  +                    XmlSchemaSequence sequence = handleSequence(schema,
  +                                                                el, schemaEl);
  +
  +                    ct.particle = sequence;
  +                } else if (el.getLocalName().equals("choice")) {
  +                    XmlSchemaChoice choice = handleChoice(schema,
  +                                                          el, schemaEl);
  +
  +                    ct.particle = choice;
  +                } else if (el.getLocalName().equals("all")) {
  +                    XmlSchemaAll all = handleAll(schema, el, schemaEl);
  +                    ct.particle = all;
  +                } else if (el.getLocalName().equals("attribute")) {
  +                    XmlSchemaAttribute attr = handleAttribute(schema,
  +                                                              el, schemaEl);
  +                    ct.attributes.add(attr);
  +                } else if (el.getLocalName().equals("attributeGroup")) {
  +                    XmlSchemaAttributeGroupRef attrGroup =
  +                            handleAttributeGroupRef(schema, el, schemaEl);
  +                    ct.attributes.add(attrGroup);
  +                } else if (el.getLocalName().equals("group")) {
  +                    XmlSchemaGroupRef group =
  +                            handleGroupRef(schema, el, schemaEl);
  +                    ct.particle = (group.particle == null)? 
  +                            (XmlSchemaParticle) group : group.particle;
  +                } else if (el.getLocalName().equals("simpleContent")) {
  +                    XmlSchemaSimpleContent simpleContent =
  +                            handleSimpleContent(schema, el, schemaEl);
  +                    ct.contentModel = simpleContent;
  +                } else if (el.getLocalName().equals("complexContent")) {
  +                    XmlSchemaComplexContent complexContent =
  +                            handleComplexContent(schema, el, schemaEl);
  +                    ct.contentModel = complexContent;
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    XmlSchemaAnnotation ann = handleAnnotation(el);
  +                    ct.setAnnotation(ann);
  +                }
  +                //}
  +            }
  +            if (complexEl.hasAttribute("block")) {
  +                String blockStr = complexEl.getAttribute("block");
  +                if (blockStr.equalsIgnoreCase("all") |
  +                        blockStr.equalsIgnoreCase("#all")) {
  +
  +                    ct.setBlock(new XmlSchemaDerivationMethod("All"));
  +                } else
  +                    ct.setBlock(new XmlSchemaDerivationMethod(blockStr));
  +                //ct.setBlock(new XmlSchemaDerivationMethod(block));
  +            }
  +            if (complexEl.hasAttribute("final")) {
  +                String finalstr = complexEl.getAttribute("final");
  +                if (finalstr.equalsIgnoreCase("all") |
  +                        finalstr.equalsIgnoreCase("#all")) {
  +
  +                    ct.setFinal(new XmlSchemaDerivationMethod("All"));
  +                } else
  +                    ct.setFinal(new XmlSchemaDerivationMethod(finalstr));
  +            }
  +            if (complexEl.hasAttribute("abstract")) {
  +                String abs = complexEl.getAttribute("abstract");
  +                if (abs.equalsIgnoreCase("true"))
  +                    ct.setAbstract(true);
  +                else
  +                    ct.setAbstract(false);
  +            }
  +            if (complexEl.hasAttribute("mixed")) {
  +                String mixed = complexEl.getAttribute("mixed");
  +                if (mixed.equalsIgnoreCase("true"))
  +                    ct.setMixed(true);
  +                else
  +                    ct.setMixed(false);
  +            }
  +            return ct;
           }
   
  -        private XmlSchemaComplexContent handleComplexContent(XmlSchema schema, 
  -															 Element complexEl, Element schemaEl) {
  -                
  -			XmlSchemaComplexContent complexContent = 
  -				new XmlSchemaComplexContent();
  -                
  -			for(Element el =
  -                    XDOMUtil.getFirstChildElementNS(complexEl, SCHEMA_NS); 
  -				el != null; 
  -				el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  -                        
  -				if( el.getLocalName().equals( "restriction") ) {
  -					XmlSchemaComplexContentRestriction restriction = 
  -						handleComplexContentRestriction(schema, el, 
  -														schemaEl);
  -					complexContent.content = restriction;
  -				}else if( el.getLocalName().equals( "extension") ) {
  -					XmlSchemaComplexContentExtension ext = 
  -						handleComplexContentExtension(schema, el,
  -													  schemaEl);
  -					complexContent.content = ext;
  -				}else if( el.getLocalName().equals( "annotation") ) {   
  -					XmlSchemaAnnotation ann = handleAnnotation(el);
  -					complexContent.setAnnotation(ann);
  -				}
  -			}
  -			return complexContent;
  -        }
  -
  -        private XmlSchemaSimpleContentRestriction 
  -            handleSimpleContentRestriction(XmlSchema schema, 
  -										   Element restrictionEl,  Element schemaEl) {
  -            
  -			XmlSchemaSimpleContentRestriction restriction = 
  -				new XmlSchemaSimpleContentRestriction();
  +        private XmlSchemaSimpleContent
  +                handleSimpleContent(XmlSchema schema, Element simpleEl,
  +                                    Element schemaEl) {
  +
  +            XmlSchemaSimpleContent simpleContent =
  +                    new XmlSchemaSimpleContent();
  +
  +            for (Element el = XDOMUtil.getFirstChildElementNS(simpleEl,
  +                                                              SCHEMA_NS)
  +                    ; el != null;
  +                 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                if (el.getLocalName().equals("restriction")) {
  +                    XmlSchemaSimpleContentRestriction restriction =
  +                            handleSimpleContentRestriction(schema, el, schemaEl);
  +
  +                    simpleContent.content = restriction;
  +                } else if (el.getLocalName().equals("extension")) {
  +                    XmlSchemaSimpleContentExtension ext =
  +                            handleSimpleContentExtension(schema, el, schemaEl);
  +                    simpleContent.content = ext;
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    XmlSchemaAnnotation ann = handleAnnotation(el);
  +                    simpleContent.setAnnotation(ann);
  +                }
  +            }
  +            return simpleContent;
  +        }
   
  -			if(restrictionEl.hasAttribute("base")) {
  -				String name = restrictionEl.getAttribute("base");
  -				Object result = schema.namespaces.get(
  -													  Tokenizer.tokenize(name, ":")[0]); 
  -
  -				if(result ==null)
  -					throw new XmlSchemaException("No namespace found in "
  -												 + "given base simple content type");
  -                    
  -				restriction.baseTypeName = 
  -					new QualifiedName(name , result.toString());
  -			}
  -
  -			if(restrictionEl.hasAttribute("id")) 
  -				restriction.id = restrictionEl.getAttribute("id");
  -
  -			// check back simpleContent tag children to add attributes and simpleType if any occur
  -			for( 
  -				Element el = XDOMUtil.getFirstChildElementNS(restrictionEl, 
  -															 SCHEMA_NS)
  -                    ;el != null; 
  -				el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -                        
  -				if(el.getLocalName().equals("attribute")) {
  -					XmlSchemaAttribute attr = 
  -						handleAttribute(schema, el,  schemaEl);
  -					restriction.attributes.add(attr);
  -				} else if(el.getLocalName().equals("attributeGroup")) {
  -					XmlSchemaAttributeGroupRef attrGroup = 
  -						handleAttributeGroupRef(schema, el,  schemaEl);
  -					restriction.attributes.add(attrGroup);
  -				} else if( el.getLocalName().equals( "simpleType") ) {
  -					XmlSchemaSimpleType type = 
  -						handleSimpleType(schema, el, schemaEl);
  -					restriction.baseType = type;
  -				} else if( el.getLocalName().equals( "anyAttribute") ){
  -					restriction.anyAttribute =  
  -						handleAnyAttribute(schema, el, schemaEl);
  -				} else if( el.getLocalName().equals( "annotation") ){
  -					XmlSchemaAnnotation ann = handleAnnotation(el);
  -					restriction.setAnnotation(ann);
  -				} else {
  -					XmlSchemaFacet facet = XmlSchemaFacet.construct(el);
  -					NodeList annotations = 
  -						el.getElementsByTagNameNS(SCHEMA_NS, "annotation");
  -
  -					if(annotations.getLength() > 0 ){
  -						XmlSchemaAnnotation facetAnnotation = 
  -							handleAnnotation(el);
  -						facet.setAnnotation(facetAnnotation);
  -					}
  -					restriction.facets.add(facet);
  -				} 
  -			}
  -			return restriction;
  -        }
  -
  -        private XmlSchemaSimpleContentExtension 
  -            handleSimpleContentExtension(XmlSchema schema, Element extEl, 
  -										 Element schemaEl) {
  -                
  -			XmlSchemaSimpleContentExtension ext = 
  -				new XmlSchemaSimpleContentExtension();
  -                
  -			if(extEl.hasAttribute("base")) {
  -				String name = extEl.getAttribute("base");
  -				String nsFromEl = Tokenizer.tokenize(name, ":")[0];
  -				Object result = schema.namespaces.get(nsFromEl);
  -                    
  -				if(result ==null)
  -					throw new XmlSchemaException("No namespace found in "
  -												 + "given base simple content type");
  -                    
  -				ext.baseTypeName = new QualifiedName(name ,
  -													 result.toString());
  -			}
  -
  -			for( 
  -				Element el=XDOMUtil.getFirstChildElementNS(extEl, SCHEMA_NS)
  -                    ;el != null; 
  -				el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  -                        
  -				if(el.getLocalName().equals("attribute")) {
  -					XmlSchemaAttribute attr = 
  -						handleAttribute(schema, el,  schemaEl);
  -					ext.attributes.add(attr);
  -				} else if(el.getLocalName().equals("attributeGroup")) {
  -					XmlSchemaAttributeGroupRef attrGroup = 
  -						handleAttributeGroupRef(schema, el,  schemaEl);
  -					ext.attributes.add(attrGroup);
  -				} else if( el.getLocalName().equals( "anyAttribute") ){
  -					ext.anyAttribute =  
  -						handleAnyAttribute(schema, el, schemaEl);
  -				} else if( el.getLocalName().equals( "annotation") ){
  -					XmlSchemaAnnotation ann = handleAnnotation(el);
  -					ext.setAnnotation(ann);
  -				}
  -			}
  -			return ext;
  +        private XmlSchemaComplexContent handleComplexContent(XmlSchema schema,
  +                                                             Element complexEl, Element schemaEl) {
  +
  +            XmlSchemaComplexContent complexContent =
  +                    new XmlSchemaComplexContent();
  +
  +            for (Element el =
  +                    XDOMUtil.getFirstChildElementNS(complexEl, SCHEMA_NS);
  +                 el != null;
  +                 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                if (el.getLocalName().equals("restriction")) {
  +                    XmlSchemaComplexContentRestriction restriction =
  +                            handleComplexContentRestriction(schema, el,
  +                                                            schemaEl);
  +                    complexContent.content = restriction;
  +                } else if (el.getLocalName().equals("extension")) {
  +                    XmlSchemaComplexContentExtension ext =
  +                            handleComplexContentExtension(schema, el,
  +                                                          schemaEl);
  +                    complexContent.content = ext;
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    XmlSchemaAnnotation ann = handleAnnotation(el);
  +                    complexContent.setAnnotation(ann);
  +                }
  +            }
  +            return complexContent;
  +        }
  +
  +        private XmlSchemaSimpleContentRestriction
  +                handleSimpleContentRestriction(XmlSchema schema,
  +                                               Element restrictionEl, Element schemaEl) {
  +
  +            XmlSchemaSimpleContentRestriction restriction =
  +                    new XmlSchemaSimpleContentRestriction();
  +
  +            if (restrictionEl.hasAttribute("base")) {
  +                String name = restrictionEl.getAttribute("base");
  +                Object result = schema.namespaces.get(
  +                        Tokenizer.tokenize(name, ":")[0]);
  +
  +                if (result == null)
  +                    throw new XmlSchemaException("No namespace found in "
  +                                                 + "given base simple content type");
  +
  +                restriction.baseTypeName =
  +                        new QualifiedName(name, result.toString());
  +            }
  +
  +            if (restrictionEl.hasAttribute("id"))
  +                restriction.id = restrictionEl.getAttribute("id");
  +
  +            // check back simpleContent tag children to add attributes and simpleType if any occur
  +            for (
  +                    Element el = XDOMUtil.getFirstChildElementNS(restrictionEl,
  +                                                                 SCHEMA_NS)
  +                            ; el != null;
  +                    el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                if (el.getLocalName().equals("attribute")) {
  +                    XmlSchemaAttribute attr =
  +                            handleAttribute(schema, el, schemaEl);
  +                    restriction.attributes.add(attr);
  +                } else if (el.getLocalName().equals("attributeGroup")) {
  +                    XmlSchemaAttributeGroupRef attrGroup =
  +                            handleAttributeGroupRef(schema, el, schemaEl);
  +                    restriction.attributes.add(attrGroup);
  +                } else if (el.getLocalName().equals("simpleType")) {
  +                    XmlSchemaSimpleType type =
  +                            handleSimpleType(schema, el, schemaEl);
  +                    restriction.baseType = type;
  +                } else if (el.getLocalName().equals("anyAttribute")) {
  +                    restriction.anyAttribute =
  +                            handleAnyAttribute(schema, el, schemaEl);
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    XmlSchemaAnnotation ann = handleAnnotation(el);
  +                    restriction.setAnnotation(ann);
  +                } else {
  +                    XmlSchemaFacet facet = XmlSchemaFacet.construct(el);
  +                    NodeList annotations =
  +                            el.getElementsByTagNameNS(SCHEMA_NS, "annotation");
  +
  +                    if (annotations.getLength() > 0) {
  +                        XmlSchemaAnnotation facetAnnotation =
  +                                handleAnnotation(el);
  +                        facet.setAnnotation(facetAnnotation);
  +                    }
  +                    restriction.facets.add(facet);
  +                }
  +            }
  +            return restriction;
           }
  -        
  +
  +        private XmlSchemaSimpleContentExtension
  +                handleSimpleContentExtension(XmlSchema schema, Element extEl,
  +                                             Element schemaEl) {
  +
  +            XmlSchemaSimpleContentExtension ext =
  +                    new XmlSchemaSimpleContentExtension();
  +
  +            if (extEl.hasAttribute("base")) {
  +                String name = extEl.getAttribute("base");
  +                String nsFromEl = Tokenizer.tokenize(name, ":")[0];
  +                Object result = schema.namespaces.get(nsFromEl);
  +
  +                if (result == null)
  +                    throw new XmlSchemaException("No namespace found in "
  +                                                 + "given base simple content type");
  +
  +                ext.baseTypeName = new QualifiedName(name,
  +                                                     result.toString());
  +            }
  +
  +            for (
  +                    Element el = XDOMUtil.getFirstChildElementNS(extEl, SCHEMA_NS)
  +                            ; el != null;
  +                    el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                if (el.getLocalName().equals("attribute")) {
  +                    XmlSchemaAttribute attr =
  +                            handleAttribute(schema, el, schemaEl);
  +                    ext.attributes.add(attr);
  +                } else if (el.getLocalName().equals("attributeGroup")) {
  +                    XmlSchemaAttributeGroupRef attrGroup =
  +                            handleAttributeGroupRef(schema, el, schemaEl);
  +                    ext.attributes.add(attrGroup);
  +                } else if (el.getLocalName().equals("anyAttribute")) {
  +                    ext.anyAttribute =
  +                            handleAnyAttribute(schema, el, schemaEl);
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    XmlSchemaAnnotation ann = handleAnnotation(el);
  +                    ext.setAnnotation(ann);
  +                }
  +            }
  +            return ext;
  +        }
  +
           private XmlSchemaComplexContentRestriction
  -            handleComplexContentRestriction(XmlSchema schema,
  -											Element restrictionEl, Element schemaEl) {
  -                
  -            XmlSchemaComplexContentRestriction restriction = 
  -                new XmlSchemaComplexContentRestriction();
  -            
  -            if(restrictionEl.hasAttribute("base")) {
  -                String name = restrictionEl.getAttribute("base");                
  -                String prefix ;
  -                if (name.indexOf(":")<0)
  -                    prefix="";
  +                handleComplexContentRestriction(XmlSchema schema,
  +                                                Element restrictionEl, Element schemaEl) {
  +
  +            XmlSchemaComplexContentRestriction restriction =
  +                    new XmlSchemaComplexContentRestriction();
  +
  +            if (restrictionEl.hasAttribute("base")) {
  +                String name = restrictionEl.getAttribute("base");
  +                String prefix;
  +                if (name.indexOf(":") < 0)
  +                    prefix = "";
                   else
  -                    prefix=name.substring(0,name.indexOf(":"));
  -                
  +                    prefix = name.substring(0, name.indexOf(":"));
  +
                   Object result = schema.namespaces.get(prefix);
  -                
  -                if(result ==null)
  +
  +                if (result == null)
                       throw new XmlSchemaException("No namespace found in "
  -												 + "given base complex content base type");
  -                    
  +                                                 + "given base complex content base type");
   
  -                restriction.baseTypeName = new QualifiedName(name , 
  -															 result.toString());
  +
  +                restriction.baseTypeName = new QualifiedName(name,
  +                                                             result.toString());
               }
  -            for(Element el=XDOMUtil.getFirstChildElementNS(restrictionEl, 
  -														   SCHEMA_NS)
  -					;el != null; 
  -                el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -                    
  -                if( el.getLocalName().equals( "sequence") ) {
  -                    XmlSchemaSequence sequence = 
  -                        handleSequence(schema, el, schemaEl);
  +            for (Element el = XDOMUtil.getFirstChildElementNS(restrictionEl,
  +                                                              SCHEMA_NS)
  +                    ; el != null;
  +                 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                if (el.getLocalName().equals("sequence")) {
  +                    XmlSchemaSequence sequence =
  +                            handleSequence(schema, el, schemaEl);
                       restriction.particle = sequence;
  -                } else if(el.getLocalName().equals("choice")) {
  +                } else if (el.getLocalName().equals("choice")) {
                       XmlSchemaChoice choice = handleChoice(schema, el, schemaEl);
                       restriction.particle = choice;
  -                } else if(el.getLocalName().equals("all")) {
  +                } else if (el.getLocalName().equals("all")) {
                       XmlSchemaAll all = handleAll(schema, el, schemaEl);
                       restriction.particle = all;
  -                } else if(el.getLocalName().equals("attribute")) {
  -                    XmlSchemaAttribute attr = 
  -                        handleAttribute(schema, el,  schemaEl);
  +                } else if (el.getLocalName().equals("attribute")) {
  +                    XmlSchemaAttribute attr =
  +                            handleAttribute(schema, el, schemaEl);
                       restriction.attributes.add(attr);
  -                } else if(el.getLocalName().equals("attributeGroup")) {
  -                    XmlSchemaAttributeGroupRef attrGroup = 
  -                        handleAttributeGroupRef(schema, el,  schemaEl);
  +                } else if (el.getLocalName().equals("attributeGroup")) {
  +                    XmlSchemaAttributeGroupRef attrGroup =
  +                            handleAttributeGroupRef(schema, el, schemaEl);
                       restriction.attributes.add(attrGroup);
  -                } else if(el.getLocalName().equals("group")) {
  -                    XmlSchemaGroupRef group = 
  -                        handleGroupRef(schema, el, schemaEl);
  +                } else if (el.getLocalName().equals("group")) {
  +                    XmlSchemaGroupRef group =
  +                            handleGroupRef(schema, el, schemaEl);
                       restriction.particle = group;
  -                } else if( el.getLocalName().equals( "anyAttribute") ){
  -                    restriction.anyAttribute =  
  -                        handleAnyAttribute(schema, el, schemaEl);
  -                }else if( el.getLocalName().equals( "annotation") ) {
  +                } else if (el.getLocalName().equals("anyAttribute")) {
  +                    restriction.anyAttribute =
  +                            handleAnyAttribute(schema, el, schemaEl);
  +                } else if (el.getLocalName().equals("annotation")) {
                       XmlSchemaAnnotation ann = handleAnnotation(el);
                       restriction.setAnnotation(ann);
                   }
  @@ -1125,221 +1163,221 @@
               return restriction;
           }
   
  -        private XmlSchemaComplexContentExtension 
  -            handleComplexContentExtension(XmlSchema schema, 
  -										  Element extEl, Element schemaEl) {
  -                
  -			XmlSchemaComplexContentExtension ext = 
  -				new XmlSchemaComplexContentExtension();
  -                
  -			if(extEl.hasAttribute("base")) {
  -				String name = extEl.getAttribute("base");
  -				String namespaceFromEl="";
  -				if (name.indexOf(":")>0)
  -					namespaceFromEl= Tokenizer.tokenize(name, ":")[0];
  -				Object result = schema.namespaces.get(namespaceFromEl);
  -                    
  -				if(result ==null)
  -					throw new XmlSchemaException("No namespace found in "
  -												 + "given base complex content base type");
  +        private XmlSchemaComplexContentExtension
  +                handleComplexContentExtension(XmlSchema schema,
  +                                              Element extEl, Element schemaEl) {
  +
  +            XmlSchemaComplexContentExtension ext =
  +                    new XmlSchemaComplexContentExtension();
  +
  +            if (extEl.hasAttribute("base")) {
  +                String name = extEl.getAttribute("base");
  +                String namespaceFromEl = "";
  +                if (name.indexOf(":") > 0)
  +                    namespaceFromEl = Tokenizer.tokenize(name, ":")[0];
  +                Object result = schema.namespaces.get(namespaceFromEl);
  +
  +                if (result == null)
  +                    throw new XmlSchemaException("No namespace found in "
  +                                                 + "given base complex content base type");
                       
  -				//                    String namespace = (result==null)? "" : result.toString();
  +                //                    String namespace = (result==null)? "" : result.toString();
                       
  -				ext.baseTypeName = new QualifiedName(name ,
  -													 result.toString());
  -			}
  -
  -			for( Element el =XDOMUtil.getFirstChildElementNS(extEl, SCHEMA_NS)
  -					 ;el != null; 
  -				 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -                        
  -				if( el.getLocalName().equals( "sequence") ) {
  -					XmlSchemaSequence sequence = 
  -						handleSequence(schema, el, schemaEl);
  -					ext.particle = sequence;
  -				} else if(el.getLocalName().equals("choice")) {
  -					XmlSchemaChoice choice = 
  -						handleChoice(schema, el, schemaEl);
  -					ext.particle = choice;
  -				} else if(el.getLocalName().equals("all")) {
  -					XmlSchemaAll all = handleAll(schema, el, schemaEl);
  -					ext.particle = all;
  -				} else if(el.getLocalName().equals("attribute")) {
  -					XmlSchemaAttribute attr = 
  -						handleAttribute(schema, el,  schemaEl);
  -					ext.attributes.add(attr);
  -				} else if(el.getLocalName().equals("attributeGroup")) {
  -					XmlSchemaAttributeGroupRef attrGroup = 
  -						handleAttributeGroupRef(schema, el,  schemaEl);
  -					ext.attributes.add(attrGroup);
  -				} else if(el.getLocalName().equals("group")) {
  -					XmlSchemaGroupRef group = 
  -						handleGroupRef(schema, el, schemaEl);
  -					ext.particle = group;
  -				} else if( el.getLocalName().equals( "anyAttribute") ){
  -					ext.anyAttribute =  
  -						handleAnyAttribute(schema, el, schemaEl);
  -				} else if( el.getLocalName().equals( "annotation") ) {
  -					XmlSchemaAnnotation ann = handleAnnotation(el);
  -					ext.setAnnotation(ann);
  -				}
  -			}
  -			return ext;
  -        }
  -
  -        private XmlSchemaAttributeGroupRef 
  -            handleAttributeGroupRef(XmlSchema schema, Element attrGroupEl, 
  -									Element schemaEl) {
  -            
  -			XmlSchemaAttributeGroupRef attrGroup = 
  -				new XmlSchemaAttributeGroupRef();
  +                ext.baseTypeName = new QualifiedName(name,
  +                                                     result.toString());
  +            }
  +
  +            for (Element el = XDOMUtil.getFirstChildElementNS(extEl, SCHEMA_NS)
  +                    ; el != null;
  +                 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                if (el.getLocalName().equals("sequence")) {
  +                    XmlSchemaSequence sequence =
  +                            handleSequence(schema, el, schemaEl);
  +                    ext.particle = sequence;
  +                } else if (el.getLocalName().equals("choice")) {
  +                    XmlSchemaChoice choice =
  +                            handleChoice(schema, el, schemaEl);
  +                    ext.particle = choice;
  +                } else if (el.getLocalName().equals("all")) {
  +                    XmlSchemaAll all = handleAll(schema, el, schemaEl);
  +                    ext.particle = all;
  +                } else if (el.getLocalName().equals("attribute")) {
  +                    XmlSchemaAttribute attr =
  +                            handleAttribute(schema, el, schemaEl);
  +                    ext.attributes.add(attr);
  +                } else if (el.getLocalName().equals("attributeGroup")) {
  +                    XmlSchemaAttributeGroupRef attrGroup =
  +                            handleAttributeGroupRef(schema, el, schemaEl);
  +                    ext.attributes.add(attrGroup);
  +                } else if (el.getLocalName().equals("group")) {
  +                    XmlSchemaGroupRef group =
  +                            handleGroupRef(schema, el, schemaEl);
  +                    ext.particle = group;
  +                } else if (el.getLocalName().equals("anyAttribute")) {
  +                    ext.anyAttribute =
  +                            handleAnyAttribute(schema, el, schemaEl);
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    XmlSchemaAnnotation ann = handleAnnotation(el);
  +                    ext.setAnnotation(ann);
  +                }
  +            }
  +            return ext;
  +        }
  +
  +        private XmlSchemaAttributeGroupRef
  +                handleAttributeGroupRef(XmlSchema schema, Element attrGroupEl,
  +                                        Element schemaEl) {
   
  -            if(attrGroupEl.hasAttribute("ref")) {
  +            XmlSchemaAttributeGroupRef attrGroup =
  +                    new XmlSchemaAttributeGroupRef();
  +
  +            if (attrGroupEl.hasAttribute("ref")) {
                   String ref = attrGroupEl.getAttribute("ref");
                   String parts[] = Tokenizer.tokenize(ref, ":");
                   String prefix = "";
                   if (parts.length > 1)
  -                    prefix=parts[0];
  +                    prefix = parts[0];
                   Object result = schema.namespaces.get(prefix);
                   //String namespace = (result==null)? "":result.toString(); 
  -                if(result ==null)
  +                if (result == null)
                       throw new XmlSchemaException("No namespace found in "
  -												 + "given ref name");
  -                    
  -                
  +                                                 + "given ref name");
  +
  +
                   attrGroup.refName = new QualifiedName(ref, result.toString());
               }
   
  -            if(attrGroupEl.hasAttribute("id"))
  +            if (attrGroupEl.hasAttribute("id"))
                   attrGroup.id = attrGroupEl.getAttribute("id");
   
  -            Element annotationEl = 
  -                XDOMUtil.getFirstChildElementNS(attrGroupEl,
  -												SCHEMA_NS,"annotation");
  -            
  -            if(annotationEl != null){
  +            Element annotationEl =
  +                    XDOMUtil.getFirstChildElementNS(attrGroupEl,
  +                                                    SCHEMA_NS, "annotation");
  +
  +            if (annotationEl != null) {
                   XmlSchemaAnnotation annotation = handleAnnotation(annotationEl);
                   attrGroup.setAnnotation(annotation);
               }
               return attrGroup;
           }
   
  -        private XmlSchemaSequence handleSequence(XmlSchema schema, 
  -												 Element sequenceEl, Element schemaEl) {
  -            
  -			XmlSchemaSequence sequence = new XmlSchemaSequence();
  -			for(Element el=XDOMUtil.getFirstChildElementNS(sequenceEl,SCHEMA_NS)
  -                    ;el != null; 
  -				el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -                        
  -				if( el.getLocalName().equals( "sequence") ) {
  -					XmlSchemaSequence seq = handleSequence(schema, el, 
  -														   schemaEl);
  -					sequence.items.add(seq);
  -				} else if( el.getLocalName().equals( "element") ) {
  -					XmlSchemaElement element = handleElement(schema, el, 
  -															 schemaEl);
  -					sequence.items.add(element);
  -				} else if(el.getLocalName().equals("group")) {
  -					XmlSchemaGroupRef group = handleGroupRef(schema, el, 
  -															 schemaEl);
  -					sequence.items.add(group);
  -				} else if(el.getLocalName().equals("choice")) {
  -					XmlSchemaChoice choice = handleChoice(schema, el, 
  -														  schemaEl);
  -					sequence.items.add(choice);
  -				} else if(el.getLocalName().equals("any")) {
  -					XmlSchemaAny any = handleAny(schema, el, schemaEl);
  -					sequence.items.add(any);
  -				} else if(el.getLocalName().equals("annotation")){
  -					XmlSchemaAnnotation annotation = handleAnnotation(el);
  -					sequence.setAnnotation(annotation);
  -				}
  -			}
  -			return sequence;
  +        private XmlSchemaSequence handleSequence(XmlSchema schema,
  +                                                 Element sequenceEl, Element schemaEl) {
  +
  +            XmlSchemaSequence sequence = new XmlSchemaSequence();
  +            for (Element el = XDOMUtil.getFirstChildElementNS(sequenceEl, SCHEMA_NS)
  +                    ; el != null;
  +                 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                if (el.getLocalName().equals("sequence")) {
  +                    XmlSchemaSequence seq = handleSequence(schema, el,
  +                                                           schemaEl);
  +                    sequence.items.add(seq);
  +                } else if (el.getLocalName().equals("element")) {
  +                    XmlSchemaElement element = handleElement(schema, el,
  +                                                             schemaEl);
  +                    sequence.items.add(element);
  +                } else if (el.getLocalName().equals("group")) {
  +                    XmlSchemaGroupRef group = handleGroupRef(schema, el,
  +                                                             schemaEl);
  +                    sequence.items.add(group);
  +                } else if (el.getLocalName().equals("choice")) {
  +                    XmlSchemaChoice choice = handleChoice(schema, el,
  +                                                          schemaEl);
  +                    sequence.items.add(choice);
  +                } else if (el.getLocalName().equals("any")) {
  +                    XmlSchemaAny any = handleAny(schema, el, schemaEl);
  +                    sequence.items.add(any);
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    XmlSchemaAnnotation annotation = handleAnnotation(el);
  +                    sequence.setAnnotation(annotation);
  +                }
  +            }
  +            return sequence;
           }
   
  -        private XmlSchemaAny handleAny(XmlSchema schema, Element anyEl, 
  -									   Element schemaEl) {
  -            
  -			XmlSchemaAny any = new XmlSchemaAny();
  -                
  -			if(anyEl.hasAttribute("namespace"))
  -				any.namespace = anyEl.getAttribute("namespace");
  +        private XmlSchemaAny handleAny(XmlSchema schema, Element anyEl,
  +                                       Element schemaEl) {
   
  -			if(anyEl.hasAttribute("processContents")) {
  -				String processContent = getEnumString(anyEl, 
  -													  "processContents");   
  -                    
  -				any.processContent  = 
  -					new XmlSchemaContentProcessing(processContent);
  -			}
  -
  -			Element annotationEl = XDOMUtil.getFirstChildElementNS(anyEl, 
  -																   SCHEMA_NS, "annotation");
  -
  -			if(annotationEl != null){
  -				XmlSchemaAnnotation annotation = 
  -					handleAnnotation(annotationEl);
  -				any.setAnnotation(annotation);
  -			}
  -			any.minOccurs = getMinOccurs(anyEl);
  -			any.maxOccurs = getMaxOccurs(anyEl);
  -
  -			return any;
  -        }
  -
  -        private XmlSchemaChoice handleChoice(XmlSchema schema, Element choiceEl, 
  -											 Element schemaEl) {
  -			XmlSchemaChoice choice = new XmlSchemaChoice();
  -
  -			if(choiceEl.hasAttribute("id"))
  -				choice.id = choiceEl.getAttribute("id");
  -
  -			for( Element el =XDOMUtil.getFirstChildElementNS(choiceEl,
  -															 SCHEMA_NS) 
  -					 ;el != null; 
  -				 el =XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -
  -				if( el.getLocalName().equals( "sequence") ) {
  -					XmlSchemaSequence seq = 
  -						handleSequence(schema, el, schemaEl);
  -					choice.items.add(seq);
  -				} else if( el.getLocalName().equals( "element") ) {
  -					XmlSchemaElement element = 
  -						handleElement(schema, el, schemaEl);
  -					choice.items.add(element);
  -				} else if(el.getLocalName().equals("group")) {
  -					XmlSchemaGroupRef group = 
  -						handleGroupRef(schema, el, schemaEl);
  -					choice.items.add(group);
  -				} else if(el.getLocalName().equals("choice")) {
  -					XmlSchemaChoice choiceItem = 
  -						handleChoice(schema, el, schemaEl);
  -					choice.items.add(choiceItem);
  -				} else if(el.getLocalName().equals("any")) {
  -					XmlSchemaAny any = handleAny(schema, el, schemaEl);
  -					choice.items.add(any);
  -				} else if(el.getLocalName().equals("annotation")){
  -					XmlSchemaAnnotation annotation = handleAnnotation(el);
  -					choice.setAnnotation(annotation);
  -				}
  -			}
  -			return choice;
  +            XmlSchemaAny any = new XmlSchemaAny();
  +
  +            if (anyEl.hasAttribute("namespace"))
  +                any.namespace = anyEl.getAttribute("namespace");
  +
  +            if (anyEl.hasAttribute("processContents")) {
  +                String processContent = getEnumString(anyEl,
  +                                                      "processContents");
  +
  +                any.processContent =
  +                        new XmlSchemaContentProcessing(processContent);
  +            }
  +
  +            Element annotationEl = XDOMUtil.getFirstChildElementNS(anyEl,
  +                                                                   SCHEMA_NS, "annotation");
  +
  +            if (annotationEl != null) {
  +                XmlSchemaAnnotation annotation =
  +                        handleAnnotation(annotationEl);
  +                any.setAnnotation(annotation);
  +            }
  +            any.minOccurs = getMinOccurs(anyEl);
  +            any.maxOccurs = getMaxOccurs(anyEl);
  +
  +            return any;
  +        }
  +
  +        private XmlSchemaChoice handleChoice(XmlSchema schema, Element choiceEl,
  +                                             Element schemaEl) {
  +            XmlSchemaChoice choice = new XmlSchemaChoice();
  +
  +            if (choiceEl.hasAttribute("id"))
  +                choice.id = choiceEl.getAttribute("id");
  +
  +            for (Element el = XDOMUtil.getFirstChildElementNS(choiceEl,
  +                                                              SCHEMA_NS)
  +                    ; el != null;
  +                 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                if (el.getLocalName().equals("sequence")) {
  +                    XmlSchemaSequence seq =
  +                            handleSequence(schema, el, schemaEl);
  +                    choice.items.add(seq);
  +                } else if (el.getLocalName().equals("element")) {
  +                    XmlSchemaElement element =
  +                            handleElement(schema, el, schemaEl);
  +                    choice.items.add(element);
  +                } else if (el.getLocalName().equals("group")) {
  +                    XmlSchemaGroupRef group =
  +                            handleGroupRef(schema, el, schemaEl);
  +                    choice.items.add(group);
  +                } else if (el.getLocalName().equals("choice")) {
  +                    XmlSchemaChoice choiceItem =
  +                            handleChoice(schema, el, schemaEl);
  +                    choice.items.add(choiceItem);
  +                } else if (el.getLocalName().equals("any")) {
  +                    XmlSchemaAny any = handleAny(schema, el, schemaEl);
  +                    choice.items.add(any);
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    XmlSchemaAnnotation annotation = handleAnnotation(el);
  +                    choice.setAnnotation(annotation);
  +                }
  +            }
  +            return choice;
           }
  -        private XmlSchemaAll handleAll(XmlSchema schema, Element allEl, 
  -									   Element schemaEl) {
  +
  +        private XmlSchemaAll handleAll(XmlSchema schema, Element allEl,
  +                                       Element schemaEl) {
   
               XmlSchemaAll all = new XmlSchemaAll();
   
  -            for( Element el = XDOMUtil.getFirstChildElementNS(allEl, SCHEMA_NS); 
  -				 el != null; el=XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -                    
  -                if( el.getLocalName().equals( "element") ) {
  -                    XmlSchemaElement element =handleElement(schema,el,schemaEl);
  +            for (Element el = XDOMUtil.getFirstChildElementNS(allEl, SCHEMA_NS);
  +                 el != null; el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                if (el.getLocalName().equals("element")) {
  +                    XmlSchemaElement element = handleElement(schema, el, schemaEl);
                       all.items.add(element);
  -                }
  -                else if(el.getLocalName().equals("annotation")){
  +                } else if (el.getLocalName().equals("annotation")) {
                       XmlSchemaAnnotation annotation = handleAnnotation(el);
                       all.setAnnotation(annotation);
                   }
  @@ -1347,278 +1385,276 @@
               return all;
           }
   
  -        private XmlSchemaGroup handleGroup( XmlSchema schema, Element groupEl, 
  -											Element schemaEl){
  -            
  -			XmlSchemaGroup group = new XmlSchemaGroup();
  -			group.name = groupEl.getAttribute( "name" );
  -                
  -			for( Element el = XDOMUtil.getFirstChildElementNS(groupEl, 
  -                                                              SCHEMA_NS); 
  -				 el != null; 
  -				 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -                        
  -				if( el.getLocalName().equals( "all") ){
  -					group.particle = handleAll(schema, el, schemaEl);
  -				}else if( el.getLocalName().equals( "sequence") ){
  -					group.particle = handleSequence(schema, el, schemaEl);
  -				}else if( el.getLocalName().equals( "choice") ){
  -					group.particle = handleChoice(schema, el, schemaEl);
  -				}else if(el.getLocalName().equals("annotation")){
  -					XmlSchemaAnnotation groupAnnotation = 
  -						handleAnnotation(el);
  -					group.setAnnotation(groupAnnotation);
  -				}
  -			}
  -			return group;
  -        }
  -		
  -        private XmlSchemaAttributeGroup handleAttributeGroup( XmlSchema schema, 
  -															  Element groupEl, Element schemaEl){
  -			XmlSchemaAttributeGroup attrGroup = 
  -				new XmlSchemaAttributeGroup();
  -
  -			if(groupEl.hasAttribute("name"))
  -				attrGroup.name = groupEl.getAttribute("name");
  -			if(groupEl.hasAttribute("id"))
  -				attrGroup.id = groupEl.getAttribute("id");
  -
  -			for( Element el = XDOMUtil.getFirstChildElementNS(groupEl, 
  -															  SCHEMA_NS); 
  -				 el != null; 
  -				 el =XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -
  -				if( el.getLocalName().equals( "attribute") ){
  -					XmlSchemaAttribute attr = 
  -						handleAttribute(schema, el, schemaEl);
  -					attrGroup.attributes.add(attr);
  -				}else if( el.getLocalName().equals( "attributeGroup") ){
  -					XmlSchemaAttributeGroupRef attrGroupRef = 
  -						handleAttributeGroupRef(schema, el, schemaEl);
  -					attrGroup.attributes.add( attrGroupRef );
  -				}else if( el.getLocalName().equals( "anyAttribute") ){
  -					attrGroup.anyAttribute =  handleAnyAttribute(schema, 
  -																 el, schemaEl);
  -				}else if(el.getLocalName().equals("annotation")){
  -					XmlSchemaAnnotation ann = handleAnnotation(el);
  -					attrGroup.setAnnotation(ann);
  -				}
  -			}
  -			return attrGroup;
  -        }
  -	
  -        private XmlSchemaAnyAttribute handleAnyAttribute( XmlSchema schema, 
  -														  Element anyAttrEl, Element schemaEl) {
  -
  -			XmlSchemaAnyAttribute anyAttr = new XmlSchemaAnyAttribute();
  -
  -			if(anyAttrEl.hasAttribute("namespace"))
  -				anyAttr.namespace = anyAttrEl.getAttribute("namespace");
  -
  -			if(anyAttrEl.hasAttribute("processContents")){
  -
  -				String contentProcessing = getEnumString(anyAttrEl,
  -														 "processContents");
  -
  -				anyAttr.processContent  = new XmlSchemaContentProcessing(
  -																		 contentProcessing);
  -			}
  -			if(anyAttrEl.hasAttribute("id"))
  -				anyAttr.id = anyAttrEl.getAttribute("id");
  -
  -			Element annotationEl = 
  -				XDOMUtil.getFirstChildElementNS(anyAttrEl, 
  -												SCHEMA_NS,"annotation");
  -
  -			if(annotationEl != null){
  -				XmlSchemaAnnotation annotation = 
  -					handleAnnotation(annotationEl);
  -                    
  -				anyAttr.setAnnotation(annotation);
  -			}
  -			return anyAttr;
  -        }
  -			
  -        private XmlSchemaGroupRef handleGroupRef(XmlSchema schema, 
  -												 Element groupEl, Element schemaEl) {
  -            
  -			XmlSchemaGroupRef group = new XmlSchemaGroupRef();
  +        private XmlSchemaGroup handleGroup(XmlSchema schema, Element groupEl,
  +                                           Element schemaEl) {
   
  -			Element annotationEl = XDOMUtil.getFirstChildElementNS(groupEl, 
  -																   SCHEMA_NS,
  -																   "annotation");
  -                
  -			if(annotationEl != null){
  -				XmlSchemaAnnotation annotation = 
  -					handleAnnotation(annotationEl);
  -                  
  -				group.setAnnotation(annotation);
  -			} 	
  -
  -			if(groupEl.hasAttribute("ref")) {
  -				String ref = groupEl.getAttribute("ref");
  -				String parts[] = Tokenizer.tokenize(ref,":");
  -				String prefix = "";
  -				if (parts.length >1 )
  -					prefix=parts[0];
  -				Object result = schema.namespaces.get(prefix);
  -				//String namespace = (result==null)?"":result.toString();
  -				if(result ==null)
  -					throw new XmlSchemaException("No namespace found in "
  -												 + "given ref group");
  -                    
  -				group.refName = new QualifiedName(ref, result.toString());
  -                    
  -				return group;
  -			} 
  -			for( Element el = XDOMUtil.getFirstChildElementNS(groupEl, 
  -															  SCHEMA_NS) 
  -					 ;el != null; 
  -				 el = XDOMUtil.getNextSiblingElement(el)){
  -                        
  -				if( el.getLocalName().equals( "sequence") ) {
  -					XmlSchemaSequence sequence = 
  -						handleSequence(schema, el, schemaEl);
  -					group.particle = sequence;
  -				} else if(el.getLocalName().equals("all")) {
  -					XmlSchemaAll all = handleAll(schema, el, schemaEl);
  -					group.particle = all;
  -				} else if(el.getLocalName().equals("choice")) {
  -					XmlSchemaChoice choice = handleChoice(schema, el, 
  -														  schemaEl);
  -					group.particle = choice;
  -				} 			
  -			}
  -			return group;
  -        }
  -
  -        private XmlSchemaAttribute handleAttribute(XmlSchema schema, 
  -												   Element attrEl, Element schemaEl) {                
  -			//todo: need to implement different rule of attribute such as 
  -			//restriction between ref and name.  This can be implemented 
  -			//in the compile function 
  -			XmlSchemaAttribute attr = new XmlSchemaAttribute();
  -                
  -			if(attrEl.hasAttribute("name")) {
  -				String name = attrEl.getAttribute("name");
  -				//String namespace = (schema.targetNamespace==null)?
  -				//                  "" :schema.targetNamespace;
  -                    
  -				attr.name = name;
  -				attr.qualifiedName = new QualifiedName(name , 
  -													   schema.targetNamespace); 
  -			}
  -
  -			if(attrEl.hasAttribute("type")) {
  -				String name = attrEl.getAttribute("type");
  -				String type[] = Tokenizer.tokenize(name,":");
  -				String namespace;
  -                    
  -				if(type.length > 1){
  -					Object result = schema.namespaces.get(type[0]);
  -					if(result ==null)
  -						throw new XmlSchemaException("No namespace found" 
  -													 + " in given attribute type");
  -                    
  -					namespace = result.toString();
  -				}
  -				else
  -					namespace = schema.targetNamespace;
  -                        
  -				attr.schemaTypeName =  new QualifiedName(name, namespace);
  -			}
  -			if(attrEl.hasAttribute("default")) 
  -				attr.defaultValue  = attrEl.getAttribute("default");
  -
  -			if(attrEl.hasAttribute("fixed"))
  -				attr.fixedValue = attrEl.getAttribute("fixed");
  -
  -			if(attrEl.hasAttribute("form")) {
  -				String formValue = getEnumString(attrEl, "form");
  -				attr.form = new XmlSchemaForm(formValue);
  -			}
  -			if(attrEl.hasAttribute("id")) 
  -				attr.id = attrEl.getAttribute("id"); 
  -
  -
  -			if(attrEl.hasAttribute("use")) {
  -				String useType = getEnumString(attrEl, "use");
  -				attr.use = new XmlSchemaUse(useType);
  -			}
  -			if(attrEl.hasAttribute("ref")) {
  -				String name = attrEl.getAttribute("ref");
  -				String[] namespaceFromEl = Tokenizer.tokenize(name, ":");
  -				String namespace;
  -                    
  -				if(namespaceFromEl.length > 1){
  -					Object result = 
  -						schema.namespaces.get(namespaceFromEl[0]);
  -					if(result ==null)
  -						throw new XmlSchemaException("No namespace found in"
  -													 + " given ref");
  -					namespace = result.toString();
  -				}
  -				else
  -					namespace = schema.targetNamespace;
  -                    
  -				attr.refName = new QualifiedName(name, namespace);
  -				attr.name = name.substring(name.indexOf(":")+1);
  -			}
  -
  -			Element simpleTypeEl = 
  -				XDOMUtil.getFirstChildElementNS(attrEl, 
  -												SCHEMA_NS,"simpleType");
  -                
  -			if( simpleTypeEl != null) {
  -				attr.schemaType = handleSimpleType(schema, simpleTypeEl, 
  -												   schemaEl);
  -			}
  -
  -			Element annotationEl = 
  -				XDOMUtil.getFirstChildElementNS(attrEl, 
  -												SCHEMA_NS,"annotation");
  -                
  -			if(annotationEl != null){
  -				XmlSchemaAnnotation annotation = 
  -					handleAnnotation(annotationEl);
  -                    
  -				attr.setAnnotation(annotation);
  -			}
  +            XmlSchemaGroup group = new XmlSchemaGroup();
  +            group.name = groupEl.getAttribute("name");
  +
  +            for (Element el = XDOMUtil.getFirstChildElementNS(groupEl,
  +                                                              SCHEMA_NS);
  +                 el != null;
  +                 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                if (el.getLocalName().equals("all")) {
  +                    group.particle = handleAll(schema, el, schemaEl);
  +                } else if (el.getLocalName().equals("sequence")) {
  +                    group.particle = handleSequence(schema, el, schemaEl);
  +                } else if (el.getLocalName().equals("choice")) {
  +                    group.particle = handleChoice(schema, el, schemaEl);
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    XmlSchemaAnnotation groupAnnotation =
  +                            handleAnnotation(el);
  +                    group.setAnnotation(groupAnnotation);
  +                }
  +            }
  +            return group;
  +        }
  +
  +        private XmlSchemaAttributeGroup handleAttributeGroup(XmlSchema schema,
  +                                                             Element groupEl, Element schemaEl) {
  +            XmlSchemaAttributeGroup attrGroup =
  +                    new XmlSchemaAttributeGroup();
  +
  +            if (groupEl.hasAttribute("name"))
  +                attrGroup.name = groupEl.getAttribute("name");
  +            if (groupEl.hasAttribute("id"))
  +                attrGroup.id = groupEl.getAttribute("id");
  +
  +            for (Element el = XDOMUtil.getFirstChildElementNS(groupEl,
  +                                                              SCHEMA_NS);
  +                 el != null;
  +                 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                if (el.getLocalName().equals("attribute")) {
  +                    XmlSchemaAttribute attr =
  +                            handleAttribute(schema, el, schemaEl);
  +                    attrGroup.attributes.add(attr);
  +                } else if (el.getLocalName().equals("attributeGroup")) {
  +                    XmlSchemaAttributeGroupRef attrGroupRef =
  +                            handleAttributeGroupRef(schema, el, schemaEl);
  +                    attrGroup.attributes.add(attrGroupRef);
  +                } else if (el.getLocalName().equals("anyAttribute")) {
  +                    attrGroup.anyAttribute = handleAnyAttribute(schema,
  +                                                                el, schemaEl);
  +                } else if (el.getLocalName().equals("annotation")) {
  +                    XmlSchemaAnnotation ann = handleAnnotation(el);
  +                    attrGroup.setAnnotation(ann);
  +                }
  +            }
  +            return attrGroup;
  +        }
  +
  +        private XmlSchemaAnyAttribute handleAnyAttribute(XmlSchema schema,
  +                                                         Element anyAttrEl, Element schemaEl) {
  +
  +            XmlSchemaAnyAttribute anyAttr = new XmlSchemaAnyAttribute();
  +
  +            if (anyAttrEl.hasAttribute("namespace"))
  +                anyAttr.namespace = anyAttrEl.getAttribute("namespace");
  +
  +            if (anyAttrEl.hasAttribute("processContents")) {
  +
  +                String contentProcessing = getEnumString(anyAttrEl,
  +                                                         "processContents");
  +
  +                anyAttr.processContent = new XmlSchemaContentProcessing(
  +                        contentProcessing);
  +            }
  +            if (anyAttrEl.hasAttribute("id"))
  +                anyAttr.id = anyAttrEl.getAttribute("id");
  +
  +            Element annotationEl =
  +                    XDOMUtil.getFirstChildElementNS(anyAttrEl,
  +                                                    SCHEMA_NS, "annotation");
  +
  +            if (annotationEl != null) {
  +                XmlSchemaAnnotation annotation =
  +                        handleAnnotation(annotationEl);
  +
  +                anyAttr.setAnnotation(annotation);
  +            }
  +            return anyAttr;
  +        }
  +
  +        private XmlSchemaGroupRef handleGroupRef(XmlSchema schema,
  +                                                 Element groupEl, Element schemaEl) {
  +
  +            XmlSchemaGroupRef group = new XmlSchemaGroupRef();
  +
  +            Element annotationEl = XDOMUtil.getFirstChildElementNS(groupEl,
  +                                                                   SCHEMA_NS,
  +                                                                   "annotation");
  +
  +            if (annotationEl != null) {
  +                XmlSchemaAnnotation annotation =
  +                        handleAnnotation(annotationEl);
  +
  +                group.setAnnotation(annotation);
  +            }
  +
  +            if (groupEl.hasAttribute("ref")) {
  +                String ref = groupEl.getAttribute("ref");
  +                String parts[] = Tokenizer.tokenize(ref, ":");
  +                String prefix = "";
  +                if (parts.length > 1)
  +                    prefix = parts[0];
  +                Object result = schema.namespaces.get(prefix);
  +                //String namespace = (result==null)?"":result.toString();
  +                if (result == null)
  +                    throw new XmlSchemaException("No namespace found in "
  +                                                 + "given ref group");
  +
  +                group.refName = new QualifiedName(ref, result.toString());
   
  -			NamedNodeMap attrNodes = attrEl.getAttributes();
  -			Vector attrs = new Vector();
  -			for( int i=0; i<attrNodes.getLength(); i++ ) {
  -				Attr att = (Attr) attrNodes.item(i);
  -				if( !att.getName().equals( "name" ) &&
  -					!att.getName().equals( "type" ) &&
  -					!att.getName().equals( "default" ) &&
  -					!att.getName().equals( "fixed" ) &&
  -					!att.getName().equals( "form" ) &&
  -					!att.getName().equals( "id" ) &&
  -					!att.getName().equals( "use" ) &&
  -					!att.getName().equals( "ref" ) ) {
  -						
  -
  -					attrs.add( att);
  -					String value = att.getValue();
  -						
  -					if( value.indexOf( ":") > -1 ) {
  -						// there is a possiblily of some namespace mapping
  -						String prefix = value.substring( 0, value.indexOf( ":" ));
  -						//String value = ( String) value.substring( value.indexOf( ":" ) + 1);
  -						String namespace = ( String) schema.namespaces.get( prefix);
  -						if( namespace != null ) {
  -							Attr nsAttr = attrEl.getOwnerDocument().createAttribute(  "xmlns:" + prefix);
  -							nsAttr.setValue( namespace );
  -							attrs.add( nsAttr );
  -						}
  -					} 
  -				}
  -			}
  -				
  -			if( attrs.size() >0 ) 
  -				attr.setUnhandledAttributes( (Attr []) attrs.toArray(new Attr[0]) );		
  -			return attr;
  +                return group;
  +            }
  +            for (Element el = XDOMUtil.getFirstChildElementNS(groupEl,
  +                                                              SCHEMA_NS)
  +                    ; el != null;
  +                 el = XDOMUtil.getNextSiblingElement(el)) {
  +
  +                if (el.getLocalName().equals("sequence")) {
  +                    XmlSchemaSequence sequence =
  +                            handleSequence(schema, el, schemaEl);
  +                    group.particle = sequence;
  +                } else if (el.getLocalName().equals("all")) {
  +                    XmlSchemaAll all = handleAll(schema, el, schemaEl);
  +                    group.particle = all;
  +                } else if (el.getLocalName().equals("choice")) {
  +                    XmlSchemaChoice choice = handleChoice(schema, el,
  +                                                          schemaEl);
  +                    group.particle = choice;
  +                }
  +            }
  +            return group;
  +        }
  +
  +        private XmlSchemaAttribute handleAttribute(XmlSchema schema,
  +                                                   Element attrEl, Element schemaEl) {
  +            //todo: need to implement different rule of attribute such as 
  +            //restriction between ref and name.  This can be implemented 
  +            //in the compile function 
  +            XmlSchemaAttribute attr = new XmlSchemaAttribute();
  +
  +            if (attrEl.hasAttribute("name")) {
  +                String name = attrEl.getAttribute("name");
  +                //String namespace = (schema.targetNamespace==null)?
  +                //                  "" :schema.targetNamespace;
  +                    
  +                attr.name = name;
  +                attr.qualifiedName = new QualifiedName(name,
  +                                                       schema.targetNamespace);
  +            }
  +
  +            if (attrEl.hasAttribute("type")) {
  +                String name = attrEl.getAttribute("type");
  +                String type[] = Tokenizer.tokenize(name, ":");
  +                String namespace;
  +
  +                if (type.length > 1) {
  +                    Object result = schema.namespaces.get(type[0]);
  +                    if (result == null)
  +                        throw new XmlSchemaException("No namespace found"
  +                                                     + " in given attribute type");
  +
  +                    namespace = result.toString();
  +                } else
  +                    namespace = schema.targetNamespace;
  +
  +                attr.schemaTypeName = new QualifiedName(name, namespace);
  +            }
  +            if (attrEl.hasAttribute("default"))
  +                attr.defaultValue = attrEl.getAttribute("default");
  +
  +            if (attrEl.hasAttribute("fixed"))
  +                attr.fixedValue = attrEl.getAttribute("fixed");
  +
  +            if (attrEl.hasAttribute("form")) {
  +                String formValue = getEnumString(attrEl, "form");
  +                attr.form = new XmlSchemaForm(formValue);
  +            }
  +            if (attrEl.hasAttribute("id"))
  +                attr.id = attrEl.getAttribute("id");
  +
  +
  +            if (attrEl.hasAttribute("use")) {
  +                String useType = getEnumString(attrEl, "use");
  +                attr.use = new XmlSchemaUse(useType);
  +            }
  +            if (attrEl.hasAttribute("ref")) {
  +                String name = attrEl.getAttribute("ref");
  +                String[] namespaceFromEl = Tokenizer.tokenize(name, ":");
  +                String namespace;
  +
  +                if (namespaceFromEl.length > 1) {
  +                    Object result =
  +                            schema.namespaces.get(namespaceFromEl[0]);
  +                    if (result == null)
  +                        throw new XmlSchemaException("No namespace found in"
  +                                                     + " given ref");
  +                    namespace = result.toString();
  +                } else
  +                    namespace = schema.targetNamespace;
  +
  +                attr.refName = new QualifiedName(name, namespace);
  +                attr.name = name.substring(name.indexOf(":") + 1);
  +            }
  +
  +            Element simpleTypeEl =
  +                    XDOMUtil.getFirstChildElementNS(attrEl,
  +                                                    SCHEMA_NS, "simpleType");
  +
  +            if (simpleTypeEl != null) {
  +                attr.schemaType = handleSimpleType(schema, simpleTypeEl,
  +                                                   schemaEl);
  +            }
  +
  +            Element annotationEl =
  +                    XDOMUtil.getFirstChildElementNS(attrEl,
  +                                                    SCHEMA_NS, "annotation");
  +
  +            if (annotationEl != null) {
  +                XmlSchemaAnnotation annotation =
  +                        handleAnnotation(annotationEl);
  +
  +                attr.setAnnotation(annotation);
  +            }
  +
  +            NamedNodeMap attrNodes = attrEl.getAttributes();
  +            Vector attrs = new Vector();
  +            for (int i = 0; i < attrNodes.getLength(); i++) {
  +                Attr att = (Attr) attrNodes.item(i);
  +                if (!att.getName().equals("name") &&
  +                        !att.getName().equals("type") &&
  +                        !att.getName().equals("default") &&
  +                        !att.getName().equals("fixed") &&
  +                        !att.getName().equals("form") &&
  +                        !att.getName().equals("id") &&
  +                        !att.getName().equals("use") &&
  +                        !att.getName().equals("ref")) {
  +
  +
  +                    attrs.add(att);
  +                    String value = att.getValue();
  +
  +                    if (value.indexOf(":") > -1) {
  +                        // there is a possiblily of some namespace mapping
  +                        String prefix = value.substring(0, value.indexOf(":"));
  +                        //String value = ( String) value.substring( value.indexOf( ":" ) + 1);
  +                        String namespace = (String) schema.namespaces.get(prefix);
  +                        if (namespace != null) {
  +                            Attr nsAttr = attrEl.getOwnerDocument().createAttribute("xmlns:" + prefix);
  +                            nsAttr.setValue(namespace);
  +                            attrs.add(nsAttr);
  +                        }
  +                    }
  +                }
  +            }
  +
  +            if (attrs.size() > 0)
  +                attr.setUnhandledAttributes((Attr[]) attrs.toArray(new Attr[0]));
  +            return attr;
           }	
   
           /********
  @@ -1647,345 +1683,340 @@
           /***********
            * handle_complex_content_restriction
            */
  -        XmlSchemaElement handleElement( XmlSchema schema, Element el, 
  -										Element schemaEl ){
  -            
  -			XmlSchemaElement element = new XmlSchemaElement();
  -                
  -			if(el.getAttributeNode("name") != null)
  -				element.name = el.getAttribute( "name" );
  -                
  -			//                String namespace = (schema.targetNamespace==null)?
  -			//                                      "" : schema.targetNamespace;    
  -                    
  -			element.qualifiedName = new QualifiedName( element.name, 
  -													   schema.targetNamespace);
  +        XmlSchemaElement handleElement(XmlSchema schema, Element el,
  +                                       Element schemaEl) {
   
  -			Element annotationEl = XDOMUtil.getFirstChildElementNS(el, 
  -																   SCHEMA_NS,"annotation");
  +            XmlSchemaElement element = new XmlSchemaElement();
  +
  +            if (el.getAttributeNode("name") != null)
  +                element.name = el.getAttribute("name");
                   
  -			if(annotationEl != null){
  -				XmlSchemaAnnotation annotation = 
  -					handleAnnotation(annotationEl);
  -                    
  -				element.setAnnotation(annotation);
  -			}
  -			if( el.getAttributeNode( "type" ) != null){
  -				String typeName = el.getAttribute( "type" );
  -				String [] args = Tokenizer.tokenize(typeName,":");
  -				String namespace = "";
  -                    
  -				if(args.length > 1){
  -					Object result = schema.namespaces.get(args[0]);
  -					if(result ==null)
  -						throw new XmlSchemaException("No namespace found"
  -													 + " in given base simple content type");
  -                    
  -					namespace = result.toString();
  -				}
  -				else
  -					namespace =  schema.targetNamespace;
  -                    
  +            //                String namespace = (schema.targetNamespace==null)?
  +            //                                      "" : schema.targetNamespace;    
                       
  -				element.schemaTypeName = 
  -					new QualifiedName(typeName, namespace);
  -			}
  -			else if( el.getAttributeNode( "ref") != null ) {
  -				String refName = el.getAttribute( "ref" );
  -                    
  -				String [] args = Tokenizer.tokenize( refName,":");
  -				String namespace; 
  -				if(args.length > 1 ){
  -					Object result = schema.namespaces.get(args[0]);
  -					if(result ==null)
  -						throw new XmlSchemaException("No namespace found in"
  -													 + "given ref");
  -                    
  -					namespace = result.toString();
  -				}
  -				else
  -					namespace = schema.targetNamespace;
  -                    
  -				element.setRefName(new QualifiedName(refName, namespace));
  -				element.name=refName;
  -			}
  -                
  -			Element simpleTypeEl, complexTypeEl, keyEl, keyrefEl, uniqueEl;
  +            element.qualifiedName = new QualifiedName(element.name,
  +                                                      schema.targetNamespace);
   
  -			if( (simpleTypeEl = XDOMUtil.getFirstChildElementNS(el,
  -																SCHEMA_NS,"simpleType"))!= null){
  -                        
  -				XmlSchemaSimpleType simpleType = 
  -					handleSimpleType( schema,simpleTypeEl, schemaEl);
  -				element.schemaType = simpleType;
  +            Element annotationEl = XDOMUtil.getFirstChildElementNS(el,
  +                                                                   SCHEMA_NS, "annotation");
  +
  +            if (annotationEl != null) {
  +                XmlSchemaAnnotation annotation =
  +                        handleAnnotation(annotationEl);
  +
  +                element.setAnnotation(annotation);
  +            }
  +            if (el.getAttributeNode("type") != null) {
  +                String typeName = el.getAttribute("type");
  +                String[] args = Tokenizer.tokenize(typeName, ":");
  +                String namespace = "";
  +
  +                if (args.length > 1) {
  +                    Object result = schema.namespaces.get(args[0]);
  +                    if (result == null)
  +                        throw new XmlSchemaException("No namespace found"
  +                                                     + " in given base simple content type");
  +
  +                    namespace = result.toString();
  +                } else
  +                    namespace = schema.targetNamespace;
  +
  +
  +                element.schemaTypeName =
  +                        new QualifiedName(typeName, namespace);
  +            } else if (el.getAttributeNode("ref") != null) {
  +                String refName = el.getAttribute("ref");
  +
  +                String[] args = Tokenizer.tokenize(refName, ":");
  +                String namespace;
  +                if (args.length > 1) {
  +                    Object result = schema.namespaces.get(args[0]);
  +                    if (result == null)
  +                        throw new XmlSchemaException("No namespace found in"
  +                                                     + "given ref");
  +
  +                    namespace = result.toString();
  +                } else
  +                    namespace = schema.targetNamespace;
  +
  +                element.setRefName(new QualifiedName(refName, namespace));
  +                element.name = refName;
  +            }
  +
  +            Element simpleTypeEl, complexTypeEl, keyEl, keyrefEl, uniqueEl;
  +
  +            if ((simpleTypeEl = XDOMUtil.getFirstChildElementNS(el,
  +                                                                SCHEMA_NS, "simpleType")) != null) {
  +
  +                XmlSchemaSimpleType simpleType =
  +                        handleSimpleType(schema, simpleTypeEl, schemaEl);
  +                element.schemaType = simpleType;
                   element.schemaTypeName = simpleType.qualifiedName;
  -			}
  -			else if((complexTypeEl = 
  -					 XDOMUtil.getFirstChildElementNS(el,SCHEMA_NS,
  -													 "complexType"))!= null) {
  -                                                       
  -				XmlSchemaComplexType complexType = 
  -					handleComplexType( schema, complexTypeEl, schemaEl);
  -                    
  -				element.schemaType = complexType;
  -				element.schemaTypeName = complexType.qualifiedName;
  -			}
  -			else if((keyEl = 
  -					 XDOMUtil.getFirstChildElementNS(el,SCHEMA_NS,"key"))!= null){
  -                    
  -				XmlSchemaIdentityConstraint key = 
  -					handleConstraint(schema, keyEl, schemaEl, "Key");
  -				element.constraints.add(key);
  -			}
  -			else if((keyrefEl = XDOMUtil.getFirstChildElementNS(
  -																el, SCHEMA_NS, "keyref")) != null) {
  -                    
  -				XmlSchemaKeyref keyRef = 
  -					(XmlSchemaKeyref)handleConstraint(schema, keyrefEl, 
  -													  schemaEl, "Keyref");
  -
  -				if(el.hasAttribute("refer")) {
  -					String name = el.getAttribute("refer");
  -					String qName[] = 
  -						Tokenizer.tokenize(name, ":");
  -					String namespace;
  -                        
  -					if(qName.length>1){
  -						Object result = schema.namespaces.get(qName[0]);
  -						namespace = result.toString();
  -					}
  -					else
  -						namespace = schema.targetNamespace;
  -                        
  -					keyRef.refer = new QualifiedName(name, namespace);
  -				}
  +            } else if ((complexTypeEl =
  +                    XDOMUtil.getFirstChildElementNS(el, SCHEMA_NS,
  +                                                    "complexType")) != null) {
  +
  +                XmlSchemaComplexType complexType =
  +                        handleComplexType(schema, complexTypeEl, schemaEl);
  +
  +                element.schemaType = complexType;
  +                element.schemaTypeName = complexType.qualifiedName;
  +            } else if ((keyEl =
  +                    XDOMUtil.getFirstChildElementNS(el, SCHEMA_NS, "key")) != null) {
  +
  +                XmlSchemaIdentityConstraint key =
  +                        handleConstraint(schema, keyEl, schemaEl, "Key");
  +                element.constraints.add(key);
  +            } else if ((keyrefEl = XDOMUtil.getFirstChildElementNS(
  +                    el, SCHEMA_NS, "keyref")) != null) {
  +
  +                XmlSchemaKeyref keyRef =
  +                        (XmlSchemaKeyref) handleConstraint(schema, keyrefEl,
  +                                                           schemaEl, "Keyref");
  +
  +                if (el.hasAttribute("refer")) {
  +                    String name = el.getAttribute("refer");
  +                    String qName[] =
  +                            Tokenizer.tokenize(name, ":");
  +                    String namespace;
  +
  +                    if (qName.length > 1) {
  +                        Object result = schema.namespaces.get(qName[0]);
  +                        namespace = result.toString();
  +                    } else
  +                        namespace = schema.targetNamespace;
   
  -				element.constraints.add(keyRef);
  -                    
  -			} 
  -			else if((uniqueEl = 
  -					 XDOMUtil.getFirstChildElementNS(el,
  -													 SCHEMA_NS,"unique"))!=null){
  -                    
  -				XmlSchemaIdentityConstraint unique = 
  -					handleConstraint(schema,uniqueEl, schemaEl, "Unique");
  -                    
  -				element.constraints.add(unique);
  -			}
  -                
  -			if(el.hasAttribute("abstract"))
  -				element.isAbstract = 
  -					new Boolean(el.getAttribute("abstract")).booleanValue();
  -                
  -			if(el.hasAttribute("block"))
  -				element.block = getDerivation( el, "block");
  +                    keyRef.refer = new QualifiedName(name, namespace);
  +                }
   
  -			if(el.hasAttribute("default"))
  -				element.defaultValue = el.getAttribute("default");
  +                element.constraints.add(keyRef);
   
  -			if(el.hasAttribute("final"))
  -				element.finalDerivation =  getDerivation(el, "final");
  +            } else if ((uniqueEl =
  +                    XDOMUtil.getFirstChildElementNS(el,
  +                                                    SCHEMA_NS, "unique")) != null) {
   
  -			if(el.hasAttribute("fixed"))
  -				element.fixedValue = el.getAttribute("fixed");
  -
  -			if(el.hasAttribute("form")){
  -				String formDef = getEnumString(el,"form");
  -				element.form = new XmlSchemaForm(formDef);
  -			}
  -			if(el.hasAttribute("id"))
  -				element.id = el.getAttribute("id");
  -
  -			if(el.hasAttribute("nillable"))
  -				element.isNillable = 
  -					new Boolean(el.getAttribute("nillable")).booleanValue();
  +                XmlSchemaIdentityConstraint unique =
  +                        handleConstraint(schema, uniqueEl, schemaEl, "Unique");
   
  -                
  -			element.minOccurs = getMinOccurs( el );
  -			element.maxOccurs = getMaxOccurs( el );
  -			return element;
  +                element.constraints.add(unique);
  +            }
  +
  +            if (el.hasAttribute("abstract"))
  +                element.isAbstract =
  +                        new Boolean(el.getAttribute("abstract")).booleanValue();
  +
  +            if (el.hasAttribute("block"))
  +                element.block = getDerivation(el, "block");
  +
  +            if (el.hasAttribute("default"))
  +                element.defaultValue = el.getAttribute("default");
  +
  +            if (el.hasAttribute("final"))
  +                element.finalDerivation = getDerivation(el, "final");
  +
  +            if (el.hasAttribute("fixed"))
  +                element.fixedValue = el.getAttribute("fixed");
  +
  +            if (el.hasAttribute("form")) {
  +                String formDef = getEnumString(el, "form");
  +                element.form = new XmlSchemaForm(formDef);
  +            }
  +            if (el.hasAttribute("id"))
  +                element.id = el.getAttribute("id");
  +
  +            if (el.hasAttribute("nillable"))
  +                element.isNillable =
  +                        new Boolean(el.getAttribute("nillable")).booleanValue();
  +
  +
  +            element.minOccurs = getMinOccurs(el);
  +            element.maxOccurs = getMaxOccurs(el);
  +            return element;
           }
   
  -        private XmlSchemaIdentityConstraint handleConstraint(XmlSchema schema, 
  -															 Element constraintEl, Element schemaEl, String type) {
  -            
  -			try {
  -				XmlSchemaIdentityConstraint constraint = 
  -					(XmlSchemaIdentityConstraint)Class.forName(
  -															   "org.apache.axis.xsd.xml.schema.XmlSchema"+type).newInstance();
  +        private XmlSchemaIdentityConstraint handleConstraint(XmlSchema schema,
  +                                                             Element constraintEl, Element schemaEl, String type) {
   
  -				if(constraintEl.hasAttribute("name"))
  -					constraint.name = constraintEl.getAttribute("name");
  -                    
  -				if(constraintEl.hasAttribute("refer")) {
  -					String name = constraintEl.getAttribute("refer");
  -					String[] namespaceFromEl = 
  -						Tokenizer.tokenize(name, ":");
  -					String namespace;
  -                        
  -					if(namespaceFromEl.length > 1){
  -						Object result = 
  -							schema.namespaces.get(namespaceFromEl[0]);
  -						if(result ==null)
  -							throw new XmlSchemaException("No namespace found in "
  -														 + "given base simple content type");
  -                    
  -						namespace= result.toString();
  -					}else
  -						namespace = schema.targetNamespace;
  -                        
  -					constraint.name=name; // need to confirm as it is not name but refer
  -                        
  -					((XmlSchemaKeyref)constraint).refer = 
  -						new QualifiedName(name , namespace);
  +            try {
  +                XmlSchemaIdentityConstraint constraint =
  +                        (XmlSchemaIdentityConstraint) Class.forName(
  +                                "org.apache.axis.xsd.xml.schema.XmlSchema" + type).newInstance();
  +
  +                if (constraintEl.hasAttribute("name"))
  +                    constraint.name = constraintEl.getAttribute("name");
  +
  +                if (constraintEl.hasAttribute("refer")) {
  +                    String name = constraintEl.getAttribute("refer");
  +                    String[] namespaceFromEl =
  +                            Tokenizer.tokenize(name, ":");
  +                    String namespace;
  +
  +                    if (namespaceFromEl.length > 1) {
  +                        Object result =
  +                                schema.namespaces.get(namespaceFromEl[0]);
  +                        if (result == null)
  +                            throw new XmlSchemaException("No namespace found in "
  +                                                         + "given base simple content type");
  +
  +                        namespace = result.toString();
  +                    } else
  +                        namespace = schema.targetNamespace;
  +
  +                    constraint.name = name; // need to confirm as it is not name but refer
  +
  +                    ((XmlSchemaKeyref) constraint).refer =
  +                            new QualifiedName(name, namespace);
  +
  +                }
  +                for (Element el = XDOMUtil.getFirstChildElementNS(constraintEl,
  +                                                                  SCHEMA_NS);
  +                     el != null;
  +                     el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)) {
  +
  +                    //    String elPrefix = el.getPrefix() == null ? "" 
  +                    //     : el.getPrefix();
  +                    //if(elPrefix.equals(schema.schema_ns_prefix)) {
  +                    if (el.getLocalName().equals("selector")) {
  +                        XmlSchemaXPath selectorXPath =
  +                                new XmlSchemaXPath();
  +                        selectorXPath.xpath = el.getAttribute("xpath");
  +
  +                        Element annotationEl =
  +                                XDOMUtil.getFirstChildElementNS(el, SCHEMA_NS,
  +                                                                "annotation");
  +                        if (annotationEl != null) {
  +                            XmlSchemaAnnotation annotation =
  +                                    handleAnnotation(annotationEl);
  +
  +                            selectorXPath.setAnnotation(annotation);
  +                        }
  +                        constraint.selector = selectorXPath;
  +                    } else if (el.getLocalName().equals("field")) {
  +                        XmlSchemaXPath fieldXPath = new XmlSchemaXPath();
  +                        fieldXPath.xpath = el.getAttribute("xpath");
  +                        constraint.fields.add(fieldXPath);
  +
  +                        Element annotationEl =
  +                                XDOMUtil.getFirstChildElementNS(el, SCHEMA_NS,
  +                                                                "annotation");
  +
  +                        if (annotationEl != null) {
  +                            XmlSchemaAnnotation annotation =
  +                                    handleAnnotation(annotationEl);
  +
  +                            fieldXPath.setAnnotation(annotation);
  +                        }
  +                    } else if (el.getLocalName().equals("annotation")) {
  +                        XmlSchemaAnnotation constraintAnnotation =
  +                                handleAnnotation(el);
  +                        constraint.setAnnotation(constraintAnnotation);
  +                    }
  +                }
  +                return constraint;
  +            } catch (ClassNotFoundException e) {
  +                throw new XmlSchemaException(e.getMessage());
  +            } catch (InstantiationException e) {
  +                throw new XmlSchemaException(e.getMessage());
  +            } catch (IllegalAccessException e) {
  +                throw new XmlSchemaException(e.getMessage());
  +            }
  +        }
  +
  +        XmlSchemaImport handleImport(XmlSchema schema, Element importEl,
  +                                     Element schemaEl) {
   
  -				}
  -				for( Element el=XDOMUtil.getFirstChildElementNS(constraintEl, 
  -																SCHEMA_NS);
  -					 el != null; 
  -					 el = XDOMUtil.getNextSiblingElementNS(el, SCHEMA_NS)){
  -                        
  -					//    String elPrefix = el.getPrefix() == null ? "" 
  -					//     : el.getPrefix();
  -					//if(elPrefix.equals(schema.schema_ns_prefix)) {
  -					if( el.getLocalName().equals( "selector") ) {
  -						XmlSchemaXPath selectorXPath = 
  -							new XmlSchemaXPath();
  -						selectorXPath.xpath = el.getAttribute("xpath");
  -
  -						Element annotationEl = 
  -							XDOMUtil.getFirstChildElementNS(el,SCHEMA_NS,
  -															"annotation");
  -						if(annotationEl != null){
  -							XmlSchemaAnnotation annotation = 
  -								handleAnnotation(annotationEl);
  -                                    
  -							selectorXPath.setAnnotation(annotation);
  -						}
  -						constraint.selector = selectorXPath;
  -					}else if( el.getLocalName().equals( "field") ) {
  -						XmlSchemaXPath fieldXPath = new XmlSchemaXPath();
  -						fieldXPath.xpath = el.getAttribute("xpath");
  -						constraint.fields.add(fieldXPath);
  -
  -						Element annotationEl = 
  -							XDOMUtil.getFirstChildElementNS(el,SCHEMA_NS,
  -															"annotation");
  -                               
  -						if(annotationEl != null){
  -							XmlSchemaAnnotation annotation = 
  -								handleAnnotation(annotationEl);
  -                                   
  -							fieldXPath.setAnnotation(annotation);
  -						}
  -					}else if( el.getLocalName().equals( "annotation")){
  -						XmlSchemaAnnotation constraintAnnotation = 
  -							handleAnnotation(el);
  -						constraint.setAnnotation(constraintAnnotation);
  -					}
  -				}
  -				return constraint;
  -			}
  -			catch(ClassNotFoundException e){
  -				throw new XmlSchemaException(e.getMessage());
  -			}
  -			catch(InstantiationException e){
  -				throw new XmlSchemaException(e.getMessage());
  -			}
  -			catch(IllegalAccessException e){
  -				throw new XmlSchemaException(e.getMessage());
  -			}
  -        }
  -        
  -        XmlSchemaImport handleImport(XmlSchema schema, Element importEl, 
  -                                     Element schemaEl){
  -                                         
               XmlSchemaImport schemaImport = new XmlSchemaImport();
  -    
  -            Element annotationEl = 
  -                XDOMUtil.getFirstChildElementNS(importEl,SCHEMA_NS,"annotation");
  -            
  -            if(annotationEl != null){
  -                XmlSchemaAnnotation importAnnotation = 
  -                    handleAnnotation(annotationEl);
  +
  +            Element annotationEl =
  +                    XDOMUtil.getFirstChildElementNS(importEl, SCHEMA_NS, "annotation");
  +
  +            if (annotationEl != null) {
  +                XmlSchemaAnnotation importAnnotation =
  +                        handleAnnotation(annotationEl);
                   schemaImport.setAnnotation(importAnnotation);
               }
   
  -            schemaImport.namespace = importEl.getAttribute( "namespace");
  -            schemaImport.schemaLocation = 
  -                importEl.getAttribute( "schemaLocation" );
  -            
  -			if ((schemaImport.schemaLocation != null)&&(!schemaImport.schemaLocation.equals("")))
  -				schemaImport.schema = getXmlSchemaFromLocation( 
  -															   schemaImport.schemaLocation);
  +            schemaImport.namespace = importEl.getAttribute("namespace");
  +            schemaImport.schemaLocation =
  +                    importEl.getAttribute("schemaLocation");
  +
  +            if ((schemaImport.schemaLocation != null) && (!schemaImport.schemaLocation.equals("")))
  +                schemaImport.schema = getXmlSchemaFromLocation(
  +                        schemaImport.schemaLocation);
               return schemaImport;
           }
   
  -        XmlSchemaInclude handleInclude( XmlSchema schema, 
  -										Element includeEl, Element schemaEl) {
  -            
  -			XmlSchemaInclude include = new XmlSchemaInclude();
  +        XmlSchemaInclude handleInclude(XmlSchema schema,
  +                                       Element includeEl, Element schemaEl) {
   
  -			Element annotationEl = 
  -				XDOMUtil.getFirstChildElementNS(includeEl, 
  -												SCHEMA_NS,"annotation");
  -                
  -			if(annotationEl != null){
  -				XmlSchemaAnnotation includeAnnotation = 
  -					handleAnnotation(annotationEl);
  -				include.setAnnotation(includeAnnotation);
  -			}
  +            XmlSchemaInclude include = new XmlSchemaInclude();
   
  -			include.schemaLocation = 
  -				includeEl.getAttribute( "schemaLocation" );
  +            Element annotationEl =
  +                    XDOMUtil.getFirstChildElementNS(includeEl,
  +                                                    SCHEMA_NS, "annotation");
  +
  +            if (annotationEl != null) {
  +                XmlSchemaAnnotation includeAnnotation =
  +                        handleAnnotation(annotationEl);
  +                include.setAnnotation(includeAnnotation);
  +            }
   
  +            include.schemaLocation =
  +                    includeEl.getAttribute("schemaLocation");
   
  -			include.schema = 
  -				getXmlSchemaFromLocation( include.schemaLocation);
   
  -			XmlSchemaObjectCollection coll = include.schema.getItems();
  -                
  -			return include;
  +            include.schema =
  +                    getXmlSchemaFromLocation(include.schemaLocation);
  +
  +            XmlSchemaObjectCollection coll = include.schema.getItems();
  +
  +            return include;
           }
   
           /**
            * Traversing if encounter appinfo or documentation 
            * add it to annotation collection
            */
  -        XmlSchemaAnnotation handleAnnotation(Element annotEl){
  +        XmlSchemaAnnotation handleAnnotation(Element annotEl) {
               XmlSchemaObjectCollection content = new XmlSchemaObjectCollection();
               XmlSchemaAppInfo appInfoObj;
               XmlSchemaDocumentation docsObj;                    
   
               for(Element appinfo = XDOMUtil.getFirstChildElementNS(annotEl,
  -																  SCHEMA_NS,"appinfo"); appinfo != null; 
  -                appinfo = XDOMUtil.getNextSiblingElementNS(
  -														   appinfo,SCHEMA_NS,"appinfo")){
  +                                                                  SCHEMA_NS, "appinfo");
  +            appinfo != null;
  +            appinfo = XDOMUtil.getNextSiblingElementNS(
  +                                                       
  +            
  +            appinfo, SCHEMA_NS, "appinfo")){
   
  -                appInfoObj =  handleAppInfo(appinfo);
  +                appInfoObj = handleAppInfo(appinfo);
                   content.add(appInfoObj);
               }
               for(Element documentation = XDOMUtil.getFirstChildElementNS(annotEl,
  -																		SCHEMA_NS,"documentation"); documentation != null; 
  -                documentation = XDOMUtil.getNextSiblingElementNS(documentation,
  -																 SCHEMA_NS,"documentation")){
  -                
  +                                                                        SCHEMA_NS, "documentation");
  +            documentation != null;
  +            documentation = XDOMUtil.getNextSiblingElementNS(documentation,
  +                                                             
  +            
  +            SCHEMA_NS, "documentation")){
  +
                   docsObj = handleDocumentation(documentation);
                   content.add(docsObj);
               }
   
               XmlSchemaAnnotation annotation = new XmlSchemaAnnotation();
               annotation.items = content;
  -            return annotation; 
  +            return annotation;
           }
   
           //create new XmlSchemaAppinfo and add value goten from element
           //to this obj
  -        XmlSchemaAppInfo handleAppInfo(Element content){
  -            XmlSchemaAppInfo appInfo = new XmlSchemaAppInfo(); 
  -            NodeList markup= getChild(content);
  +        XmlSchemaAppInfo handleAppInfo(Element content) {
  +            XmlSchemaAppInfo appInfo = new XmlSchemaAppInfo();
  +            NodeList markup = getChild(content);
   
  -            if(!content.hasAttribute("source") && markup.getLength() <= 0)
  +            if (!content.hasAttribute("source") && markup.getLength() <= 0)
                   return null;
               appInfo.setSource(getAttribute(content, "source"));
               appInfo.setMarkup(markup);
  @@ -1993,113 +2024,112 @@
           }
   
           //iterate each documentation element, create new XmlSchemaAppinfo and add to collection
  -        XmlSchemaDocumentation handleDocumentation(Element content){
  +        XmlSchemaDocumentation handleDocumentation(Element content) {
               XmlSchemaDocumentation documentation = new XmlSchemaDocumentation();
  -            NodeList markup= getChild(content);
  +            NodeList markup = getChild(content);
   
  -            if(!content.hasAttribute("source") && 
  -			   !content.hasAttribute("xml:lang") && markup.getLength()<=0)
  +            if (!content.hasAttribute("source") &&
  +                    !content.hasAttribute("xml:lang") && markup.getLength() <= 0)
                   return null;
   
               documentation.setSource(getAttribute(content, "source"));
  -            documentation.setLanguage(getAttribute(content,"xml:lang"));
  +            documentation.setLanguage(getAttribute(content, "xml:lang"));
               documentation.setMarkup(getChild(content));
   
               return documentation;
           }
   
  -        private String getAttribute(Element content, String attrName){
  -            if(content.hasAttribute(attrName))
  +        private String getAttribute(Element content, String attrName) {
  +            if (content.hasAttribute(attrName))
                   return content.getAttribute(attrName);
               return null;
           }
  -        private NodeList getChild(Element content){
  +
  +        private NodeList getChild(Element content) {
               NodeList childs = content.getChildNodes();
  -            if(childs.getLength()>0)
  +            if (childs.getLength() > 0)
                   return childs;
               return null;
           }
   
  -        long getMinOccurs( Element el ) {
  -            try{
  -                if( el.getAttributeNode( "minOccurs") != null ) {
  -                    String value = el.getAttribute( "minOccurs");
  -                    if( value.equals( "unbounded" ) )
  +        long getMinOccurs(Element el) {
  +            try {
  +                if (el.getAttributeNode("minOccurs") != null) {
  +                    String value = el.getAttribute("minOccurs");
  +                    if (value.equals("unbounded"))
                           return Long.MAX_VALUE;
                       else
                           return new Long(value).longValue();
                   }
                   return 1;
  -            }
  -            catch(java.lang.NumberFormatException  e ){
  +            } catch (java.lang.NumberFormatException e) {
                   return 1;
               }
           }
   
  -        long getMaxOccurs( Element el ) {
  -            try{
  -                if( el.getAttributeNode( "maxOccurs") != null ) {
  -                    String value = el.getAttribute( "maxOccurs");
  -                    if( value.equals( "unbounded" ) )
  +        long getMaxOccurs(Element el) {
  +            try {
  +                if (el.getAttributeNode("maxOccurs") != null) {
  +                    String value = el.getAttribute("maxOccurs");
  +                    if (value.equals("unbounded"))
                           return Long.MAX_VALUE;
                       else
                           return new Long(value).longValue();
                   }
                   return 1;
  -            }
  -            catch(java.lang.NumberFormatException e ){
  +            } catch (java.lang.NumberFormatException e) {
                   return 1;
               }
           }
   
  -        XmlSchemaForm getFormDefault( Element el, String attrName ) {
  -            if( el.getAttributeNode( attrName) != null ) {                         
  -                String value = el.getAttribute( attrName);
  +        XmlSchemaForm getFormDefault(Element el, String attrName) {
  +            if (el.getAttributeNode(attrName) != null) {
  +                String value = el.getAttribute(attrName);
                   char c = Character.toUpperCase(value.charAt(0));
                   return new XmlSchemaForm(c + value.substring(1));
               } else
                   return new XmlSchemaForm("Unqualified");
           }
  -        
  +
           //Check value entered by user and change according to .net spec, 
           //according to w3c spec have to be "#all"
           //but in .net the valid enum value is "all". 
  -        XmlSchemaDerivationMethod getDerivation( Element el, String attrName ) {
  -            if(el.hasAttribute( attrName ) ) {
  +        XmlSchemaDerivationMethod getDerivation(Element el, String attrName) {
  +            if (el.hasAttribute(attrName)) {
                   //#all | List of (extension | restriction | substitution    
                   String derivationMethod = el.getAttribute(attrName).trim();
                   char c = Character.toUpperCase(derivationMethod.charAt(0));
  -                if(derivationMethod.equals("#all"))
  +                if (derivationMethod.equals("#all"))
                       return new XmlSchemaDerivationMethod("All");
  -                else 
  +                else
                       return new XmlSchemaDerivationMethod(
  -														 c+derivationMethod.substring(1));
  +                            c + derivationMethod.substring(1));
               }
  -            return new XmlSchemaDerivationMethod( "None");
  +            return new XmlSchemaDerivationMethod("None");
           }
  -        
  +
           //Check value entered by user and change according to .net spec, user
  -        String getEnumString(Element el, String attrName){
  -            if(el.hasAttribute( attrName ) ) {
  +        String getEnumString(Element el, String attrName) {
  +            if (el.hasAttribute(attrName)) {
                   String contentProcessing = el.getAttribute(attrName).trim();
                   char c = Character.toUpperCase(contentProcessing.charAt(0));
  -                return c+contentProcessing.substring(1);
  +                return c + contentProcessing.substring(1);
               }
               return "None";
           }
   
  -        XmlSchema getXmlSchemaFromLocation( String schemaLocation ){
  +        XmlSchema getXmlSchemaFromLocation(String schemaLocation) {
               try {
                   XmlSchema s = new XmlSchema();
                   java.net.URL u = new java.net.URL(schemaLocation);
  -                java.io.InputStream uStream=u.openConnection().getInputStream();
  -                java.io.InputStreamReader readerS = 
  -                    new java.io.InputStreamReader(uStream);
  -                
  +                java.io.InputStream uStream = u.openConnection().getInputStream();
  +                java.io.InputStreamReader readerS =
  +                        new java.io.InputStreamReader(uStream);
  +
                   s = XmlSchema.read(readerS, null);
                   return s;
  -            }catch( java.io.IOException e){
  -                throw new XmlSchemaException( e.getMessage());
  +            } catch (java.io.IOException e) {
  +                throw new XmlSchemaException(e.getMessage());
               }
           }
       }
  
  
  
  1.2       +59 -4     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAll.java
  
  Index: XmlSchemaAll.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAll.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaAll.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaAll.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaAll.java
    *
    * Created on September 27, 2001, 3:37 AM
  @@ -18,9 +73,9 @@
       /** Creates new XmlSchemaAll */
       public XmlSchemaAll() {
       }
  -	
  -	public XmlSchemaObjectCollection getItems() {
  -		return this.items;
  -	}
  +
  +    public XmlSchemaObjectCollection getItems() {
  +        return this.items;
  +    }
   
   }
  
  
  
  1.2       +92 -36    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAnnotated.java
  
  Index: XmlSchemaAnnotated.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAnnotated.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaAnnotated.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaAnnotated.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,10 +1,66 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaAnnotated.java
    *
    * Created on September 27, 2001, 3:08 AM
    */
   
   package org.apache.axis.xsd.xml.schema;
  +
   import org.w3c.dom.Attr;
   
   /**
  @@ -16,45 +72,45 @@
   // October 15th - momo - initial implementation
   
   public class XmlSchemaAnnotated extends XmlSchemaObject {
  -	/**
  -	 * Defines an annotation. 
  -	 * Creates an annotation element. 
  -	 * Represents the W3C annotation element.
  -	 */
  -	XmlSchemaAnnotation annotation;
  -	String id;
  -	
  -	// Stores qualified attributes that do not belong to the schema target namespace.
  -	public Attr[] unhandledAttributes;
  -	
  -	
  +    /**
  +     * Defines an annotation. 
  +     * Creates an annotation element. 
  +     * Represents the W3C annotation element.
  +     */
  +    XmlSchemaAnnotation annotation;
  +    String id;
  +
  +    // Stores qualified attributes that do not belong to the schema target namespace.
  +    public Attr[] unhandledAttributes;
  +
  +
       /** Creates new XmlSchemaAnnotated */
       public XmlSchemaAnnotated() {
       }
   
  -	public String getId() {
  -		return id;
  -	}
  -	
  -	public void setId(String id) {
  -		this.id = id;
  -	}
  -	
  -	public XmlSchemaAnnotation getAnnotation() {
  -		return annotation;
  -	}
  -	
  -	public void setAnnotation(XmlSchemaAnnotation annotation) {
  -		this.annotation = annotation;
  -	}
  -	
  -	public Attr[] getUnhandledAttributes() {
  -		return unhandledAttributes;
  -	}
  -	
  -	public void setUnhandledAttributes(Attr[] unhandledAttributes) {
  -		this.unhandledAttributes = unhandledAttributes;
  -	}
  -	
  +    public String getId() {
  +        return id;
  +    }
  +
  +    public void setId(String id) {
  +        this.id = id;
  +    }
  +
  +    public XmlSchemaAnnotation getAnnotation() {
  +        return annotation;
  +    }
  +
  +    public void setAnnotation(XmlSchemaAnnotation annotation) {
  +        this.annotation = annotation;
  +    }
  +
  +    public Attr[] getUnhandledAttributes() {
  +        return unhandledAttributes;
  +    }
  +
  +    public void setUnhandledAttributes(Attr[] unhandledAttributes) {
  +        this.unhandledAttributes = unhandledAttributes;
  +    }
  +
   }
   
  
  
  
  1.2       +59 -5     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAnnotation.java
  
  Index: XmlSchemaAnnotation.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAnnotation.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaAnnotation.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaAnnotation.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,12 +1,66 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaAnnotation.java
    *
    * Created on September 27, 2001, 3:40 AM
    */
   
   package org.apache.axis.xsd.xml.schema;
  -import org.w3c.dom.Element;
  -import org.w3c.dom.NodeList;
  +
   
   /**
    * Defines an annotation. Represents the World Wide Web Consortium (W3C)
  @@ -20,13 +74,13 @@
   
   public class XmlSchemaAnnotation extends XmlSchemaObject {
       XmlSchemaObjectCollection items;
  -	
  +
       /** Creates new XmlSchemaAnnotation */
       public XmlSchemaAnnotation() {
           items = new XmlSchemaObjectCollection();
       }
  -	
  +
       public XmlSchemaObjectCollection getItems() {
  -            return items;
  +        return items;
       }
   }
  
  
  
  1.2       +82 -27    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAny.java
  
  Index: XmlSchemaAny.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAny.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaAny.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaAny.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaAny.java
    *
    * Created on September 27, 2001, 3:36 AM
  @@ -18,32 +73,32 @@
   
   public class XmlSchemaAny extends XmlSchemaParticle {
   
  -	/** Creates new XmlSchemaAny */
  -	public XmlSchemaAny() {
  -		processContent = new XmlSchemaContentProcessing("None");
  -	}
  -	
  -	/**
  -	 * Namespaces containing the elements that can be used.
  -	 */
  -	String namespace;
  -	
  -	public String getNamespace() {
  -		return namespace;
  -	}
  -	
  -	public void setNamespace(String namespace) {
  -		this.namespace = namespace;
  -	}
  -	
  -	XmlSchemaContentProcessing processContent;
  -	
  -	public XmlSchemaContentProcessing getProcessContent() {
  -		return processContent;
  -	}
  -	
  -	public void setProcessContent(XmlSchemaContentProcessing processContent) {
  -		this.processContent = processContent;
  -	}
  +    /** Creates new XmlSchemaAny */
  +    public XmlSchemaAny() {
  +        processContent = new XmlSchemaContentProcessing("None");
  +    }
  +
  +    /**
  +     * Namespaces containing the elements that can be used.
  +     */
  +    String namespace;
  +
  +    public String getNamespace() {
  +        return namespace;
  +    }
  +
  +    public void setNamespace(String namespace) {
  +        this.namespace = namespace;
  +    }
  +
  +    XmlSchemaContentProcessing processContent;
  +
  +    public XmlSchemaContentProcessing getProcessContent() {
  +        return processContent;
  +    }
  +
  +    public void setProcessContent(XmlSchemaContentProcessing processContent) {
  +        this.processContent = processContent;
  +    }
   
   }
  
  
  
  1.2       +79 -24    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAnyAttribute.java
  
  Index: XmlSchemaAnyAttribute.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAnyAttribute.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaAnyAttribute.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaAnyAttribute.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaAnyAttribute.java
    *
    * Created on September 27, 2001, 3:09 AM
  @@ -15,28 +70,28 @@
    */
   public class XmlSchemaAnyAttribute extends XmlSchemaAnnotated {
   
  -	/** Creates new XmlSchemaAnyAttribute */
  -	public XmlSchemaAnyAttribute() {
  -		processContent = new XmlSchemaContentProcessing("None");
  -	}
  -
  -	String namespace;
  -	
  -	public String getNamespace() {
  -		return namespace;
  -	}
  -	
  -	public void setNamespace(String namespace) {
  -		this.namespace = namespace;
  -	}
  -	
  -	XmlSchemaContentProcessing processContent;
  -	
  -	public XmlSchemaContentProcessing getProcessContent() {
  -		return processContent;
  -	}
  -	
  -	public void setProcessContent(XmlSchemaContentProcessing processContent) {
  -		this.processContent = processContent;
  -	}
  +    /** Creates new XmlSchemaAnyAttribute */
  +    public XmlSchemaAnyAttribute() {
  +        processContent = new XmlSchemaContentProcessing("None");
  +    }
  +
  +    String namespace;
  +
  +    public String getNamespace() {
  +        return namespace;
  +    }
  +
  +    public void setNamespace(String namespace) {
  +        this.namespace = namespace;
  +    }
  +
  +    XmlSchemaContentProcessing processContent;
  +
  +    public XmlSchemaContentProcessing getProcessContent() {
  +        return processContent;
  +    }
  +
  +    public void setProcessContent(XmlSchemaContentProcessing processContent) {
  +        this.processContent = processContent;
  +    }
   }
  
  
  
  1.2       +81 -26    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAppInfo.java
  
  Index: XmlSchemaAppInfo.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAppInfo.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaAppInfo.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaAppInfo.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaAppInfo.java
    *
    * Created on September 27, 2001, 3:40 AM
  @@ -20,36 +75,36 @@
   
   public class XmlSchemaAppInfo extends XmlSchemaObject {
   
  -	/**
  -	 * Provides the source of the application information.
  -	 */
  -	String source;
  -	
  -	/**
  -	 * Returns an array of XmlNode that represents the document text markup.
  -	 */
  -	NodeList markup;
  -		
  +    /**
  +     * Provides the source of the application information.
  +     */
  +    String source;
  +
  +    /**
  +     * Returns an array of XmlNode that represents the document text markup.
  +     */
  +    NodeList markup;
  +
       /** 
        * Creates new XmlSchemaAppInfo 
        * The default constructor initializes all fields to their default values.
        * */
       public XmlSchemaAppInfo() {
       }
  -	
  -	public String getSource() {
  -		return source;
  -	}
  -	
  -	public void setSource(String source) {
  -		this.source = source;
  -	}
  -	
  -	public NodeList getMarkup() {
  -		return markup;
  -	}
  -	
  -	public void setMarkup(NodeList markup) {
  -		this.markup = markup;
  -	}
  +
  +    public String getSource() {
  +        return source;
  +    }
  +
  +    public void setSource(String source) {
  +        this.source = source;
  +    }
  +
  +    public NodeList getMarkup() {
  +        return markup;
  +    }
  +
  +    public void setMarkup(NodeList markup) {
  +        this.markup = markup;
  +    }
   }
  
  
  
  1.2       +157 -101  xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAttribute.java
  
  Index: XmlSchemaAttribute.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAttribute.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaAttribute.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaAttribute.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,10 +1,66 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaAttribute.java
    *
    * Created on September 27, 2001, 3:09 AM
    */
   
   package org.apache.axis.xsd.xml.schema;
  +
   import org.apache.axis.xsd.xml.QualifiedName;
   
   /**
  @@ -18,106 +74,106 @@
   
   public class XmlSchemaAttribute extends XmlSchemaAnnotated {
   
  -	Object attributeType;
  -	String defaultValue, fixedValue, name;
  -	XmlSchemaForm form;
  -	XmlSchemaSimpleType schemaType;
  -	QualifiedName schemaTypeName, qualifiedName, refName;
  -	XmlSchemaUse use;
  -	
  +    Object attributeType;
  +    String defaultValue, fixedValue, name;
  +    XmlSchemaForm form;
  +    XmlSchemaSimpleType schemaType;
  +    QualifiedName schemaTypeName, qualifiedName, refName;
  +    XmlSchemaUse use;
  +
       /** Creates new XmlSchemaAttribute */
  -	public XmlSchemaAttribute() {
  -		form = new XmlSchemaForm("None");
  -		use= new XmlSchemaUse("None");
  -	}
  -
  -	public Object getAttributeType() {
  -		return attributeType;
  -	}
  -	
  -	public String getDefaultValue() {
  -		return defaultValue;
  -	}
  -	
  -	public void setDefaultValue(String defaultValue) {
  -		this.defaultValue = defaultValue;
  -	}
  -	
  -	public String getFixedValue() {
  -		return fixedValue;
  -	}
  -	
  -	public void setFixedValue(String fixedValue) {
  -		this.fixedValue = fixedValue;
  -	}
  -	
  -	public XmlSchemaForm getForm() {
  -		return form;
  -	}
  -	
  -	public void setSchemaForm(XmlSchemaForm form) {
  -		this.form = form;
  -	}	
  -	
  -	public QualifiedName getQualifiedName() {
  -		return qualifiedName;
  -	}
  -	
  -	public void setQualifiedName(QualifiedName qualifiedName) {
  -		this.qualifiedName = qualifiedName;
  -	}
  -	
  -	public String getName() {
  -		return name;
  -	}
  -	
  -	public void setName(String name) {
  -		this.name = name;
  -	}
  -	
  -	public QualifiedName getRefName() {
  -		return refName;
  -	}
  -	
  -	public void setRefName(QualifiedName refName) {
  -		this.refName = refName;
  -	}
  -	
  -	public XmlSchemaSimpleType getSchemaType() {
  -		return schemaType;
  -	}
  -	
  -	public void setSchemaType(XmlSchemaSimpleType schemaType) {
  -		this.schemaType = schemaType;
  -	}
  -	
  -	public QualifiedName getSchemaTypeName() {
  -		return schemaTypeName;
  -	}
  -	
  -	public void setSchemaTypeName(QualifiedName schemaTypeName) {
  -		this.schemaTypeName = schemaTypeName;
  -	}
  -	
  -	public XmlSchemaUse getUse() {
  -		return use;
  -	}
  -	
  -	public void setUse(XmlSchemaUse use) {
  -		this.use = use;
  -	}
  -	
  -	public String toString(String prefix, int tab) {
  -		String xml = new String();
  -		
  -		if(!prefix.equals("") && prefix.indexOf(":") == -1)
  -			prefix += ":";
  -		
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		xml += "<"+prefix+"attribute name=\""+name+"\" type=\""+schemaTypeName+"\"/>\n";
  -		
  -		return xml;
  -	}
  +    public XmlSchemaAttribute() {
  +        form = new XmlSchemaForm("None");
  +        use = new XmlSchemaUse("None");
  +    }
  +
  +    public Object getAttributeType() {
  +        return attributeType;
  +    }
  +
  +    public String getDefaultValue() {
  +        return defaultValue;
  +    }
  +
  +    public void setDefaultValue(String defaultValue) {
  +        this.defaultValue = defaultValue;
  +    }
  +
  +    public String getFixedValue() {
  +        return fixedValue;
  +    }
  +
  +    public void setFixedValue(String fixedValue) {
  +        this.fixedValue = fixedValue;
  +    }
  +
  +    public XmlSchemaForm getForm() {
  +        return form;
  +    }
  +
  +    public void setSchemaForm(XmlSchemaForm form) {
  +        this.form = form;
  +    }
  +
  +    public QualifiedName getQualifiedName() {
  +        return qualifiedName;
  +    }
  +
  +    public void setQualifiedName(QualifiedName qualifiedName) {
  +        this.qualifiedName = qualifiedName;
  +    }
  +
  +    public String getName() {
  +        return name;
  +    }
  +
  +    public void setName(String name) {
  +        this.name = name;
  +    }
  +
  +    public QualifiedName getRefName() {
  +        return refName;
  +    }
  +
  +    public void setRefName(QualifiedName refName) {
  +        this.refName = refName;
  +    }
  +
  +    public XmlSchemaSimpleType getSchemaType() {
  +        return schemaType;
  +    }
  +
  +    public void setSchemaType(XmlSchemaSimpleType schemaType) {
  +        this.schemaType = schemaType;
  +    }
  +
  +    public QualifiedName getSchemaTypeName() {
  +        return schemaTypeName;
  +    }
  +
  +    public void setSchemaTypeName(QualifiedName schemaTypeName) {
  +        this.schemaTypeName = schemaTypeName;
  +    }
  +
  +    public XmlSchemaUse getUse() {
  +        return use;
  +    }
  +
  +    public void setUse(XmlSchemaUse use) {
  +        this.use = use;
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +
  +        if (!prefix.equals("") && prefix.indexOf(":") == -1)
  +            prefix += ":";
  +
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        xml += "<" + prefix + "attribute name=\"" + name + "\" type=\"" + schemaTypeName + "\"/>\n";
  +
  +        return xml;
  +    }
   }
  
  
  
  1.2       +85 -30    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAttributeGroup.java
  
  Index: XmlSchemaAttributeGroup.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAttributeGroup.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaAttributeGroup.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaAttributeGroup.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaAttributeGroup.java
    *
    * Created on September 27, 2001, 3:09 AM
  @@ -15,40 +70,40 @@
    * @author  mukund
    */
   
  -public class XmlSchemaAttributeGroup extends XmlSchemaAnnotated{
  +public class XmlSchemaAttributeGroup extends XmlSchemaAnnotated {
   
       /** Creates new XmlSchemaAttributeGroup */
       public XmlSchemaAttributeGroup() {
           attributes = new XmlSchemaObjectCollection();
       }
   
  -	XmlSchemaAnyAttribute anyAttribute;
  -	
  -	public XmlSchemaAnyAttribute getAnyAttribute(){
  -		return this.anyAttribute;
  -	}
  -	
  -	public void setAnyAttribute(XmlSchemaAnyAttribute anyAttribute){
  -		this.anyAttribute = anyAttribute;
  -	}
  -	
  -	XmlSchemaObjectCollection attributes;
  -        
  -	public XmlSchemaObjectCollection getAttributes(){
  -		return this.attributes;
  -	}
  -	
  -	public void setAttributes(XmlSchemaObjectCollection attributes){
  -		this.attributes = attributes;
  -	}
  -	
  -	String name;
  -	
  -	public String getName(){
  -		return this.name;
  -	}
  -	
  -	public void setName( String name) {
  -		this.name = name;
  -	}
  +    XmlSchemaAnyAttribute anyAttribute;
  +
  +    public XmlSchemaAnyAttribute getAnyAttribute() {
  +        return this.anyAttribute;
  +    }
  +
  +    public void setAnyAttribute(XmlSchemaAnyAttribute anyAttribute) {
  +        this.anyAttribute = anyAttribute;
  +    }
  +
  +    XmlSchemaObjectCollection attributes;
  +
  +    public XmlSchemaObjectCollection getAttributes() {
  +        return this.attributes;
  +    }
  +
  +    public void setAttributes(XmlSchemaObjectCollection attributes) {
  +        this.attributes = attributes;
  +    }
  +
  +    String name;
  +
  +    public String getName() {
  +        return this.name;
  +    }
  +
  +    public void setName(String name) {
  +        this.name = name;
  +    }
   }
  
  
  
  1.2       +68 -11    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAttributeGroupRef.java
  
  Index: XmlSchemaAttributeGroupRef.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaAttributeGroupRef.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaAttributeGroupRef.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaAttributeGroupRef.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,11 +1,68 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaAttributeGroupRef.java
    *
    * Created on September 27, 2001, 3:10 AM
    */
   
   package org.apache.axis.xsd.xml.schema;
  +
   import org.apache.axis.xsd.xml.QualifiedName;
  +
   /**
    *
    * Class for the attribute group reference. Represents the World Wide
  @@ -19,15 +76,15 @@
       /** Creates new XmlSchemaAttributeGroupRef */
       public XmlSchemaAttributeGroupRef() {
       }
  -	
  -	QualifiedName refName;
  -	
  -	public QualifiedName getRefName(){
  -		return this.refName;
  -	}
  -
  -	public void setRefName(QualifiedName refName) {
  -		this.refName = refName;
  -	}
  -		
  +
  +    QualifiedName refName;
  +
  +    public QualifiedName getRefName() {
  +        return this.refName;
  +    }
  +
  +    public void setRefName(QualifiedName refName) {
  +        this.refName = refName;
  +    }
  +
   }
  
  
  
  1.2       +60 -5     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaChoice.java
  
  Index: XmlSchemaChoice.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaChoice.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaChoice.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaChoice.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaChoice.java
    *
    * Created on September 27, 2001, 3:37 AM
  @@ -12,14 +67,14 @@
    *
    * @author  mukund
    */
  -public class XmlSchemaChoice extends XmlSchemaGroupBase{
  +public class XmlSchemaChoice extends XmlSchemaGroupBase {
   
       /** Creates new XmlSchemaChoice */
       public XmlSchemaChoice() {
       }
  -	
  -	public XmlSchemaObjectCollection getItems() {
  -		return this.items;
  -	}
  +
  +    public XmlSchemaObjectCollection getItems() {
  +        return this.items;
  +    }
   
   }
  
  
  
  1.2       +55 -0     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaCollection.java
  
  Index: XmlSchemaCollection.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaCollection.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaCollection.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaCollection.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaCollection.java
    *
    * Created on September 27, 2001, 3:06 AM
  
  
  
  1.2       +55 -0     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaCollectionEnumerator.java
  
  Index: XmlSchemaCollectionEnumerator.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaCollectionEnumerator.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaCollectionEnumerator.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaCollectionEnumerator.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaCollectionEnumerator.java
    *
    * Created on September 27, 2001, 3:07 AM
  
  
  
  1.2       +95 -40    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaComplexContent.java
  
  Index: XmlSchemaComplexContent.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaComplexContent.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaComplexContent.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaComplexContent.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaComplexContent.java
    *
    * Created on September 27, 2001, 3:19 AM
  @@ -22,48 +77,48 @@
       /** Creates new XmlSchemaComplexContent */
       public XmlSchemaComplexContent() {
       }
  -	
  -	/* One of either the XmlSchemaComplexContentRestriction or 
  +
  +    /* One of either the XmlSchemaComplexContentRestriction or 
   	 * XmlSchemaComplexContentExtension classes.
   	 */
  -	XmlSchemaContent content;
  -	
  -	public XmlSchemaContent getContent() {
  -		return this.content;
  -	}
  -
  -	public void setContent( XmlSchemaContent content) {
  -		this.content = content;
  -	}
  -	
  -	/* Indicates that this type has a mixed content model. Character data
  +    XmlSchemaContent content;
  +
  +    public XmlSchemaContent getContent() {
  +        return this.content;
  +    }
  +
  +    public void setContent(XmlSchemaContent content) {
  +        this.content = content;
  +    }
  +
  +    /* Indicates that this type has a mixed content model. Character data
   	 * is allowed to appear between the child elements of the complex type. 
   	 */
  -	public boolean mixed;
  -	
  -	public boolean isMixed() {
  -		return this.mixed;
  -	}
  -	
  -	public void setMixed(boolean mixed) {
  -		this.mixed = mixed;
  -	}
  -	
  -	public String toString(String prefix, int tab) {
  -		String xml = new String();
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		if(!prefix.equals("") && prefix.indexOf(":") == -1)
  -			prefix += ":";
  -		
  -		xml += "<"+prefix+"complexContent>\n";
  -		
  -		xml += content.toString(prefix, (tab+1));
  -		
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		xml += "<"+prefix+"complexContent>\n";
  -		return xml;
  -	}
  +    public boolean mixed;
  +
  +    public boolean isMixed() {
  +        return this.mixed;
  +    }
  +
  +    public void setMixed(boolean mixed) {
  +        this.mixed = mixed;
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        if (!prefix.equals("") && prefix.indexOf(":") == -1)
  +            prefix += ":";
  +
  +        xml += "<" + prefix + "complexContent>\n";
  +
  +        xml += content.toString(prefix, (tab + 1));
  +
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +        xml += "<" + prefix + "complexContent>\n";
  +        return xml;
  +    }
   }
  
  
  
  1.2       +114 -59   xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaComplexContentExtension.java
  
  Index: XmlSchemaComplexContentExtension.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaComplexContentExtension.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaComplexContentExtension.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaComplexContentExtension.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaComplexContentExtension.java
    *
    * Created on September 27, 2001, 3:11 AM
  @@ -23,65 +78,65 @@
       /** Creates new XmlSchemaComplexContentExtension */
       public XmlSchemaComplexContentExtension() {
           attributes = new XmlSchemaObjectCollection();
  -        
  +
  +    }
  +
  +    /* Allows an XmlSchemaAnyAttribute to be used for the attribute value.*/
  +    XmlSchemaAnyAttribute anyAttribute;
  +
  +    public void setAnyAttribute(XmlSchemaAnyAttribute anyAttribute) {
  +        this.anyAttribute = anyAttribute;
  +    }
  +
  +    public XmlSchemaAnyAttribute getAnyAttribute() {
  +        return this.anyAttribute;
       }
   
  -	/* Allows an XmlSchemaAnyAttribute to be used for the attribute value.*/
  -	XmlSchemaAnyAttribute anyAttribute;
  -	
  -	public void setAnyAttribute( XmlSchemaAnyAttribute anyAttribute ) {
  -		this.anyAttribute = anyAttribute;
  -	}
  -	
  -	public XmlSchemaAnyAttribute getAnyAttribute() {
  -		return this.anyAttribute;
  -	}
  -	
  -	/* Contains XmlSchemaAttribute and XmlSchemaAttributeGroupRef. Collection of attributes for the simple type.*/
  -	XmlSchemaObjectCollection  attributes;
  -	
  -	public XmlSchemaObjectCollection getAttributes() {
  -		return this.attributes;
  -	}
  -
  -	/* Name of the built-in data type, simple type, or complex type.*/
  -	QualifiedName baseTypeName;
  -	
  -	public void setBaseTypeName( QualifiedName  baseTypeName) {
  -		this.baseTypeName = baseTypeName;
  -	}
  -	
  -	public QualifiedName getBaseTypeName() {
  -		return this.baseTypeName;
  -	}
  -	
  -	/*One of the XmlSchemaGroupRef, XmlSchemaChoice, XmlSchemaAll, or XmlSchemaSequence classes.*/
  -	XmlSchemaParticle particle;
  -	
  -	public XmlSchemaParticle getParticle() {
  -		return this.particle;
  -	}
  -	
  -	public void setParticle( XmlSchemaParticle particle ) {
  -		this.particle = particle;
  -	}
  -	
  -	public String toString(String prefix, int tab) {
  -		String xml = new String();
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		if(!prefix.equals("") && prefix.indexOf(":") == -1)
  -			prefix += ":";
  -	
  -		xml += "<"+prefix+"extension>\n";
  -		
  -		if(particle != null)
  -			xml += particle.toString(prefix, (tab+1));
  -		
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		xml += "</"+prefix+"extension>\n";
  -		return xml;
  -	}
  +    /* Contains XmlSchemaAttribute and XmlSchemaAttributeGroupRef. Collection of attributes for the simple type.*/
  +    XmlSchemaObjectCollection attributes;
  +
  +    public XmlSchemaObjectCollection getAttributes() {
  +        return this.attributes;
  +    }
  +
  +    /* Name of the built-in data type, simple type, or complex type.*/
  +    QualifiedName baseTypeName;
  +
  +    public void setBaseTypeName(QualifiedName baseTypeName) {
  +        this.baseTypeName = baseTypeName;
  +    }
  +
  +    public QualifiedName getBaseTypeName() {
  +        return this.baseTypeName;
  +    }
  +
  +    /*One of the XmlSchemaGroupRef, XmlSchemaChoice, XmlSchemaAll, or XmlSchemaSequence classes.*/
  +    XmlSchemaParticle particle;
  +
  +    public XmlSchemaParticle getParticle() {
  +        return this.particle;
  +    }
  +
  +    public void setParticle(XmlSchemaParticle particle) {
  +        this.particle = particle;
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +        if (!prefix.equals("") && prefix.indexOf(":") == -1)
  +            prefix += ":";
  +
  +        xml += "<" + prefix + "extension>\n";
  +
  +        if (particle != null)
  +            xml += particle.toString(prefix, (tab + 1));
  +
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        xml += "</" + prefix + "extension>\n";
  +        return xml;
  +    }
   }
  
  
  
  1.2       +114 -59   xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaComplexContentRestriction.java
  
  Index: XmlSchemaComplexContentRestriction.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaComplexContentRestriction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaComplexContentRestriction.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaComplexContentRestriction.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaComplexContentRestriction.java
    *
    * Created on September 27, 2001, 3:17 AM
  @@ -23,70 +78,70 @@
   
       /** Creates new XmlSchemaComplexContentRestriction */
       public XmlSchemaComplexContentRestriction() {
  -       attributes= new XmlSchemaObjectCollection();
  +        attributes = new XmlSchemaObjectCollection();
  +    }
  +
  +    /* Allows an XmlSchemaAnyAttribute to be used for the attribute value.*/
  +    XmlSchemaAnyAttribute anyAttribute;
  +
  +    public void setAnyAttribute(XmlSchemaAnyAttribute anyAttribute) {
  +        this.anyAttribute = anyAttribute;
  +    }
  +
  +    public XmlSchemaAnyAttribute getAnyAttribute() {
  +        return this.anyAttribute;
       }
   
  -	/* Allows an XmlSchemaAnyAttribute to be used for the attribute value.*/
  -	XmlSchemaAnyAttribute anyAttribute;
  -	
  -	public void setAnyAttribute( XmlSchemaAnyAttribute anyAttribute ) {
  -		this.anyAttribute = anyAttribute;
  -	}
  -	
  -	public XmlSchemaAnyAttribute getAnyAttribute() {
  -		return this.anyAttribute;
  -	}
  -	
  -	/* Contains XmlSchemaAttribute and XmlSchemaAttributeGroupRef. 
  +    /* Contains XmlSchemaAttribute and XmlSchemaAttributeGroupRef. 
   	 *  Collection of attributes for the simple type.
   	 */
  -	XmlSchemaObjectCollection  attributes;
  -	
  -	public XmlSchemaObjectCollection getAttributes() {
  -		return this.attributes;
  -	}
  -
  -	/* Name of the built-in data type, simple type, or complex type.*/
  -	QualifiedName baseTypeName;
  -	
  -	public void setBaseTypeName( QualifiedName  baseTypeName) {
  -		this.baseTypeName = baseTypeName;
  -	}
  -	
  -	public QualifiedName getBaseTypeName() {
  -		return this.baseTypeName;
  -	}
  -	
  -	/*One of the XmlSchemaGroupRef, XmlSchemaChoice, XmlSchemaAll, 
  +    XmlSchemaObjectCollection attributes;
  +
  +    public XmlSchemaObjectCollection getAttributes() {
  +        return this.attributes;
  +    }
  +
  +    /* Name of the built-in data type, simple type, or complex type.*/
  +    QualifiedName baseTypeName;
  +
  +    public void setBaseTypeName(QualifiedName baseTypeName) {
  +        this.baseTypeName = baseTypeName;
  +    }
  +
  +    public QualifiedName getBaseTypeName() {
  +        return this.baseTypeName;
  +    }
  +
  +    /*One of the XmlSchemaGroupRef, XmlSchemaChoice, XmlSchemaAll, 
   	 * or XmlSchemaSequence classes.
   	 */
  -	XmlSchemaParticle particle;
  -	
  -	public XmlSchemaParticle getParticle() {
  -		return this.particle;
  -	}
  -	
  -	public void setParticle( XmlSchemaParticle particle ) {
  -		this.particle = particle;
  -	}
  -	
  -	public String toString(String prefix, int tab) {
  -		String xml = new String();
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		if(!prefix.equals("") && prefix.indexOf(":") == -1)
  -			prefix += ":";
  -	
  -		xml += "<"+prefix+"restriction>\n";
  -		
  -		if(particle != null)
  -			xml += particle.toString(prefix, (tab+1));
  -		
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		xml += "</"+prefix+"restriction>\n";
  -		return xml;
  -	}
  +    XmlSchemaParticle particle;
  +
  +    public XmlSchemaParticle getParticle() {
  +        return this.particle;
  +    }
  +
  +    public void setParticle(XmlSchemaParticle particle) {
  +        this.particle = particle;
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +        if (!prefix.equals("") && prefix.indexOf(":") == -1)
  +            prefix += ":";
  +
  +        xml += "<" + prefix + "restriction>\n";
  +
  +        if (particle != null)
  +            xml += particle.toString(prefix, (tab + 1));
  +
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        xml += "</" + prefix + "restriction>\n";
  +        return xml;
  +    }
   }
   
  
  
  
  1.2       +176 -121  xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaComplexType.java
  
  Index: XmlSchemaComplexType.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaComplexType.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaComplexType.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaComplexType.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaComplexType.java
    *
    * Created on September 27, 2001, 3:40 AM
  @@ -15,126 +70,126 @@
    */
   
   public class XmlSchemaComplexType extends XmlSchemaType {
  -	XmlSchemaAnyAttribute anyAttribute, attributeWildcard;
  -	XmlSchemaObjectCollection attributes;
  -	XmlSchemaObjectTable attributeUses;
  -	XmlSchemaDerivationMethod block, blockResolved;
  -	XmlSchemaContentModel contentModel;
  -	XmlSchemaContentType contentType;
  -	XmlSchemaParticle particleType, particle;
  -	boolean isAbstract, isMixed;
  -	
  +    XmlSchemaAnyAttribute anyAttribute, attributeWildcard;
  +    XmlSchemaObjectCollection attributes;
  +    XmlSchemaObjectTable attributeUses;
  +    XmlSchemaDerivationMethod block, blockResolved;
  +    XmlSchemaContentModel contentModel;
  +    XmlSchemaContentType contentType;
  +    XmlSchemaParticle particleType, particle;
  +    boolean isAbstract, isMixed;
  +
       /** Creates new XmlSchemaComplexType */
  -	public XmlSchemaComplexType() {
  -		attributes = new XmlSchemaObjectCollection();
  -		block=new XmlSchemaDerivationMethod("None");
  -		isAbstract=false;
  -		isMixed=false;
  -	}
  -
  -	public XmlSchemaAnyAttribute getAnyAttribute() {
  -		return anyAttribute;
  -	}
  -	
  -	public void setAnyAttribute(XmlSchemaAnyAttribute anyAttribute) {
  -		this.anyAttribute = anyAttribute;
  -	}
  -	
  -	public  XmlSchemaObjectCollection getAttributes() {
  -		return attributes;
  -	}
  -	
  -	public XmlSchemaObjectTable getAttributeUses() {
  -		return attributeUses;
  -	}
  -	
  -	public XmlSchemaAnyAttribute getAttributeWildcard() {
  -		return attributeWildcard;
  -	}
  -	
  -	public XmlSchemaDerivationMethod getBlock() {
  -		return block;
  -	}
  -	
  -	public void setBlock(XmlSchemaDerivationMethod block) {
  -		this.block = block;
  -	}
  -	
  -	public XmlSchemaDerivationMethod getBlockResolved() {
  -		return blockResolved;
  -	}
  -	
  -	public XmlSchemaContentModel getContentModel() {
  -		return contentModel;
  -	}
  -	
  -	public void setContentModel(XmlSchemaContentModel contentModel) {
  -		this.contentModel = contentModel;
  -	}
  -	
  -	public XmlSchemaContentType  getContentType() {
  -		return contentType;
  -	}
  -	
  -	public void setContentType(XmlSchemaContentType contentType) {
  -		this.contentType = contentType;
  -	}
  -	
  -	public XmlSchemaParticle getContentTypeParticle() {
  -		return particleType;
  -	}
  -	
  -	public boolean isAbstract() {
  -		return isAbstract;
  -	}
  -	
  -	public void setAbstract(boolean b) {
  -		isAbstract = b;
  -	}
  -	
  -	public boolean isMixed() {
  -		return isMixed;
  -	}
  -	
  -	public void setMixed(boolean b) {
  -		isMixed = b;
  -	}
  -	
  -	public XmlSchemaParticle getParticle() {
  -		return particle;
  -	}
  -	
  -	public void setParticle(XmlSchemaParticle particle) {
  -		this.particle = particle;
  -	}
  -	
  -	public String toString(String prefix, int tab) {
  -		String xml = new String();
  -		
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		if(!prefix.equals("") && prefix.indexOf(":") == -1)
  -			prefix += ":";
  -
  -		String typeName = name != null ? name : "";
  -		
  -		xml += "<"+prefix+"complexType name=\""+typeName+"\">\n";
  -		
  -		if(particle != null) 
  -			xml += particle.toString(prefix, (tab+1));
  -		
  -		if(contentModel != null) 
  -			xml += contentModel.toString(prefix, (tab+1));
  -		
  -		for(int i=0;i<attributes.getCount();i++) {
  -			xml += attributes.getItem(i).toString(prefix, (tab+1));
  -		}
  -		
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -				
  -		xml += "</"+prefix+"complexType>\n";
  -		return xml;
  -	}
  +    public XmlSchemaComplexType() {
  +        attributes = new XmlSchemaObjectCollection();
  +        block = new XmlSchemaDerivationMethod("None");
  +        isAbstract = false;
  +        isMixed = false;
  +    }
  +
  +    public XmlSchemaAnyAttribute getAnyAttribute() {
  +        return anyAttribute;
  +    }
  +
  +    public void setAnyAttribute(XmlSchemaAnyAttribute anyAttribute) {
  +        this.anyAttribute = anyAttribute;
  +    }
  +
  +    public XmlSchemaObjectCollection getAttributes() {
  +        return attributes;
  +    }
  +
  +    public XmlSchemaObjectTable getAttributeUses() {
  +        return attributeUses;
  +    }
  +
  +    public XmlSchemaAnyAttribute getAttributeWildcard() {
  +        return attributeWildcard;
  +    }
  +
  +    public XmlSchemaDerivationMethod getBlock() {
  +        return block;
  +    }
  +
  +    public void setBlock(XmlSchemaDerivationMethod block) {
  +        this.block = block;
  +    }
  +
  +    public XmlSchemaDerivationMethod getBlockResolved() {
  +        return blockResolved;
  +    }
  +
  +    public XmlSchemaContentModel getContentModel() {
  +        return contentModel;
  +    }
  +
  +    public void setContentModel(XmlSchemaContentModel contentModel) {
  +        this.contentModel = contentModel;
  +    }
  +
  +    public XmlSchemaContentType getContentType() {
  +        return contentType;
  +    }
  +
  +    public void setContentType(XmlSchemaContentType contentType) {
  +        this.contentType = contentType;
  +    }
  +
  +    public XmlSchemaParticle getContentTypeParticle() {
  +        return particleType;
  +    }
  +
  +    public boolean isAbstract() {
  +        return isAbstract;
  +    }
  +
  +    public void setAbstract(boolean b) {
  +        isAbstract = b;
  +    }
  +
  +    public boolean isMixed() {
  +        return isMixed;
  +    }
  +
  +    public void setMixed(boolean b) {
  +        isMixed = b;
  +    }
  +
  +    public XmlSchemaParticle getParticle() {
  +        return particle;
  +    }
  +
  +    public void setParticle(XmlSchemaParticle particle) {
  +        this.particle = particle;
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        if (!prefix.equals("") && prefix.indexOf(":") == -1)
  +            prefix += ":";
  +
  +        String typeName = name != null ? name : "";
  +
  +        xml += "<" + prefix + "complexType name=\"" + typeName + "\">\n";
  +
  +        if (particle != null)
  +            xml += particle.toString(prefix, (tab + 1));
  +
  +        if (contentModel != null)
  +            xml += contentModel.toString(prefix, (tab + 1));
  +
  +        for (int i = 0; i < attributes.getCount(); i++) {
  +            xml += attributes.getItem(i).toString(prefix, (tab + 1));
  +        }
  +
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        xml += "</" + prefix + "complexType>\n";
  +        return xml;
  +    }
   }
  
  
  
  1.2       +55 -0     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaContent.java
  
  Index: XmlSchemaContent.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaContent.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaContent.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaContent.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaContent.java
    *
    * Created on September 27, 2001, 3:11 AM
  
  
  
  1.2       +59 -4     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaContentModel.java
  
  Index: XmlSchemaContentModel.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaContentModel.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaContentModel.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaContentModel.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaContentModel.java
    *
    * Created on September 27, 2001, 3:18 AM
  @@ -14,13 +69,13 @@
   
   // Vidyanand - 16th Oct - initial implementation
   
  -public abstract class XmlSchemaContentModel extends XmlSchemaAnnotated{
  +public abstract class XmlSchemaContentModel extends XmlSchemaAnnotated {
   
       /** Creates new XmlSchemaContentModel */
       protected XmlSchemaContentModel() {
       }
   
  -	public abstract void setContent(XmlSchemaContent content);
  -	
  -	public abstract XmlSchemaContent getContent();
  +    public abstract void setContent(XmlSchemaContent content);
  +
  +    public abstract XmlSchemaContent getContent();
   }
  
  
  
  1.2       +68 -13    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaContentProcessing.java
  
  Index: XmlSchemaContentProcessing.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaContentProcessing.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaContentProcessing.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaContentProcessing.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaContentProcessing.java
    *
    * Created on September 27, 2001, 3:04 AM
  @@ -17,20 +72,20 @@
   
   public class XmlSchemaContentProcessing extends Enum {
   
  -	static String[] members = new String[] { "Lax", "None",
  -											 "Skip", "Strict"};
  -	
  +    static String[] members = new String[]{"Lax", "None",
  +                                           "Skip", "Strict"};
  +
       /** Creates new XmlSeverityType */
       public XmlSchemaContentProcessing() {
  -		super();
  -	}
  -	
  -	public XmlSchemaContentProcessing(String value) {
  -		super(value);
  -	}
  -	
  -	public String[] getValues() {
  -		return members;
  -	}
  +        super();
  +    }
  +
  +    public XmlSchemaContentProcessing(String value) {
  +        super(value);
  +    }
  +
  +    public String[] getValues() {
  +        return members;
  +    }
   
   }
  
  
  
  1.2       +66 -11    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaContentType.java
  
  Index: XmlSchemaContentType.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaContentType.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaContentType.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaContentType.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaContentType.java
    *
    * Created on September 27, 2001, 3:04 AM
  @@ -17,19 +72,19 @@
   
   public class XmlSchemaContentType extends Enum {
   
  -	static String[] members = new String[] { "ElementOnly", "Empty", 
  -											 "Mixed", "TextOnly"};
  -		
  +    static String[] members = new String[]{"ElementOnly", "Empty",
  +                                           "Mixed", "TextOnly"};
  +
       /** Creates new XmlSchemaContentType */
       public XmlSchemaContentType() {
  -		super();
  +        super();
  +    }
  +
  +    public XmlSchemaContentType(String value) {
  +        super(value);
       }
   
  -	public XmlSchemaContentType(String value) {
  -		super(value); 
  -	}
  -	
  -	public String[] getValues() {
  -		return members;
  -	}
  +    public String[] getValues() {
  +        return members;
  +    }
   }
  
  
  
  1.2       +62 -4     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaDatatype.java
  
  Index: XmlSchemaDatatype.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaDatatype.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaDatatype.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaDatatype.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,10 +1,66 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaDatatype.java
    *
    * Created on September 27, 2001, 3:07 AM
    */
   
   package org.apache.axis.xsd.xml.schema;
  +
   import org.apache.axis.xsd.xml.XmlTokenizedType;
   
   /**
  @@ -17,9 +73,11 @@
       /** Creates new XmlSchemaDatatype */
       public XmlSchemaDatatype() {
       }
  -	
  -	public abstract Object parseValue(Object input);
  -	public abstract Class valueType();
  -	public abstract XmlTokenizedType tokenizedType();
  +
  +    public abstract Object parseValue(Object input);
  +
  +    public abstract Class valueType();
  +
  +    public abstract XmlTokenizedType tokenizedType();
   
   }
  
  
  
  1.2       +69 -14    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaDerivationMethod.java
  
  Index: XmlSchemaDerivationMethod.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaDerivationMethod.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaDerivationMethod.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaDerivationMethod.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaDerivationMethod.java
    *
    * Created on September 27, 2001, 3:04 AM
  @@ -15,22 +70,22 @@
    */
   
   public class XmlSchemaDerivationMethod extends Enum {
  -	static String[] members = new String[] { "All", "Empty", "Extension", 
  -											 "List", "None", "Restriction", 
  -											 "Substitution", "Union"};
  -	
  +    static String[] members = new String[]{"All", "Empty", "Extension",
  +                                           "List", "None", "Restriction",
  +                                           "Substitution", "Union"};
  +
       /** Creates new XmlSeverityType */
       public XmlSchemaDerivationMethod() {
  -		super();
  -	}
  -	
  -	public XmlSchemaDerivationMethod(String value) {
  -		super(value);
  -	}
  -	
  -	public String[] getValues() {
  -		return members;
  -	}
  +        super();
  +    }
  +
  +    public XmlSchemaDerivationMethod(String value) {
  +        super(value);
  +    }
  +
  +    public String[] getValues() {
  +        return members;
  +    }
   
   
   }
  
  
  
  1.2       +91 -35    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaDocumentation.java
  
  Index: XmlSchemaDocumentation.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaDocumentation.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaDocumentation.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaDocumentation.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,10 +1,66 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaDocumentation.java
    *
    * Created on September 27, 2001, 3:41 AM
    */
   
   package org.apache.axis.xsd.xml.schema;
  +
   import org.w3c.dom.NodeList;
   
   /**
  @@ -20,40 +76,40 @@
       /** Creates new XmlSchemaDocumentation */
       public XmlSchemaDocumentation() {
       }
  -	
  -	/**
  -	 * Provides the source of the application information.
  -	 */
  -	String source;
  -	String language;
  -	
  -	/**
  -	 * Returns an array of XmlNode that represents the document text markup.
  -	 */
  -	NodeList markup;
  -	
  -	public String getSource() {
  -		return source;
  -	}
  -	
  -	public void setSource(String source) {
  -		this.source = source;
  -	}
  -	
  -	public NodeList getMarkup() {
  -		return markup;
  -	}
  -	
  -	public void setMarkup(NodeList markup) {
  -		this.markup = markup;
  -	}
  -	
  -	public String getLanguage() {
  -		return language;
  -	}
  -	
  -	public void setLanguage(String language) {
  -		this.language = language;
  -	}
  +
  +    /**
  +     * Provides the source of the application information.
  +     */
  +    String source;
  +    String language;
  +
  +    /**
  +     * Returns an array of XmlNode that represents the document text markup.
  +     */
  +    NodeList markup;
  +
  +    public String getSource() {
  +        return source;
  +    }
  +
  +    public void setSource(String source) {
  +        this.source = source;
  +    }
  +
  +    public NodeList getMarkup() {
  +        return markup;
  +    }
  +
  +    public void setMarkup(NodeList markup) {
  +        this.markup = markup;
  +    }
  +
  +    public String getLanguage() {
  +        return language;
  +    }
  +
  +    public void setLanguage(String language) {
  +        this.language = language;
  +    }
   
   }
  
  
  
  1.2       +282 -226  xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaElement.java
  
  Index: XmlSchemaElement.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaElement.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaElement.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaElement.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaElement.java
    *
    * Created on September 27, 2001, 3:36 AM
  @@ -15,232 +70,233 @@
    */
   
   // October 15th - momo - initial implementation
  -public class XmlSchemaElement extends XmlSchemaParticle  {
   
  -	/**
  -	 * Attribute used to block a type derivation.
  -	 */
  -	XmlSchemaDerivationMethod block;
  -	
  -	/**
  -	 * The value after an element has been compiled to post-schema infoset. 
  -	 * This value is either from the type itself or, if not defined on the type, taken from the schema element.
  -	 */
  -	XmlSchemaDerivationMethod blockResolved;
  -	XmlSchemaObjectCollection constraints;
  -	
  -	/**
  -	 * Provides the default value of the element if its content 
  -	 * is a simple type or the element's content is textOnly.
  -	 */
  -	String defaultValue;
  -	String fixedValue;
  -	
  -	/**
  -	 * Returns the correct common runtime library 
  -	 * object based upon the SchemaType for the element.
  -	 */
  -	Object elementType;
  -
  -	XmlSchemaDerivationMethod finalDerivation;
  -	XmlSchemaDerivationMethod finalDerivationResolved;
  -	
  -	/**
  -	 * The default value is the value of the elementFormDefault attribute for the schema element containing the attribute. 
  -	 * The default is Unqualified.
  -	 */
  -	XmlSchemaForm form; 
  -	boolean isAbstract;
  -	boolean isNillable;
  -	String name;
  -	QualifiedName qualifiedName;
  -	QualifiedName refName;
  -	
  -	/**
  -	 * Returns the type of the element. 
  -	 * This can either be a complex type or a simple type.
  -	 */
  -	XmlSchemaType schemaType;
  -	
  -	/**
  -	 * QualifiedName of a built-in data type defined in this schema or another 
  -	 * schema indicated by the specified namespace.
  -	 */
  -	QualifiedName schemaTypeName;
  -	
  -	/**
  -	 * QualifiedName of an element that can be a substitute for this element.
  -	 */
  -	QualifiedName substitutionGroup;
  -	
  -	/** Creates new XmlSchemaElement */
  -        public XmlSchemaElement() {
  -               constraints = new XmlSchemaObjectCollection();
  -               isAbstract = false;
  -               isNillable = false;
  -               form = new XmlSchemaForm("None");
  -               finalDerivation = new XmlSchemaDerivationMethod("None");
  -               block = new XmlSchemaDerivationMethod("None");
  +public class XmlSchemaElement extends XmlSchemaParticle {
  +
  +    /**
  +     * Attribute used to block a type derivation.
  +     */
  +    XmlSchemaDerivationMethod block;
  +
  +    /**
  +     * The value after an element has been compiled to post-schema infoset. 
  +     * This value is either from the type itself or, if not defined on the type, taken from the schema element.
  +     */
  +    XmlSchemaDerivationMethod blockResolved;
  +    XmlSchemaObjectCollection constraints;
  +
  +    /**
  +     * Provides the default value of the element if its content 
  +     * is a simple type or the element's content is textOnly.
  +     */
  +    String defaultValue;
  +    String fixedValue;
  +
  +    /**
  +     * Returns the correct common runtime library 
  +     * object based upon the SchemaType for the element.
  +     */
  +    Object elementType;
  +
  +    XmlSchemaDerivationMethod finalDerivation;
  +    XmlSchemaDerivationMethod finalDerivationResolved;
  +
  +    /**
  +     * The default value is the value of the elementFormDefault attribute for the schema element containing the attribute. 
  +     * The default is Unqualified.
  +     */
  +    XmlSchemaForm form;
  +    boolean isAbstract;
  +    boolean isNillable;
  +    String name;
  +    QualifiedName qualifiedName;
  +    QualifiedName refName;
  +
  +    /**
  +     * Returns the type of the element. 
  +     * This can either be a complex type or a simple type.
  +     */
  +    XmlSchemaType schemaType;
  +
  +    /**
  +     * QualifiedName of a built-in data type defined in this schema or another 
  +     * schema indicated by the specified namespace.
  +     */
  +    QualifiedName schemaTypeName;
  +
  +    /**
  +     * QualifiedName of an element that can be a substitute for this element.
  +     */
  +    QualifiedName substitutionGroup;
  +
  +    /** Creates new XmlSchemaElement */
  +    public XmlSchemaElement() {
  +        constraints = new XmlSchemaObjectCollection();
  +        isAbstract = false;
  +        isNillable = false;
  +        form = new XmlSchemaForm("None");
  +        finalDerivation = new XmlSchemaDerivationMethod("None");
  +        block = new XmlSchemaDerivationMethod("None");
  +    }
  +
  +    /**
  +     * Returns a collection of constraints on the element.
  +     */
  +    public XmlSchemaObjectCollection getConstraints() {
  +        return constraints;
  +    }
  +
  +    public String getDefaultValue() {
  +        return defaultValue;
  +    }
  +
  +    public void setDefaultValue(String defaultValue) {
  +        this.defaultValue = defaultValue;
  +    }
  +
  +    public XmlSchemaDerivationMethod getBlock() {
  +        return block;
  +    }
  +
  +    public void setBlock(XmlSchemaDerivationMethod block) {
  +        this.block = block;
  +    }
  +
  +    public XmlSchemaDerivationMethod getFinal() {
  +        return finalDerivation;
  +    }
  +
  +    public void setFinal(XmlSchemaDerivationMethod finalDerivation) {
  +        this.finalDerivation = finalDerivation;
  +    }
  +
  +    public XmlSchemaDerivationMethod getBlockResolved() {
  +        return blockResolved;
  +    }
  +
  +    public String getFixedValue() {
  +        return fixedValue;
  +    }
  +
  +    public void setFixedValue(String fixedValue) {
  +        this.fixedValue = fixedValue;
  +    }
  +
  +    public Object getElementType() {
  +        return elementType;
  +    }
  +
  +    public XmlSchemaForm getForm() {
  +        return form;
  +    }
  +
  +    public void setForm(XmlSchemaForm form) {
  +        this.form = form;
  +    }
  +
  +    public boolean isAbstract() {
  +        return isAbstract;
  +    }
  +
  +    public void setAbstract(boolean isAbstract) {
  +        this.isAbstract = isAbstract;
  +    }
  +
  +    public boolean isNillable() {
  +        return isNillable;
  +    }
  +
  +    public void setNillable(boolean isNillable) {
  +        this.isNillable = isNillable;
  +    }
  +
  +    public String getName() {
  +        return name;
  +    }
  +
  +    public void setName(String name) {
  +        this.name = name;
  +    }
  +
  +    public QualifiedName getRefName() {
  +        return refName;
  +    }
  +
  +    public void setRefName(QualifiedName refName) {
  +        this.refName = refName;
  +    }
  +
  +    public QualifiedName getQualifiedName() {
  +        return qualifiedName;
  +    }
  +
  +    public void setQualifiedName(QualifiedName qualifiedName) {
  +        this.qualifiedName = qualifiedName;
  +    }
  +
  +    public XmlSchemaType getSchemaType() {
  +        return schemaType;
  +    }
  +
  +    public void setSchemaType(XmlSchemaType schemaType) {
  +        this.schemaType = schemaType;
  +    }
  +
  +    public QualifiedName getSchemaTypeName() {
  +        return schemaTypeName;
  +    }
  +
  +    public void setSchemaTypeName(QualifiedName schemaTypeName) {
  +        this.schemaTypeName = schemaTypeName;
  +    }
  +
  +    public QualifiedName getSubstitutionGroup() {
  +        return substitutionGroup;
  +    }
  +
  +    public void setSubstitutionGroup(QualifiedName substitutionGroup) {
  +        this.substitutionGroup = substitutionGroup;
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +
  +        if (!prefix.equals("") && prefix.indexOf(":") == -1)
  +            prefix += ":";
  +
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        xml += "<" + prefix + "element ";
  +
  +        if (!name.equals(""))
  +            xml += "name=\"" + name + "\" ";
  +
  +        if (schemaTypeName != null)
  +            xml += "type=\"" + schemaTypeName + "\"";
  +
  +        if (refName != null)
  +            xml += "ref=\"" + refName + "\" ";
  +
  +        if (minOccurs != 1)
  +            xml += "minOccurs=\"" + minOccurs + "\" ";
  +
  +        if (maxOccurs != 1)
  +            xml += "maxOccurs=\"" + maxOccurs + "\" ";
  +
  +        xml += ">\n";
  +
  +        if (constraints != null)
  +            xml += constraints.toString(prefix, (tab + 1));
  +
  +        if (schemaType != null) {
  +            xml += schemaType.toString(prefix, (tab + 1));
           }
  -	
  -	/**
  -	 * Returns a collection of constraints on the element.
  -	 */
  -	public XmlSchemaObjectCollection getConstraints() {
  -		return constraints;
  -	}
  -	
  -	public String getDefaultValue() {
  -		return defaultValue;
  -	}
  -	
  -	public void setDefaultValue(String defaultValue) {
  -		this.defaultValue = defaultValue;
  -	}
  -	
  -	public XmlSchemaDerivationMethod getBlock() {
  -		return block;
  -	}
  -	
  -	public void setBlock(XmlSchemaDerivationMethod block) {
  -		this.block = block;
  -	}
  -	
  -	public XmlSchemaDerivationMethod getFinal() {
  -		return finalDerivation;
  -	}
  -	
  -	public void setFinal(XmlSchemaDerivationMethod finalDerivation) {
  -		this.finalDerivation = finalDerivation;
  -	}
  -	
  -	public XmlSchemaDerivationMethod getBlockResolved() {
  -		return blockResolved;
  -	}
  -	
  -	public String getFixedValue() {
  -		return fixedValue;
  -	}
  -	
  -	public void setFixedValue(String fixedValue) {
  -		this.fixedValue = fixedValue;
  -	}
  -	
  -	public Object getElementType() {
  -		return elementType;
  -	}
  -	
  -	public XmlSchemaForm getForm() {
  -		return form;
  -	}
  -	
  -	public void setForm(XmlSchemaForm form) {
  -		this.form = form;
  -	}
  -	
  -	public boolean isAbstract() {
  -		return isAbstract;
  -	}
  -	
  -	public void setAbstract(boolean isAbstract) {
  -		this.isAbstract = isAbstract;
  -	}
  -	
  -	public boolean isNillable() {
  -		return isNillable;
  -	}
  -	
  -	public void setNillable(boolean isNillable) {
  -		this.isNillable = isNillable;
  -	}
  -	
  -	public String getName() {
  -		return name;
  -	}
  -	
  -	public void setName(String name) {
  -		this.name = name;
  -	}
  -	
  -	public QualifiedName getRefName() {
  -		return refName;
  -	}
  -	
  -	public void setRefName(QualifiedName refName) {
  -		this.refName = refName;
  -	}
  -	
  -	public QualifiedName getQualifiedName() {
  -		return qualifiedName;
  -	}
  -	
  -	public void setQualifiedName(QualifiedName qualifiedName) {
  -		this.qualifiedName = qualifiedName;
  -	}
  -	
  -	public XmlSchemaType getSchemaType() {
  -		return schemaType;
  -	}
  -	
  -	public void setSchemaType(XmlSchemaType schemaType) {
  -		this.schemaType = schemaType;
  -	}
  -	
  -	public QualifiedName getSchemaTypeName() {
  -		return schemaTypeName;
  -	}
  -	
  -	public void setSchemaTypeName(QualifiedName schemaTypeName) {
  -		this.schemaTypeName = schemaTypeName;
  -	}
  -	
  -	public QualifiedName getSubstitutionGroup() {
  -		return substitutionGroup;
  -	}
  -	
  -	public void setSubstitutionGroup(QualifiedName substitutionGroup) {
  -		this.substitutionGroup = substitutionGroup;
  -	}
  -	
  -	public String toString(String prefix, int tab) {
  -		String xml = new String();
  -		
  -		if(!prefix.equals("") && prefix.indexOf(":") == -1)
  -			prefix += ":";
  -		
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		xml += "<"+prefix+"element ";
  -		
  -		if(!name.equals("")) 
  -			xml += "name=\""+name+"\" ";
  -		
  -		if(schemaTypeName != null) 
  -			xml +="type=\""+schemaTypeName+"\"";
  -		
  -		if(refName != null)
  -			xml += "ref=\"" + refName + "\" ";
  -		
  -		if(minOccurs != 1)
  -			xml +=  "minOccurs=\""+minOccurs+"\" "; 
  -		
  -		if(maxOccurs != 1)
  -			xml += "maxOccurs=\""+maxOccurs+"\" ";
  -			   
  -		xml += ">\n";
  -		
  -		if(constraints != null)
  -			xml += constraints.toString(prefix, (tab+1));
  -	
  -		if(schemaType != null) {
  -			xml += schemaType.toString(prefix, (tab + 1));
  -		} 
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		xml += "</"+prefix+"element>\n";
  -		
  -		return xml;
  -	}
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        xml += "</" + prefix + "element>\n";
  +
  +        return xml;
  +    }
   }
  
  
  
  1.2       +58 -3     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaEnumerationFacet.java
  
  Index: XmlSchemaEnumerationFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaEnumerationFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaEnumerationFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaEnumerationFacet.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaEnumerationFacet.java
    *
    * Created on September 27, 2001, 3:21 AM
  @@ -21,7 +76,7 @@
       public XmlSchemaEnumerationFacet() {
       }
   
  -	public XmlSchemaEnumerationFacet( Object value, boolean fixed ) {
  -		super( value, fixed );
  -	}
  +    public XmlSchemaEnumerationFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   }
  
  
  
  1.2       +68 -12    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaException.java
  
  Index: XmlSchemaException.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaException.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaException.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaException.java
    *
    * Created on September 27, 2001, 3:00 AM
  @@ -18,24 +73,25 @@
       /** Creates new XmlSchemaException */
       public XmlSchemaException() {
       }
  -    
  -	public XmlSchemaException(String message) {
  -		super(message);
  -	}
  -	// TODO :implement
  +
  +    public XmlSchemaException(String message) {
  +        super(message);
  +    }
  +
  +    // TODO :implement
       public int getLineNumer() {
  -		return 1;
  +        return 1;
       }
  -    
  +
       public int getLinePosition() {
  -		return 1;
  +        return 1;
       }
  -    
  +
       public XmlSchemaObject getSourceSchemaObject() {
  -		return null;
  +        return null;
       }
  -    
  +
       public String getSourceUri() {
  -		return null;
  +        return null;
       }
   }
  
  
  
  1.2       +74 -19    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaExternal.java
  
  Index: XmlSchemaExternal.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaExternal.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaExternal.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaExternal.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaExternal.java
    *
    * Created on September 27, 2001, 3:19 AM
  @@ -18,24 +73,24 @@
       protected XmlSchemaExternal() {
       }
   
  -	XmlSchema schema;
  -	
  -	public XmlSchema getSchema() {
  -		return schema;
  -	}
  -	
  -	public void setSchema(XmlSchema schema) {
  -		this.schema = schema;
  -	}
  -	
  -	String schemaLocation;
  -	
  -	public String getSchemaLocation() {
  -		return schemaLocation;
  -	}
  -	
  -	public void setSchemaLocation(String schemaLocation) {
  -		this.schemaLocation = schemaLocation;
  -	}
  +    XmlSchema schema;
  +
  +    public XmlSchema getSchema() {
  +        return schema;
  +    }
  +
  +    public void setSchema(XmlSchema schema) {
  +        this.schema = schema;
  +    }
  +
  +    String schemaLocation;
  +
  +    public String getSchemaLocation() {
  +        return schemaLocation;
  +    }
  +
  +    public void setSchemaLocation(String schemaLocation) {
  +        this.schemaLocation = schemaLocation;
  +    }
   }
   
  
  
  
  1.2       +109 -53   xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaFacet.java
  
  Index: XmlSchemaFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaFacet.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaFacet.java
    *
    * Created on September 27, 2001, 3:21 AM
  @@ -7,6 +62,7 @@
   package org.apache.axis.xsd.xml.schema;
   
   import org.w3c.dom.Element;
  +
   /**
    * Abstract class for all facets that are used when simple types are 
    * derived by restriction.
  @@ -21,59 +77,59 @@
   public abstract class XmlSchemaFacet extends XmlSchemaAnnotated {
   
       /** Creates new XmlSchemaFacet */
  -	
  -	
  +
  +
       protected XmlSchemaFacet() {
       }
  -	
  -	protected XmlSchemaFacet( Object value, boolean fixed ) {
  -		this.value = value;
  -		this.fixed = fixed;
  -	}
  -	
  -	boolean fixed;
  -	
  -	Object value;
  -	
  -	public boolean isFixed() {
  -		return fixed;
  -	}
  -	
  -	public void setFixed(boolean fixed) {
  -		this.fixed = fixed;
  -	}	
  -	
  -	public Object getValue() {
  -		return value;
  -	}
  -
  -	public void setValue(Object value) {
  -		this.value = value;
  -	}
  -	
  -	public static XmlSchemaFacet construct( Element el ) {
  -		String name = el.getLocalName();
  -		boolean fixed = false;
  -		if( el.getAttribute( "fixed" ).equals( "true" ) ) {
  -			fixed = true;
  -		}
  -		try {
  -			// TODO : move this from reflection to a if condition and avoid cost 
  -			// of reflection
  -			Class facetClass = Class.forName("org.apache.axis.xsd.xml.schema.XmlSchema" 
  -											 + Character.toUpperCase(name.charAt(0)) 
  -											 + name.substring(1) + "Facet");
  -			XmlSchemaFacet facet = (XmlSchemaFacet) facetClass.newInstance();
  -			facet.setFixed( fixed );
  -			facet.setValue( el.getAttribute( "value" ));
  -			return facet;		
  -		} catch (ClassNotFoundException e) {
  -			throw new XmlSchemaException(e.getMessage());
  -		} catch (InstantiationException e) {
  -			throw new XmlSchemaException(e.getMessage());
  -		} catch (IllegalAccessException e) {
  -			throw new XmlSchemaException(e.getMessage());
  -		}
  -			
  -	}
  +
  +    protected XmlSchemaFacet(Object value, boolean fixed) {
  +        this.value = value;
  +        this.fixed = fixed;
  +    }
  +
  +    boolean fixed;
  +
  +    Object value;
  +
  +    public boolean isFixed() {
  +        return fixed;
  +    }
  +
  +    public void setFixed(boolean fixed) {
  +        this.fixed = fixed;
  +    }
  +
  +    public Object getValue() {
  +        return value;
  +    }
  +
  +    public void setValue(Object value) {
  +        this.value = value;
  +    }
  +
  +    public static XmlSchemaFacet construct(Element el) {
  +        String name = el.getLocalName();
  +        boolean fixed = false;
  +        if (el.getAttribute("fixed").equals("true")) {
  +            fixed = true;
  +        }
  +        try {
  +            // TODO : move this from reflection to a if condition and avoid cost 
  +            // of reflection
  +            Class facetClass = Class.forName("org.apache.axis.xsd.xml.schema.XmlSchema"
  +                                             + Character.toUpperCase(name.charAt(0))
  +                                             + name.substring(1) + "Facet");
  +            XmlSchemaFacet facet = (XmlSchemaFacet) facetClass.newInstance();
  +            facet.setFixed(fixed);
  +            facet.setValue(el.getAttribute("value"));
  +            return facet;
  +        } catch (ClassNotFoundException e) {
  +            throw new XmlSchemaException(e.getMessage());
  +        } catch (InstantiationException e) {
  +            throw new XmlSchemaException(e.getMessage());
  +        } catch (IllegalAccessException e) {
  +            throw new XmlSchemaException(e.getMessage());
  +        }
  +
  +    }
   }
  
  
  
  1.2       +66 -11    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaForm.java
  
  Index: XmlSchemaForm.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaForm.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaForm.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaForm.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaForm.java
    *
    * Created on September 27, 2001, 3:05 AM
  @@ -20,19 +75,19 @@
   
   public class XmlSchemaForm extends Enum {
   
  -	static String[] members = new String[] { "None", "Qualified", "Unqualified"};
  -		
  +    static String[] members = new String[]{"None", "Qualified", "Unqualified"};
  +
       /** Creates new XmlSchemaForm */
       public XmlSchemaForm() {
  -		super();
  +        super();
  +    }
  +
  +    public XmlSchemaForm(String value) {
  +        super(value);
  +    }
  +
  +    public String[] getValues() {
  +        return members;
       }
  -	
  -	public XmlSchemaForm(String value) {
  -		super(value);
  -	}
  -	
  -	public String[] getValues() {
  -		return members;
  -	}
   
   }
  
  
  
  1.2       +59 -4     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaFractionDigitsFacet.java
  
  Index: XmlSchemaFractionDigitsFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaFractionDigitsFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaFractionDigitsFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaFractionDigitsFacet.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaFractionDigitsFacet.java
    *
    * Created on September 27, 2001, 3:24 AM
  @@ -20,9 +75,9 @@
       /** Creates new XmlSchemaFractionDigitsFacet */
       public XmlSchemaFractionDigitsFacet() {
       }
  -	
  -	public XmlSchemaFractionDigitsFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  +
  +    public XmlSchemaFractionDigitsFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   
   }
  
  
  
  1.2       +75 -20    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaGroup.java
  
  Index: XmlSchemaGroup.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaGroup.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaGroup.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaGroup.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaGroup.java
    *
    * Created on September 27, 2001, 3:34 AM
  @@ -20,24 +75,24 @@
       /** Creates new XmlSchemaGroup */
       public XmlSchemaGroup() {
       }
  -	
  -	String name;
  -	XmlSchemaGroupBase particle;
  -	
  -	public String getName() {
  -		return name;
  -	}
  -	
  -	public void setName(String name) {
  -		this.name = name;
  -	}
  -	
  -	public XmlSchemaGroupBase getParticle() {
  -		return particle;
  -	}
  -	
  -	public void setParticle(XmlSchemaGroupBase particle) {
  -		this.particle = particle;
  -	}
  -	
  +
  +    String name;
  +    XmlSchemaGroupBase particle;
  +
  +    public String getName() {
  +        return name;
  +    }
  +
  +    public void setName(String name) {
  +        this.name = name;
  +    }
  +
  +    public XmlSchemaGroupBase getParticle() {
  +        return particle;
  +    }
  +
  +    public void setParticle(XmlSchemaGroupBase particle) {
  +        this.particle = particle;
  +    }
  +
   }
  
  
  
  1.2       +59 -4     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaGroupBase.java
  
  Index: XmlSchemaGroupBase.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaGroupBase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaGroupBase.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaGroupBase.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaGroupBase.java
    *
    * Created on September 27, 2001, 3:36 AM
  @@ -13,12 +68,12 @@
    */
   
   public abstract class XmlSchemaGroupBase extends XmlSchemaParticle {
  -	XmlSchemaObjectCollection items;
  -	
  +    XmlSchemaObjectCollection items;
  +
       /** Creates new XmlSchemaGroupBase */
       public XmlSchemaGroupBase() {
  -		items = new XmlSchemaObjectCollection();
  +        items = new XmlSchemaObjectCollection();
       }
   
  -	public abstract XmlSchemaObjectCollection getItems();
  +    public abstract XmlSchemaObjectCollection getItems();
   }
  
  
  
  1.2       +74 -17    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaGroupRef.java
  
  Index: XmlSchemaGroupRef.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaGroupRef.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaGroupRef.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaGroupRef.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,11 +1,68 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaGroupRef.java
    *
    * Created on September 27, 2001, 3:37 AM
    */
   
   package org.apache.axis.xsd.xml.schema;
  +
   import org.apache.axis.xsd.xml.QualifiedName;
  +
   /**
    * Class used within complex types that defines the reference to 
    * groups defined at the schema level. Represents the World Wide
  @@ -19,22 +76,22 @@
       /** Creates new XmlSchemaGroupRef */
       public XmlSchemaGroupRef() {
       }
  -	
  -	XmlSchemaGroupBase particle;
  -	
  -	public XmlSchemaGroupBase getParticle(){
  -		return this.particle;
  -	}
  -	
  -	QualifiedName refName;
  -	
  -	public QualifiedName getRefName(){
  -		return this.refName;
  -	}
  -
  -	public void setRefName(QualifiedName refName) {
  -		this.refName = refName;
  -	}
  -	
  +
  +    XmlSchemaGroupBase particle;
  +
  +    public XmlSchemaGroupBase getParticle() {
  +        return this.particle;
  +    }
  +
  +    QualifiedName refName;
  +
  +    public QualifiedName getRefName() {
  +        return this.refName;
  +    }
  +
  +    public void setRefName(QualifiedName refName) {
  +        this.refName = refName;
  +    }
  +
   
   }
  
  
  
  1.2       +83 -29    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaIdentityConstraint.java
  
  Index: XmlSchemaIdentityConstraint.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaIdentityConstraint.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaIdentityConstraint.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaIdentityConstraint.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaIdentityConstraint.java
    *
    * Created on September 27, 2001, 3:34 AM
  @@ -18,35 +73,34 @@
   
       /** Creates new XmlSchemaIdentityConstraint */
       public XmlSchemaIdentityConstraint() {
  -		fields = new XmlSchemaObjectCollection();
  +        fields = new XmlSchemaObjectCollection();
  +    }
  +
  +    XmlSchemaObjectCollection fields;
  +
  +    public XmlSchemaObjectCollection getFields() {
  +        return fields;
  +    }
  +
  +    String name;
  +
  +    public String getName() {
  +        return name;
  +    }
  +
  +    public void setName(String name) {
  +        this.name = name;
       }
   
  -	XmlSchemaObjectCollection fields;
  -	
  -	public XmlSchemaObjectCollection getFields() {
  -		return fields;
  -	}
  -	
  -	String name;
  -	
  -	public String getName() {
  -		return name;
  -	}
  -	
  -	public void setName(String name) {
  -		this.name = name;
  -	}
  -	
  -	XmlSchemaXPath selector;
  -	
  -	public XmlSchemaXPath getSelector() {
  -		return selector;
  -	}
  -	
  -	public void setSelector(XmlSchemaXPath selector) {
  -		this.selector = selector;
  -	}
  -	
  -	
  -	
  +    XmlSchemaXPath selector;
  +
  +    public XmlSchemaXPath getSelector() {
  +        return selector;
  +    }
  +
  +    public void setSelector(XmlSchemaXPath selector) {
  +        this.selector = selector;
  +    }
  +
  +
   }
  
  
  
  1.2       +68 -13    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaImport.java
  
  Index: XmlSchemaImport.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaImport.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaImport.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaImport.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaImport.java
    *
    * Created on September 27, 2001, 3:20 AM
  @@ -13,22 +68,22 @@
    * @author  mukund
    */
   
  -public class XmlSchemaImport extends XmlSchemaExternal{
  +public class XmlSchemaImport extends XmlSchemaExternal {
   
       /** Creates new XmlSchemaImport */
       public XmlSchemaImport() {
  -		super();
  +        super();
       }
   
  -	String namespace;
  -	
  -	public String getNamespace(){
  -		return this.namespace;
  -	}
  -	
  -	public void setNamespace( String namespace){
  -		this.namespace = namespace;
  -	}
  -							  
  -					 
  +    String namespace;
  +
  +    public String getNamespace() {
  +        return this.namespace;
  +    }
  +
  +    public void setNamespace(String namespace) {
  +        this.namespace = namespace;
  +    }
  +
  +
   }
  
  
  
  1.2       +56 -1     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaInclude.java
  
  Index: XmlSchemaInclude.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaInclude.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaInclude.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaInclude.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaInclude.java
    *
    * Created on September 27, 2001, 3:20 AM
  @@ -18,7 +73,7 @@
   
       /** Creates new XmlSchemaInclude */
       public XmlSchemaInclude() {
  -		super();
  +        super();
       }
   
   }
  
  
  
  1.2       +57 -1     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaKey.java
  
  Index: XmlSchemaKey.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaKey.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaKey.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaKey.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaKey.java
    *
    * Created on September 27, 2001, 3:34 AM
  @@ -13,7 +69,7 @@
    * @author  mukund
    */
   
  -public class XmlSchemaKey  extends XmlSchemaIdentityConstraint{
  +public class XmlSchemaKey extends XmlSchemaIdentityConstraint {
   
       /** Creates new XmlSchemaKey */
       public XmlSchemaKey() {
  
  
  
  1.2       +66 -9     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaKeyref.java
  
  Index: XmlSchemaKeyref.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaKeyref.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaKeyref.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaKeyref.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,10 +1,67 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaKeyref.java
    *
    * Created on September 27, 2001, 3:35 AM
    */
   
   package org.apache.axis.xsd.xml.schema;
  +
   import org.apache.axis.xsd.xml.QualifiedName;
   
   /**
  @@ -20,13 +77,13 @@
       public XmlSchemaKeyref() {
       }
   
  -	QualifiedName refer;
  -	
  -	public QualifiedName getRefer() {
  -		return refer;
  -	}
  -	
  -	public void setRefer(QualifiedName refer) {
  -		this.refer = refer;
  -	}
  +    QualifiedName refer;
  +
  +    public QualifiedName getRefer() {
  +        return refer;
  +    }
  +
  +    public void setRefer(QualifiedName refer) {
  +        this.refer = refer;
  +    }
   }
  
  
  
  1.2       +60 -4     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaLengthFacet.java
  
  Index: XmlSchemaLengthFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaLengthFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaLengthFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaLengthFacet.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaLengthFacet.java
    *
    * Created on September 27, 2001, 3:24 AM
  @@ -15,13 +71,13 @@
   
   // Vidyanand - 16th Oct - initial implementation
   
  -public class XmlSchemaLengthFacet extends XmlSchemaNumericFacet{
  +public class XmlSchemaLengthFacet extends XmlSchemaNumericFacet {
   
       /** Creates new XmlSchemaLengthFacet */
       public XmlSchemaLengthFacet() {
       }
   
  -	public XmlSchemaLengthFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  +    public XmlSchemaLengthFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   }
  
  
  
  1.2       +60 -4     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMaxExclusiveFacet.java
  
  Index: XmlSchemaMaxExclusiveFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMaxExclusiveFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaMaxExclusiveFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaMaxExclusiveFacet.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaMaxExclusiveFacet.java
    *
    * Created on September 27, 2001, 3:21 AM
  @@ -21,8 +77,8 @@
       /** Creates new XmlSchemaMaxExclusiveFacet */
       public XmlSchemaMaxExclusiveFacet() {
       }
  -	
  -	public XmlSchemaMaxExclusiveFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  +
  +    public XmlSchemaMaxExclusiveFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   }
  
  
  
  1.2       +59 -3     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMaxInclusiveFacet.java
  
  Index: XmlSchemaMaxInclusiveFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMaxInclusiveFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaMaxInclusiveFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaMaxInclusiveFacet.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaMaxInclusiveFacet.java
    *
    * Created on September 27, 2001, 3:22 AM
  @@ -22,7 +78,7 @@
       public XmlSchemaMaxInclusiveFacet() {
       }
   
  -	public XmlSchemaMaxInclusiveFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  +    public XmlSchemaMaxInclusiveFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   }
  
  
  
  1.2       +59 -3     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMaxLengthFacet.java
  
  Index: XmlSchemaMaxLengthFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMaxLengthFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaMaxLengthFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaMaxLengthFacet.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaMaxLengthFacet.java
    *
    * Created on September 27, 2001, 3:32 AM
  @@ -21,7 +77,7 @@
       public XmlSchemaMaxLengthFacet() {
       }
   
  -	public XmlSchemaMaxLengthFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  +    public XmlSchemaMaxLengthFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   }
  
  
  
  1.2       +60 -4     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMinExclusiveFacet.java
  
  Index: XmlSchemaMinExclusiveFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMinExclusiveFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaMinExclusiveFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaMinExclusiveFacet.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaMinExclusive.java
    *
    * Created on September 27, 2001, 3:22 AM
  @@ -20,9 +76,9 @@
       /** Creates new XmlSchemaMinExclusive */
       public XmlSchemaMinExclusiveFacet() {
       }
  -	
  -	public XmlSchemaMinExclusiveFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  +
  +    public XmlSchemaMinExclusiveFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   
   }
  
  
  
  1.2       +59 -3     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMinInclusiveFacet.java
  
  Index: XmlSchemaMinInclusiveFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMinInclusiveFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaMinInclusiveFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaMinInclusiveFacet.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaMinInclusive.java
    *
    * Created on September 27, 2001, 3:22 AM
  @@ -21,7 +77,7 @@
       public XmlSchemaMinInclusiveFacet() {
       }
   
  -	public XmlSchemaMinInclusiveFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  +    public XmlSchemaMinInclusiveFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   }
  
  
  
  1.2       +59 -3     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMinLengthFacet.java
  
  Index: XmlSchemaMinLengthFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaMinLengthFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaMinLengthFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaMinLengthFacet.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaMinLengthFacet.java
    *
    * Created on September 27, 2001, 3:32 AM
  @@ -21,7 +77,7 @@
       public XmlSchemaMinLengthFacet() {
       }
   
  -	public XmlSchemaMinLengthFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  +    public XmlSchemaMinLengthFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   }
  
  
  
  1.2       +84 -29    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaNotation.java
  
  Index: XmlSchemaNotation.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaNotation.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaNotation.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaNotation.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaNotation.java
    *
    * Created on September 27, 2001, 3:35 AM
  @@ -16,38 +72,37 @@
    * @author  mukund
    */
   
  -public class XmlSchemaNotation extends XmlSchemaAnnotated  {
  +public class XmlSchemaNotation extends XmlSchemaAnnotated {
  +
  +    String name, system, publicNotation;
   
  -	String name, system, publicNotation;
  -	
       /** Creates new XmlSchemaNotation */
       public XmlSchemaNotation() {
       }
   
  -	public String getName() {
  -		return name;
  -	}
  -	
  -	public void setString(String name) {
  -		this.name = name;
  -	}
  -	
  -	public String getPublic() {
  -		return publicNotation;
  -	}
  -	
  -	public void setPublic(String publicNotation) {
  -		this.publicNotation = publicNotation;
  -	}
  -	
  -	public String getSystem() {
  -		return system;
  -	}
  -	
  -	public void setSystem(String system) {
  -		this.system = system;
  -	}
  -	
  -	
  -	
  +    public String getName() {
  +        return name;
  +    }
  +
  +    public void setString(String name) {
  +        this.name = name;
  +    }
  +
  +    public String getPublic() {
  +        return publicNotation;
  +    }
  +
  +    public void setPublic(String publicNotation) {
  +        this.publicNotation = publicNotation;
  +    }
  +
  +    public String getSystem() {
  +        return system;
  +    }
  +
  +    public void setSystem(String system) {
  +        this.system = system;
  +    }
  +
  +
   }
  
  
  
  1.2       +61 -5     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaNumericFacet.java
  
  Index: XmlSchemaNumericFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaNumericFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaNumericFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaNumericFacet.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaNumericFacet.java
    *
    * Created on September 27, 2001, 3:23 AM
  @@ -19,10 +75,10 @@
       /** Creates new XmlSchemaNumericFacet */
       protected XmlSchemaNumericFacet() {
       }
  -	
  -	protected XmlSchemaNumericFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  -	
  +
  +    protected XmlSchemaNumericFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
  +
   
   }
  
  
  
  1.2       +98 -42    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaObject.java
  
  Index: XmlSchemaObject.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaObject.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaObject.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaObject.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaObject.java
    *
    * Created on September 27, 2001, 3:07 AM
  @@ -14,49 +70,49 @@
   // October 15th - momo - initial implementation
   
   public abstract class XmlSchemaObject {
  -	int lineNumber;
  -	int linePosition;
  -	String sourceURI;
  -		
  +    int lineNumber;
  +    int linePosition;
  +    String sourceURI;
  +
       /** Creates new XmlSchemaObject */
       protected XmlSchemaObject() {
       }
  -	
  -	public int getLineNumber() {
  -		return lineNumber;
  -	}
  -	
  -	public void setLineNumber(int lineNumber) {
  -		this.lineNumber = lineNumber;
  -	}
  -	
  -	public int getLinePosition() {
  -		return linePosition;
  -	}
  -	
  -	public void setLinePosition(int linePosition) {
  -		this.linePosition = linePosition;
  -	}
  -	
  -	public String getSourceURI() {
  -		return sourceURI;
  -	}
  -	
  -	public void setSourceURI(String sourceURI) {
  -		this.sourceURI = sourceURI;
  -	}
  -	
  -	public boolean equals(Object what) {
  -		// toDO : implement this once everything completed
  -		return true;
  -	}
  -	
  -	public String toString(String prefix, int tab) { 
  -		String xml = new String();
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		xml += this.getClass().toString() + "\n";
  -		return xml;
  -	}
  +
  +    public int getLineNumber() {
  +        return lineNumber;
  +    }
  +
  +    public void setLineNumber(int lineNumber) {
  +        this.lineNumber = lineNumber;
  +    }
  +
  +    public int getLinePosition() {
  +        return linePosition;
  +    }
  +
  +    public void setLinePosition(int linePosition) {
  +        this.linePosition = linePosition;
  +    }
  +
  +    public String getSourceURI() {
  +        return sourceURI;
  +    }
  +
  +    public void setSourceURI(String sourceURI) {
  +        this.sourceURI = sourceURI;
  +    }
  +
  +    public boolean equals(Object what) {
  +        // toDO : implement this once everything completed
  +        return true;
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        xml += this.getClass().toString() + "\n";
  +        return xml;
  +    }
   }
  
  
  
  1.2       +109 -52   xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaObjectCollection.java
  
  Index: XmlSchemaObjectCollection.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaObjectCollection.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaObjectCollection.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaObjectCollection.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,12 +1,69 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaObjectCollection.java
    *
    * Created on September 27, 2001, 2:58 AM
    */
   
   package org.apache.axis.xsd.xml.schema;
  -import java.util.Vector;
  +
   import java.util.Iterator;
  +import java.util.Vector;
   
   /**
    * An object collection class to handle XmlSchemaObjects when collections
  @@ -16,58 +73,58 @@
    */
   public class XmlSchemaObjectCollection {
   
  -	Vector objects;
  -	
  +    Vector objects;
  +
       /** Creates new XmlSchemaObjectCollection */
       public XmlSchemaObjectCollection() {
  -		objects = new Vector();
  +        objects = new Vector();
  +    }
  +
  +    public int getCount() {
  +        return objects.size();
  +    }
  +
  +    public XmlSchemaObject getItem(int i) {
  +        return (XmlSchemaObject) objects.elementAt(i);
  +    }
  +
  +    public void setItem(int i, XmlSchemaObject item) {
  +        objects.insertElementAt(item, i);
  +    }
  +
  +    public void add(XmlSchemaObject item) {
  +        objects.addElement(item);
  +    }
  +
  +    public boolean contains(XmlSchemaObject item) {
  +        return objects.contains(item);
  +    }
  +
  +    public int indexOf(XmlSchemaObject item) {
  +        return objects.indexOf(item);
  +    }
  +
  +    public void remove(XmlSchemaObject item) {
  +        objects.remove(item);
  +    }
  +
  +    public void removeAt(int index) {
  +        objects.removeElementAt(index);
  +    }
  +
  +    public Iterator getIterator() {
  +        return objects.iterator();
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +
  +        for (int i = 0; i < getCount(); i++) {
  +            xml += getItem(i).toString(prefix, tab);
  +        }
  +
  +
  +        return xml;
  +
       }
  -	
  -	public int getCount() {
  -		return objects.size();
  -	}
  -	
  -	public XmlSchemaObject getItem(int i) {
  -		return (XmlSchemaObject)objects.elementAt(i);
  -	}
  -
  -	public void setItem(int i, XmlSchemaObject item) {
  -		objects.insertElementAt(item, i);
  -	}
  -	
  -	public void add(XmlSchemaObject item) {
  -		objects.addElement(item);
  -	}
  -	
  -	public boolean contains(XmlSchemaObject item) {
  -		return objects.contains(item);
  -	}
  -	
  -	public int indexOf(XmlSchemaObject item) {
  -		return objects.indexOf(item);
  -	}
  -	
  -	public void remove(XmlSchemaObject item) {
  -		objects.remove(item);
  -	}
  -	
  -	public void removeAt(int index) {
  -		objects.removeElementAt(index);
  -	}
  -	
  -	public Iterator getIterator() {
  -		return objects.iterator();
  -	}
  -	
  -	public String toString(String prefix, int tab) {
  -		String xml = new String();
  -		
  -		for(int i=0;i<getCount();i++) {
  -			xml += getItem(i).toString(prefix, tab);
  -		}
  -
  -		
  -		return xml;
  -			
  -	}
   }
  
  
  
  1.2       +56 -0     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaObjectEnumerator.java
  
  Index: XmlSchemaObjectEnumerator.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaObjectEnumerator.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaObjectEnumerator.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaObjectEnumerator.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaObjectEnumerator.java
    *
    * Created on September 27, 2001, 3:41 AM
  
  
  
  1.2       +89 -30    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaObjectTable.java
  
  Index: XmlSchemaObjectTable.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaObjectTable.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaObjectTable.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaObjectTable.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaObjectTable.java
    *
    * Created on September 27, 2001, 3:41 AM
  @@ -6,10 +62,11 @@
   
   package org.apache.axis.xsd.xml.schema;
   
  -import java.util.Hashtable;
  -import java.util.Enumeration;
   import org.apache.axis.xsd.xml.QualifiedName;
   
  +import java.util.Enumeration;
  +import java.util.Hashtable;
  +
   /**
    * A collection class that provides read-only helpers for XmlSchemaObject 
    * objects. This class is used to provide the collections for contained 
  @@ -24,35 +81,37 @@
   
   public class XmlSchemaObjectTable {
   
  -	Hashtable collection;
  +    Hashtable collection;
  +
       /** Creates new XmlSchemaObjectTable */
       public XmlSchemaObjectTable() {
  -		this.collection = new Hashtable();;
  +        this.collection = new Hashtable();
  +        ;
  +    }
  +
  +    public int getCount() {
  +        return this.collection.size();
  +    }
  +
  +    public XmlSchemaObject getItem(QualifiedName name) {
  +        return (XmlSchemaObject) collection.get(name);
  +    }
  +
  +    public Enumeration getNames() {
  +        return collection.keys();
  +    }
  +
  +    public Enumeration getValues() {
  +        return collection.elements();
  +    }
  +
  +    public boolean contains(QualifiedName name) {
  +        return collection.contains(name);
  +    }
  +
  +    //TODO: think of smthg better 
  +    public Object getEnumerator() {
  +        return null;
       }
  -	
  -	public int getCount() {
  -		return this.collection.size();
  -	}
  -	
  -	public XmlSchemaObject getItem( QualifiedName name ) {
  -		return (XmlSchemaObject) collection.get(name);
  -	}
  -	
  -	public Enumeration getNames(){
  -		return collection.keys();
  -	}
  -
  -	public Enumeration getValues(){
  -		return collection.elements();
  -	}
  -	
  -	public boolean contains(QualifiedName name) {
  -		return collection.contains( name );
  -	}
  -	
  -	//TODO: think of smthg better 
  -	public Object getEnumerator(){
  -		return null;
  -	}
  -	
  +
   }
  
  
  
  1.2       +78 -22    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaParticle.java
  
  Index: XmlSchemaParticle.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaParticle.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaParticle.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaParticle.java	17 Nov 2002 23:53:18 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaParticle.java
    *
    * Created on September 27, 2001, 3:35 AM
  @@ -16,35 +72,35 @@
   
   public class XmlSchemaParticle extends XmlSchemaAnnotated {
   
  -	long maxOccurs = 1;
  -	String maxOccursString;
  -	long minOccurs = 1;
  -	String minOccursString;
  -	
  +    long maxOccurs = 1;
  +    String maxOccursString;
  +    long minOccurs = 1;
  +    String minOccursString;
  +
       /**
  -	 * Creates new XmlSchemaParticle 
  +     * Creates new XmlSchemaParticle 
        * Particle types are usually interchangeable. 
        * A local element declaration or reference to a global element 
        * declaration (element), a compositor ( sequence, choice, or all), 
        * a reference to a named content model group (group), or an element wildcard (any).
        *
  -	 */
  +     */
       public XmlSchemaParticle() {
       }
   
  -	public void setMaxOccurs(long maxOccurs) {
  -		this.maxOccurs = maxOccurs;
  -	}
  -	
  -	public long getMaxOccurs() {
  -		return maxOccurs;
  -	}
  -	
  -	public void setMinOccurs(long minOccurs) {
  -		this.minOccurs = minOccurs;
  -	}
  -	
  -	public long getMinOccurs() {
  -		return minOccurs;
  -	}
  +    public void setMaxOccurs(long maxOccurs) {
  +        this.maxOccurs = maxOccurs;
  +    }
  +
  +    public long getMaxOccurs() {
  +        return maxOccurs;
  +    }
  +
  +    public void setMinOccurs(long minOccurs) {
  +        this.minOccurs = minOccurs;
  +    }
  +
  +    public long getMinOccurs() {
  +        return minOccurs;
  +    }
   }
  
  
  
  1.2       +59 -3     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaPatternFacet.java
  
  Index: XmlSchemaPatternFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaPatternFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaPatternFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaPatternFacet.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaPatternFacet.java
    *
    * Created on September 27, 2001, 3:33 AM
  @@ -21,7 +77,7 @@
       public XmlSchemaPatternFacet() {
       }
   
  -	public XmlSchemaPatternFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  +    public XmlSchemaPatternFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   }
  
  
  
  1.2       +77 -21    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaRedefine.java
  
  Index: XmlSchemaRedefine.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaRedefine.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaRedefine.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaRedefine.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaRedefine.java
    *
    * Created on September 27, 2001, 3:20 AM
  @@ -15,31 +71,31 @@
    * @author  mukund
    */
   
  -public class XmlSchemaRedefine  extends XmlSchemaExternal {
  +public class XmlSchemaRedefine extends XmlSchemaExternal {
   
       /** Creates new XmlSchemaRedefine */
       public XmlSchemaRedefine() {
           items = new XmlSchemaObjectCollection();
       }
   
  -	XmlSchemaObjectTable attributeGroups, groups, schemaTypes;
  -	
  -	public XmlSchemaObjectTable getAttributeGroup() {
  -		return attributeGroups;
  -	}
  -	
  -	public XmlSchemaObjectTable getGroup() {
  -		return groups;
  -	}
  -	
  -	XmlSchemaObjectCollection items;
  -	
  -	public XmlSchemaObjectCollection getItems() {
  -		return items;
  -	}
  -	
  -	public XmlSchemaObjectTable getSchemaTypes() {
  -		return schemaTypes;
  -	}
  -	
  +    XmlSchemaObjectTable attributeGroups, groups, schemaTypes;
  +
  +    public XmlSchemaObjectTable getAttributeGroup() {
  +        return attributeGroups;
  +    }
  +
  +    public XmlSchemaObjectTable getGroup() {
  +        return groups;
  +    }
  +
  +    XmlSchemaObjectCollection items;
  +
  +    public XmlSchemaObjectCollection getItems() {
  +        return items;
  +    }
  +
  +    public XmlSchemaObjectTable getSchemaTypes() {
  +        return schemaTypes;
  +    }
  +
   }
  
  
  
  1.2       +83 -27    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSequence.java
  
  Index: XmlSchemaSequence.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSequence.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaSequence.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaSequence.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaSequence.java
    *
    * Created on September 27, 2001, 3:37 AM
  @@ -20,31 +76,31 @@
       public XmlSchemaSequence() {
       }
   
  -	/**
  -	 *  The elements contained within the compositor. 
  -	 *	Collection of XmlSchemaElement, XmlSchemaGroupRef, 
  -	 *  XmlSchemaChoice, XmlSchemaSequence, or XmlSchemaAny.
  -	 */
  -	public XmlSchemaObjectCollection getItems() {
  -		return items;
  -	}	
  -	
  -	public String toString(String prefix, int tab) {
  -		String xml = new String();
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		if(!prefix.equals("") && prefix.indexOf(":") == -1)
  -			prefix += ":";
  -	
  -		xml += "<"+prefix+"sequence>\n";
  -		for(int i=0;i<items.getCount();i++) {
  -			xml += items.getItem(i).toString(prefix, (tab+1));
  -		}
  -		
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		xml += "</"+prefix+"sequence>\n";
  -		return xml;
  -	}
  +    /**
  +     *  The elements contained within the compositor. 
  +     *	Collection of XmlSchemaElement, XmlSchemaGroupRef, 
  +     *  XmlSchemaChoice, XmlSchemaSequence, or XmlSchemaAny.
  +     */
  +    public XmlSchemaObjectCollection getItems() {
  +        return items;
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +        if (!prefix.equals("") && prefix.indexOf(":") == -1)
  +            prefix += ":";
  +
  +        xml += "<" + prefix + "sequence>\n";
  +        for (int i = 0; i < items.getCount(); i++) {
  +            xml += items.getItem(i).toString(prefix, (tab + 1));
  +        }
  +
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        xml += "</" + prefix + "sequence>\n";
  +        return xml;
  +    }
   }
  
  
  
  1.2       +1751 -1698xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSerializer.java
  
  Index: XmlSchemaSerializer.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSerializer.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaSerializer.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaSerializer.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,60 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +
  +/*
    * XmlSchemaSerializer.java
    * 
    * Construct Document of given XmlSchema component
  @@ -19,180 +75,173 @@
   package org.apache.axis.xsd.xml.schema;
   
   
  -import java.io.FileReader;
  -import java.util.Enumeration;
  -import java.util.ArrayList;
  -import java.util.Hashtable;
  -
   import org.apache.axis.xsd.xml.QualifiedName;
  -
  -import org.w3c.dom.DocumentFragment;
  -import org.w3c.dom.Element;
  +import org.w3c.dom.Attr;
   import org.w3c.dom.Document;
  -import org.w3c.dom.NodeList;
  +import org.w3c.dom.Element;
   import org.w3c.dom.NamedNodeMap;
   import org.w3c.dom.Node;
  +import org.w3c.dom.NodeList;
   import org.w3c.dom.Text;
  -import org.w3c.dom.Attr;
   
  -import javax.xml.parsers.DocumentBuilderFactory;
   import javax.xml.parsers.DocumentBuilder;
  +import javax.xml.parsers.DocumentBuilderFactory;
   import javax.xml.parsers.ParserConfigurationException;
  -
  -import org.xml.sax.InputSource;
  -import org.xml.sax.SAXException;
  +import java.util.ArrayList;
  +import java.util.Enumeration;
  +import java.util.Hashtable;
   
   
   public class XmlSchemaSerializer {
       private Hashtable schema_ns;
  -    
  -    static String xsdPrefix="xs";
  -    public static final String xsdNamespace="http://www.w3.org/2001/XMLSchema";
  +
  +    static String xsdPrefix = "xs";
  +    public static final String xsdNamespace = "http://www.w3.org/2001/XMLSchema";
       ArrayList docs;
       Element schemaElement;
   
       private XmlSchemaSerializer() {
  -		docs = new ArrayList();
  -		schema_ns = new Hashtable();
  +        docs = new ArrayList();
  +        schema_ns = new Hashtable();
       }
  -    
  -    public static void main(String[] args) throws Exception{    
  +
  +    public static void main(String[] args) throws Exception {
           XmlSchema schema = XmlSchema.read(new java.io.FileReader(
  -																 "E:/projects/core/xml/schema/test/serializerTestCase/"
  -																 +"Test8ElementRefTest.xsd"), null);
  +                "E:/projects/core/xml/schema/test/serializerTestCase/"
  +                + "Test8ElementRefTest.xsd"), null);
           //XmlSchemaSerializer serializer = new XmlSchemaSerializer();
           Document[] serializedSchemas = XmlSchemaSerializer.serializeSchema(schema, true);
       }
  -    
  -    
  +
  +
       /************************************************************************
  -	 * Document[]  serializeSchema(XmlSchema schemaObj, 
  -	 *   boolean serializeIncluded)
  -	 *
  -	 * Serialize XmlSchema object pass back the document containing a schema
  -	 * element as its root.
  -	 *
  -	 * Parameter:
  -	 * schemaObj - Schema object to serialize.
  -	 * serialzeIncluded - whether to serialize the included(imported) 
  -	 *                    schema or not. pass true for serialize all included 
  -	 *                    schema. 
  -	 *
  -	 * Return:
  -	 * Array of Documents that include/imported. 
  -	 ************************************************************************/
  -    public static Document[] serializeSchema(XmlSchema schemaObj, 
  -											 boolean serializeIncluded) throws XmlSchemaSerializerException{
  -        return new XmlSchemaSerializer().serializeSchemaElement(schemaObj, 
  -																serializeIncluded);
  -    }
  -    
  -    Document[]  serializeSchemaElement(XmlSchema schemaObj, 
  -									   boolean serializeIncluded) throws XmlSchemaSerializerException{
  -     
  +     * Document[]  serializeSchema(XmlSchema schemaObj, 
  +     *   boolean serializeIncluded)
  +     *
  +     * Serialize XmlSchema object pass back the document containing a schema
  +     * element as its root.
  +     *
  +     * Parameter:
  +     * schemaObj - Schema object to serialize.
  +     * serialzeIncluded - whether to serialize the included(imported) 
  +     *                    schema or not. pass true for serialize all included 
  +     *                    schema. 
  +     *
  +     * Return:
  +     * Array of Documents that include/imported. 
  +     ************************************************************************/
  +    public static Document[] serializeSchema(XmlSchema schemaObj,
  +                                             boolean serializeIncluded) throws XmlSchemaSerializerException {
  +        return new XmlSchemaSerializer().serializeSchemaElement(schemaObj,
  +                                                                serializeIncluded);
  +    }
  +
  +    Document[] serializeSchemaElement(XmlSchema schemaObj,
  +                                      boolean serializeIncluded) throws XmlSchemaSerializerException {
  +
           XmlSchemaObjectCollection items = schemaObj.getItems();
  -		Document serializedSchemaDocs = null;
  -		try{    
  -			DocumentBuilderFactory docFac = DocumentBuilderFactory.newInstance();            
  -			docFac.setNamespaceAware(true);
  -			DocumentBuilder builder = docFac.newDocumentBuilder();
  -			serializedSchemaDocs = builder.newDocument();
  -		}catch( ParserConfigurationException e ){
  -			throw new XmlSchemaException(e.getMessage());	
  -		}
  +        Document serializedSchemaDocs = null;
  +        try {
  +            DocumentBuilderFactory docFac = DocumentBuilderFactory.newInstance();
  +            docFac.setNamespaceAware(true);
  +            DocumentBuilder builder = docFac.newDocumentBuilder();
  +            serializedSchemaDocs = builder.newDocument();
  +        } catch (ParserConfigurationException e) {
  +            throw new XmlSchemaException(e.getMessage());
  +        }
   
           Element serializedSchema;
  -       
  -		serializedSchema = setupNamespaces(serializedSchemaDocs, schemaObj);
  -		schemaElement = serializedSchema;
  -        
  -        if(schemaObj.targetNamespace != null){
  -            serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS, 
  -											"targetNamespace",schemaObj.targetNamespace);
   
  -            Object targetNS = 
  -                schema_ns.get(schemaObj.targetNamespace);
  +        serializedSchema = setupNamespaces(serializedSchemaDocs, schemaObj);
  +        schemaElement = serializedSchema;
  +
  +        if (schemaObj.targetNamespace != null) {
  +            serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS,
  +                                            "targetNamespace", schemaObj.targetNamespace);
  +
  +            Object targetNS =
  +                    schema_ns.get(schemaObj.targetNamespace);
               
               //if the namespace is not entered then add 
               //the targetNamespace as its
  -            if(targetNS == null){
  -                serializedSchema.setAttributeNS("http://www.w3.org/2000/xmlns/", 
  -												"xmlns", schemaObj.targetNamespace);
  +            if (targetNS == null) {
  +                serializedSchema.setAttributeNS("http://www.w3.org/2000/xmlns/",
  +                                                "xmlns", schemaObj.targetNamespace);
                   schema_ns.put(schemaObj.targetNamespace.toString(), "");
               }
           }
           
           
           //todo: implement xml:lang, 
  -        if(schemaObj.attributeFormDefault != null ){ 
  -            String formQualified =  schemaObj.attributeFormDefault.getValue();
  -            
  -            if(!formQualified.equals("None"))
  -                serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS, 
  -												"attributeFormDefault",convertString(formQualified));
  +        if (schemaObj.attributeFormDefault != null) {
  +            String formQualified = schemaObj.attributeFormDefault.getValue();
  +
  +            if (!formQualified.equals("None"))
  +                serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS,
  +                                                "attributeFormDefault", convertString(formQualified));
           }
  -        
  -        if(schemaObj.elementFormDefault != null){
  -            String formQualified =  schemaObj.elementFormDefault.getValue();
  -            
  -            if(!formQualified.equals("None"))
  -                serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS, 
  -												"elementFormDefault",convertString(formQualified));
  +
  +        if (schemaObj.elementFormDefault != null) {
  +            String formQualified = schemaObj.elementFormDefault.getValue();
  +
  +            if (!formQualified.equals("None"))
  +                serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS,
  +                                                "elementFormDefault", convertString(formQualified));
           }
  -        
  -        
  -        if(schemaObj.annotation != null){
  +
  +
  +        if (schemaObj.annotation != null) {
               Element annotation = serializeAnnotation(serializedSchemaDocs,
  -													 schemaObj.annotation, schemaObj);
  +                                                     schemaObj.annotation, schemaObj);
               serializedSchema.appendChild(annotation);
           }
  -        if(schemaObj.id != null){
  -            serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS, "id", 
  -											schemaObj.id);
  +        if (schemaObj.id != null) {
  +            serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS, "id",
  +                                            schemaObj.id);
           }
  -        if(schemaObj.blockDefault != null){
  +        if (schemaObj.blockDefault != null) {
               String blockDefault = schemaObj.blockDefault.getValue();
  -            if(!blockDefault.equals("None")){
  +            if (!blockDefault.equals("None")) {
                   blockDefault = convertString(blockDefault);
  -                serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS, 
  -												"blockDefault", blockDefault);
  +                serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS,
  +                                                "blockDefault", blockDefault);
               }
           }
  -        if(schemaObj.finalDefault != null){
  +        if (schemaObj.finalDefault != null) {
               String finalDefault = schemaObj.finalDefault.getValue();
  -            if(!finalDefault.equals("None")){
  +            if (!finalDefault.equals("None")) {
                   finalDefault = convertString(finalDefault);
  -                serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS, 
  -												"finalDefault", finalDefault);
  +                serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS,
  +                                                "finalDefault", finalDefault);
               }
           }
  -        
  -        if(schemaObj.version != null){
  -            serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS, 
  -											"version", schemaObj.version);
  +
  +        if (schemaObj.version != null) {
  +            serializedSchema.setAttributeNS(schemaObj.SCHEMA_NS,
  +                                            "version", schemaObj.version);
           }
           
           //after serialize the schema add into documentation 
           //and add to document collection array  which at the end 
           //returned
  -        serializeSchemaChild(items,serializedSchema, serializedSchemaDocs, 
  -							 schemaObj, serializeIncluded);
  -    
  +        serializeSchemaChild(items, serializedSchema, serializedSchemaDocs,
  +                             schemaObj, serializeIncluded);
  +
           serializedSchemaDocs.appendChild(serializedSchema);
           docs.add(serializedSchemaDocs);
   
  -        
  +
           Document[] serializedDocs = new Document[docs.size()];
           docs.toArray(serializedDocs);
  -        
  +
           return serializedDocs;
       }
  -    
  +
       private void serializeSchemaChild(XmlSchemaObjectCollection items,
  -									  Element serializedSchema, Document serializedSchemaDocs, 
  -									  XmlSchema schemaObj, boolean serializeIncluded) 
  -        throws XmlSchemaSerializerException{
  -            
  +                                      Element serializedSchema, Document serializedSchemaDocs,
  +                                      XmlSchema schemaObj, boolean serializeIncluded)
  +            throws XmlSchemaSerializerException {
  +
           int itemsLength = items.getCount();
           /**
            * For each of the items that belong to this schema, 
  @@ -201,55 +250,55 @@
            * group, attrributeGroup, Attribute, include, import and redefine.
            * if any of the member found then serialize the component.
            */
  -        for(int i=0;i < itemsLength ;i++){
  +        for (int i = 0; i < itemsLength; i++) {
               XmlSchemaObject obj = items.getItem(i);
  -            
  -            if(obj instanceof XmlSchemaElement){
  -                Element e = serializeElement(serializedSchemaDocs, 
  -											 (XmlSchemaElement)obj, schemaObj);
  +
  +            if (obj instanceof XmlSchemaElement) {
  +                Element e = serializeElement(serializedSchemaDocs,
  +                                             (XmlSchemaElement) obj, schemaObj);
                   serializedSchema.appendChild(e);
  -                
  -            }else if(obj instanceof XmlSchemaSimpleType){
  -                Element e = serializeSimpleType(serializedSchemaDocs, 
  -												(XmlSchemaSimpleType)obj, schemaObj);
  +
  +            } else if (obj instanceof XmlSchemaSimpleType) {
  +                Element e = serializeSimpleType(serializedSchemaDocs,
  +                                                (XmlSchemaSimpleType) obj, schemaObj);
                   serializedSchema.appendChild(e);
  -            }else if(obj instanceof XmlSchemaComplexType){
  -                Element e = serializeComplexType(serializedSchemaDocs, 
  -												 (XmlSchemaComplexType)obj, schemaObj);
  +            } else if (obj instanceof XmlSchemaComplexType) {
  +                Element e = serializeComplexType(serializedSchemaDocs,
  +                                                 (XmlSchemaComplexType) obj, schemaObj);
                   serializedSchema.appendChild(e);
  -            }else if(obj instanceof XmlSchemaGroup){
  +            } else if (obj instanceof XmlSchemaGroup) {
                   Element e = serializeGroup(serializedSchemaDocs,
  -										   (XmlSchemaGroup)obj, schemaObj);
  +                                           (XmlSchemaGroup) obj, schemaObj);
                   serializedSchema.appendChild(e);
  -            }else if(obj instanceof XmlSchemaAttributeGroup){
  -                Element e = serializeAttributeGroup(serializedSchemaDocs, 
  -													(XmlSchemaAttributeGroup)obj, schemaObj);
  +            } else if (obj instanceof XmlSchemaAttributeGroup) {
  +                Element e = serializeAttributeGroup(serializedSchemaDocs,
  +                                                    (XmlSchemaAttributeGroup) obj, schemaObj);
                   serializedSchema.appendChild(e);
  -            }else if(obj instanceof XmlSchemaAttribute){
  -                Element e = serializeAttribute(serializedSchemaDocs, 
  -											   (XmlSchemaAttribute)obj, schemaObj);
  +            } else if (obj instanceof XmlSchemaAttribute) {
  +                Element e = serializeAttribute(serializedSchemaDocs,
  +                                               (XmlSchemaAttribute) obj, schemaObj);
                   serializedSchema.appendChild(e);
  -            }else if(obj instanceof XmlSchemaRedefine){
  -                Element e = serializeRedefine(serializedSchemaDocs, 
  -											  (XmlSchemaRedefine)obj, schemaObj);
  +            } else if (obj instanceof XmlSchemaRedefine) {
  +                Element e = serializeRedefine(serializedSchemaDocs,
  +                                              (XmlSchemaRedefine) obj, schemaObj);
                   serializedSchema.appendChild(e);
  -            }else if(obj instanceof XmlSchemaInclude ){
  -                Element e = serializeInclude(serializedSchemaDocs, 
  -											 (XmlSchemaInclude)obj, schemaObj, serializeIncluded);
  +            } else if (obj instanceof XmlSchemaInclude) {
  +                Element e = serializeInclude(serializedSchemaDocs,
  +                                             (XmlSchemaInclude) obj, schemaObj, serializeIncluded);
                   serializedSchema.appendChild(e);
  -            }else if(obj instanceof XmlSchemaImport){
  -                Element e = serializeImport(serializedSchemaDocs, 
  -											(XmlSchemaImport)obj, schemaObj, serializeIncluded);
  +            } else if (obj instanceof XmlSchemaImport) {
  +                Element e = serializeImport(serializedSchemaDocs,
  +                                            (XmlSchemaImport) obj, schemaObj, serializeIncluded);
                   serializedSchema.appendChild(e);
               }
           }
       }
  -    
  +
       /**
        * Set up <schema> namespaces appropriately and append that attr
        * into specified element
        */
  -    private Element setupNamespaces(Document schemaDocs, XmlSchema schemaObj){
  +    private Element setupNamespaces(Document schemaDocs, XmlSchema schemaObj) {
           Enumeration prefixs = schemaObj.namespaces.keys();
           Enumeration values = schemaObj.namespaces.elements();
   
  @@ -258,7 +307,7 @@
            * hashtable.  When finish then set namespace to schema 
            * element appropriatelly.
            */
  -        for(;prefixs.hasMoreElements() && values.hasMoreElements();){
  +        for (; prefixs.hasMoreElements() && values.hasMoreElements();) {
               String namespace = values.nextElement().toString();
               String prefix = prefixs.nextElement().toString();
               /*
  @@ -267,32 +316,32 @@
                * set prefix and namespace to the default attribute
                * then register the prefix on hashtable
                */
  -            if(/*prefix.trim().length()<1 &&*/ namespace.equals(xsdNamespace)){
  +            if (/*prefix.trim().length()<1 &&*/ namespace.equals(xsdNamespace)) {
                   xsdPrefix = prefix;
                   schemaObj.schema_ns_prefix = xsdPrefix;
               }
  -			
  +
               schema_ns.put(namespace, prefix);
           }
  -		//for schema that not set the xmlns attrib member
  -        if(schema_ns.get(xsdNamespace)== null){    
  +        //for schema that not set the xmlns attrib member
  +        if (schema_ns.get(xsdNamespace) == null) {
               schema_ns.put(xsdNamespace, xsdPrefix);
               schemaObj.schema_ns_prefix = xsdPrefix;
           }
   
  -        Element schemaEl = createNewElement(schemaDocs, "schema" , 
  -											schemaObj.schema_ns_prefix ,schemaObj.SCHEMA_NS);
  +        Element schemaEl = createNewElement(schemaDocs, "schema",
  +                                            schemaObj.schema_ns_prefix, schemaObj.SCHEMA_NS);
   
           Enumeration keys = schema_ns.keys();
   
  -        while(keys.hasMoreElements()){
  +        while (keys.hasMoreElements()) {
               //let it crash for null pointer because then either the schema
               //is wrong(namespace not set properly or bug in setting ns)
               String key = keys.nextElement().toString();
               String value = schema_ns.get(key).toString();
  -            value = (value.length()>1)? "xmlns:"+value : "xmlns";
  -            schemaEl.setAttributeNS("http://www.w3.org/2000/xmlns/", 
  -									value, key);
  +            value = (value.length() > 1)? "xmlns:" + value : "xmlns";
  +            schemaEl.setAttributeNS("http://www.w3.org/2000/xmlns/",
  +                                    value, key);
           }
           return schemaEl;
       }
  @@ -314,36 +363,36 @@
        * Element object representation of XmlSchemaInclude
        ************************************************************************/
       Element serializeInclude(Document doc, XmlSchemaInclude includeObj,
  -							 XmlSchema schema, boolean serializeIncluded)
  -        throws XmlSchemaSerializerException {
  -        
  -        Element includeEl = createNewElement(doc, "include", 
  -											 schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        
  -        if(includeObj.schemaLocation != null){
  -            includeEl.setAttributeNS(schema.SCHEMA_NS, "schemaLocation", 
  -									 includeObj.schemaLocation);
  +                             XmlSchema schema, boolean serializeIncluded)
  +            throws XmlSchemaSerializerException {
  +
  +        Element includeEl = createNewElement(doc, "include",
  +                                             schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if (includeObj.schemaLocation != null) {
  +            includeEl.setAttributeNS(schema.SCHEMA_NS, "schemaLocation",
  +                                     includeObj.schemaLocation);
           }
  -        
  -        if(includeObj.id != null)
  +
  +        if (includeObj.id != null)
               includeEl.setAttributeNS(schema.SCHEMA_NS, "id", includeObj.id);
  -        
  -        if(includeObj.annotation != null){
  +
  +        if (includeObj.annotation != null) {
               Element annotation = serializeAnnotation(doc,
  -													 includeObj.annotation, schema);
  +                                                     includeObj.annotation, schema);
               includeEl.appendChild(annotation);
           }
   
           //Get the XmlSchema obj and append that to the content
           XmlSchema includedSchemaObj = includeObj.getSchema();
  -        if(includedSchemaObj != null && serializeIncluded){
  +        if (includedSchemaObj != null && serializeIncluded) {
               XmlSchemaSerializer includeSeri = new XmlSchemaSerializer();
               includeSeri.serializeSchemaElement(includedSchemaObj, true);
               XmlSchemaObjectCollection ii = includedSchemaObj.getItems();
  -            Document d = (Document)includeSeri.docs.get(0);
  +            Document d = (Document) includeSeri.docs.get(0);
               docs.addAll(includeSeri.docs);
           }
  -        
  +
           return includeEl;
       }
   
  @@ -363,42 +412,42 @@
        * Return:
        * Element object representation of XmlSchemaImport
        ************************************************************************/
  -    Element serializeImport(Document doc, XmlSchemaImport importObj, 
  -							XmlSchema schema, boolean serializeIncluded)
  -        throws XmlSchemaSerializerException {
  -        
  -        Element importEl = createNewElement(doc, "import", 
  -											schema.schema_ns_prefix, schema.SCHEMA_NS);
  +    Element serializeImport(Document doc, XmlSchemaImport importObj,
  +                            XmlSchema schema, boolean serializeIncluded)
  +            throws XmlSchemaSerializerException {
  +
  +        Element importEl = createNewElement(doc, "import",
  +                                            schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if (importObj.namespace != null)
  +            importEl.setAttributeNS(schema.SCHEMA_NS, "namespace",
  +                                    importObj.namespace);
  +
  +        if (importObj.schemaLocation != null && !importObj.schemaLocation.trim().equals(""))
  +            importEl.setAttributeNS(schema.SCHEMA_NS, "schemaLocation",
  +                                    importObj.schemaLocation);
   
  -        if(importObj.namespace != null)
  -            importEl.setAttributeNS(schema.SCHEMA_NS, "namespace", 
  -									importObj.namespace);
  -        
  -        if(importObj.schemaLocation != null && !importObj.schemaLocation.trim().equals(""))
  -            importEl.setAttributeNS(schema.SCHEMA_NS, "schemaLocation", 
  -									importObj.schemaLocation);
  -
  -        if(importObj.id != null)
  +        if (importObj.id != null)
               importEl.setAttributeNS(schema.SCHEMA_NS, "id", importObj.id);
  -        
  -        if(importObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 importObj.annotation, schema);
  -            
  +
  +        if (importObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     importObj.annotation, schema);
  +
               importEl.appendChild(annotation);
           }
   
  -        if(importObj.schema != null&& serializeIncluded ){
  -            
  -            
  +        if (importObj.schema != null && serializeIncluded) {
  +
  +
               XmlSchemaSerializer importSeri = new XmlSchemaSerializer();
  -            importSeri.serializeSchemaElement(importObj.schema,serializeIncluded);
  +            importSeri.serializeSchemaElement(importObj.schema, serializeIncluded);
               docs.addAll(importSeri.docs);
           }
  -        
  +
           return importEl;
       }
  -    
  +
       /************************************************************************
        * Element serializeRedefine(Document doc, XmlSchemaRedefine redefineObj, 
        *      XmlSchema schema)throws XmlSchemaSerializerException  
  @@ -415,129 +464,127 @@
        * Return:
        * Element object representation of XmlSchemaRedefine
        ************************************************************************/
  -    Element serializeRedefine(Document doc, XmlSchemaRedefine redefineObj, 
  -							  XmlSchema schema)throws XmlSchemaSerializerException {
  +    Element serializeRedefine(Document doc, XmlSchemaRedefine redefineObj,
  +                              XmlSchema schema) throws XmlSchemaSerializerException {
   
  -        Element redefine = createNewElement(doc, "redefine", 
  -											schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        
  -        if(redefineObj.schemaLocation != null)
  -            redefine.setAttributeNS(schema.SCHEMA_NS, "schemaLocation", 
  -									redefineObj.schemaLocation);
  +        Element redefine = createNewElement(doc, "redefine",
  +                                            schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if (redefineObj.schemaLocation != null)
  +            redefine.setAttributeNS(schema.SCHEMA_NS, "schemaLocation",
  +                                    redefineObj.schemaLocation);
           else
               throw new XmlSchemaSerializerException("redefine must have "
  -												   + "schemaLocation fields fill");
  +                                                   + "schemaLocation fields fill");
   
  -        if(redefineObj.id != null)
  +        if (redefineObj.id != null)
               redefine.setAttributeNS(schema.SCHEMA_NS, "id", redefineObj.id);
  -        
  -        if(redefineObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 redefineObj.annotation, schema);
  +
  +        if (redefineObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     redefineObj.annotation, schema);
               redefine.appendChild(annotation);
           }
           int itemsLength = redefineObj.items.getCount();
  -        for(int i=0;i<itemsLength;i++){
  +        for (int i = 0; i < itemsLength; i++) {
               XmlSchemaObject obj = redefineObj.items.getItem(i);
  -            if(obj instanceof XmlSchemaSimpleType){
  -                Element simpleType = serializeSimpleType(doc, 
  -														 (XmlSchemaSimpleType)obj, schema);
  +            if (obj instanceof XmlSchemaSimpleType) {
  +                Element simpleType = serializeSimpleType(doc,
  +                                                         (XmlSchemaSimpleType) obj, schema);
                   redefine.appendChild(simpleType);
  -            }else if(obj instanceof XmlSchemaComplexType){
  -                Element complexType = serializeComplexType(doc, 
  -														   (XmlSchemaComplexType)obj, schema);
  +            } else if (obj instanceof XmlSchemaComplexType) {
  +                Element complexType = serializeComplexType(doc,
  +                                                           (XmlSchemaComplexType) obj, schema);
                   redefine.appendChild(complexType);
  -            }else if(obj instanceof XmlSchemaGroupRef){
  -                Element groupRef = serializeGroupRef(doc, 
  -													 (XmlSchemaGroupRef)obj, schema);
  +            } else if (obj instanceof XmlSchemaGroupRef) {
  +                Element groupRef = serializeGroupRef(doc,
  +                                                     (XmlSchemaGroupRef) obj, schema);
                   redefine.appendChild(groupRef);
  -            }else if(obj instanceof XmlSchemaGroup){
  -                Element group = serializeGroup(doc, 
  -											   (XmlSchemaGroup)obj, schema);
  +            } else if (obj instanceof XmlSchemaGroup) {
  +                Element group = serializeGroup(doc,
  +                                               (XmlSchemaGroup) obj, schema);
                   redefine.appendChild(group);
  -            }else if(obj instanceof XmlSchemaAttributeGroup){
  -                Element attributeGroup = serializeAttributeGroup(doc, 
  -																 (XmlSchemaAttributeGroup)obj, schema);
  +            } else if (obj instanceof XmlSchemaAttributeGroup) {
  +                Element attributeGroup = serializeAttributeGroup(doc,
  +                                                                 (XmlSchemaAttributeGroup) obj, schema);
                   redefine.appendChild(attributeGroup);
  -            }else if(obj instanceof XmlSchemaAttributeGroupRef){
  -                Element attributeGroupRef = serializeAttributeGroupRef(doc, 
  -																	   (XmlSchemaAttributeGroupRef)obj, schema);
  +            } else if (obj instanceof XmlSchemaAttributeGroupRef) {
  +                Element attributeGroupRef = serializeAttributeGroupRef(doc,
  +                                                                       (XmlSchemaAttributeGroupRef) obj, schema);
                   redefine.appendChild(attributeGroupRef);
               }
           }
           return redefine;
       }
  -    
  +
       /************************************************************************
  -	 * Element serializeElement(Document doc, XmlSchemaElement elementObj, 
  -	 *   XmlSchema schema) throws XmlSchemaSerializerException
  -	 *
  -	 * Each member of Element will be appended and pass the element
  -	 * created.  Element processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc           - Document the parent use.
  -	 * elementObj   - XmlSchemaInclude that will be serialized.
  -	 * schema        - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element object of element.
  -	 ************************************************************************/
  -    Element serializeElement(Document doc, XmlSchemaElement elementObj, 
  -							 XmlSchema schema) throws XmlSchemaSerializerException{
  -        Element serializedEl = createNewElement(doc, "element" , 
  -												schema.schema_ns_prefix ,schema.SCHEMA_NS);
  +     * Element serializeElement(Document doc, XmlSchemaElement elementObj, 
  +     *   XmlSchema schema) throws XmlSchemaSerializerException
  +     *
  +     * Each member of Element will be appended and pass the element
  +     * created.  Element processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc           - Document the parent use.
  +     * elementObj   - XmlSchemaInclude that will be serialized.
  +     * schema        - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element object of element.
  +     ************************************************************************/
  +    Element serializeElement(Document doc, XmlSchemaElement elementObj,
  +                             XmlSchema schema) throws XmlSchemaSerializerException {
  +        Element serializedEl = createNewElement(doc, "element",
  +                                                schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +
  +        if (elementObj.refName != null) {
   
  -        
  -        if(elementObj.refName != null){
  -            
               String resolvedName = resolveQualifiedName(
  -													   elementObj.refName, schema);
  +                    elementObj.refName, schema);
               serializedEl.setAttributeNS(schema.SCHEMA_NS, "ref", resolvedName);
  +        } else if (elementObj.name != null && elementObj.name.length() > 0) {
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "name",
  +                                        elementObj.name);
           }
  -        
  -        else if(elementObj.name != null && elementObj.name.length() > 0){
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS, "name", 
  -										elementObj.name);
  -        }
  -        
  -        if(elementObj.isAbstract)
  +
  +        if (elementObj.isAbstract)
               serializedEl.setAttributeNS(schema.SCHEMA_NS, "abstract", "true");
   
  -        String block =elementObj.block.getValue(); 
  -        if(!block.equals("None")){
  +        String block = elementObj.block.getValue();
  +        if (!block.equals("None")) {
               block = convertString(block);
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS,"block",block);
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "block", block);
           }
  -        if(elementObj.defaultValue != null)
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS,"default",
  -										elementObj.defaultValue);
  +        if (elementObj.defaultValue != null)
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "default",
  +                                        elementObj.defaultValue);
   
  -        String finalDerivation = elementObj.finalDerivation.getValue(); 
  -        if(!finalDerivation.equals("None")){
  +        String finalDerivation = elementObj.finalDerivation.getValue();
  +        if (!finalDerivation.equals("None")) {
               finalDerivation = convertString(finalDerivation);
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS,"final",
  -										finalDerivation);
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "final",
  +                                        finalDerivation);
           }
  -        if(elementObj.fixedValue!=null)
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS,"fixed",
  -										elementObj.fixedValue);
  +        if (elementObj.fixedValue != null)
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "fixed",
  +                                        elementObj.fixedValue);
   
           String formDef = elementObj.form.getValue();
  -        if(!formDef.equals("None")){
  +        if (!formDef.equals("None")) {
               formDef = convertString(formDef);
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS,"form",formDef);
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "form", formDef);
           }
  -        if(elementObj.id != null)
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS,"id",elementObj.id);
  +        if (elementObj.id != null)
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "id", elementObj.id);
   
  -        if(elementObj.maxOccurs < Long.MAX_VALUE && elementObj.maxOccurs > 1)
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS, "maxOccurs", 
  -										elementObj.maxOccurs +"");
  -        else if(elementObj.maxOccurs == Long.MAX_VALUE)
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS, "maxOccurs", 
  -										"unbounded");
  +        if (elementObj.maxOccurs < Long.MAX_VALUE && elementObj.maxOccurs > 1)
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "maxOccurs",
  +                                        elementObj.maxOccurs + "");
  +        else if (elementObj.maxOccurs == Long.MAX_VALUE)
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "maxOccurs",
  +                                        "unbounded");
           //else not serialized
           
           /*if(elementObj.minOccurs >1)
  @@ -546,12 +593,12 @@
           
           //Change - SK and Ragu cos it wasnt picking up
           // minOccurs = 0
  -        if(elementObj.minOccurs < Long.MAX_VALUE && elementObj.minOccurs != 1)
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS, "minOccurs", 
  -										elementObj.minOccurs +"");
  -        else if(elementObj.minOccurs == Long.MAX_VALUE)
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS, "minOccurs", 
  -										"unbounded");
  +        if (elementObj.minOccurs < Long.MAX_VALUE && elementObj.minOccurs != 1)
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "minOccurs",
  +                                        elementObj.minOccurs + "");
  +        else if (elementObj.minOccurs == Long.MAX_VALUE)
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "minOccurs",
  +                                        "unbounded");
               
           /*
   		  if(elementObj.maxOccursString != null)
  @@ -565,100 +612,100 @@
   		  serializedEl.setAttributeNS(schema.SCHEMA_NS, "minOccurs", 
   		  elementObj.minOccurs + "");
   		*/
  -        if(elementObj.substitutionGroup != null){
  +        if (elementObj.substitutionGroup != null) {
               String resolvedQName = resolveQualifiedName(
  -														elementObj.substitutionGroup, schema);
  -            serializedEl.setAttributeNS(schema.SCHEMA_NS, "substitutionGroup", 
  -										resolvedQName);
  +                    elementObj.substitutionGroup, schema);
  +            serializedEl.setAttributeNS(schema.SCHEMA_NS, "substitutionGroup",
  +                                        resolvedQName);
           }
  -        if(elementObj.schemaTypeName  != null){
  +        if (elementObj.schemaTypeName != null) {
               String resolvedName = resolveQualifiedName(
  -													   elementObj.schemaTypeName, schema);
  +                    elementObj.schemaTypeName, schema);
               serializedEl.setAttributeNS(schema.SCHEMA_NS, "type", resolvedName);
           }
  -        if(elementObj.annotation != null){
  -            Element annotationEl = serializeAnnotation(doc, 
  -													   elementObj.annotation, schema);
  +        if (elementObj.annotation != null) {
  +            Element annotationEl = serializeAnnotation(doc,
  +                                                       elementObj.annotation, schema);
               serializedEl.appendChild(annotationEl);
           }
  -        if(elementObj.schemaType != null){
  -            if(elementObj.schemaType instanceof XmlSchemaComplexType){
  -                Element complexType  = serializeComplexType(doc, 
  -															(XmlSchemaComplexType)elementObj.schemaType, schema);
  +        if (elementObj.schemaType != null) {
  +            if (elementObj.schemaType instanceof XmlSchemaComplexType) {
  +                Element complexType = serializeComplexType(doc,
  +                                                           (XmlSchemaComplexType) elementObj.schemaType, schema);
                   serializedEl.appendChild(complexType);
  -            }else if(elementObj.schemaType instanceof XmlSchemaSimpleType){
  -                Element simpleType  = serializeSimpleType(doc, 
  -														  (XmlSchemaSimpleType)elementObj.schemaType, schema);
  +            } else if (elementObj.schemaType instanceof XmlSchemaSimpleType) {
  +                Element simpleType = serializeSimpleType(doc,
  +                                                         (XmlSchemaSimpleType) elementObj.schemaType, schema);
                   serializedEl.appendChild(simpleType);
               }
           }
  -        if(elementObj.constraints.getCount() > 0){
  -            for(int i=0; i<elementObj.constraints.getCount();i++){
  -                Element constraint = serializeIdentityConstraint(doc, 
  -																 (XmlSchemaIdentityConstraint)elementObj.constraints.getItem(i), 
  -																 schema);
  +        if (elementObj.constraints.getCount() > 0) {
  +            for (int i = 0; i < elementObj.constraints.getCount(); i++) {
  +                Element constraint = serializeIdentityConstraint(doc,
  +                                                                 (XmlSchemaIdentityConstraint) elementObj.constraints.getItem(i),
  +                                                                 schema);
                   serializedEl.appendChild(constraint);
               }
           }
   
           return serializedEl;
       }
  -    
  +
       /************************************************************************
  -	 * Element serializeSimpleType(Document doc, 
  -	 *    XmlSchemaSimpleType simpleTypeObj, XmlSchema schema) 
  -	 *    throws XmlSchemaSerializerException{
  -	 *
  -	 * Each member of simple type will be appended and pass the element
  -	 * created.  Simple type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc               - Document the parent use.
  -	 * simpleTypeObj     - XmlSchemaSimpleType that will be serialized.
  -	 * schema            - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element object of SimpleType
  -	 ************************************************************************/
  -    Element serializeSimpleType(Document doc, XmlSchemaSimpleType simpleTypeObj, 
  -								XmlSchema schema) throws XmlSchemaSerializerException{
  -        
  -		Element serializedSimpleType = createNewElement(doc, "simpleType",
  -														schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        
  -        
  +     * Element serializeSimpleType(Document doc, 
  +     *    XmlSchemaSimpleType simpleTypeObj, XmlSchema schema) 
  +     *    throws XmlSchemaSerializerException{
  +     *
  +     * Each member of simple type will be appended and pass the element
  +     * created.  Simple type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc               - Document the parent use.
  +     * simpleTypeObj     - XmlSchemaSimpleType that will be serialized.
  +     * schema            - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element object of SimpleType
  +     ************************************************************************/
  +    Element serializeSimpleType(Document doc, XmlSchemaSimpleType simpleTypeObj,
  +                                XmlSchema schema) throws XmlSchemaSerializerException {
  +
  +        Element serializedSimpleType = createNewElement(doc, "simpleType",
  +                                                        schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +
           String tmp;
           tmp = simpleTypeObj.finalDerivation.getValue();
  -        if(!tmp.equals("None")){
  +        if (!tmp.equals("None")) {
   
               tmp = convertString(tmp);
               serializedSimpleType.setAttributeNS(schema.SCHEMA_NS, "final", tmp);
           }
  -        if(simpleTypeObj.id != null)
  -            serializedSimpleType.setAttributeNS(schema.SCHEMA_NS, "id", 
  -												simpleTypeObj.id);
  -        if((simpleTypeObj.name != null)&&(!simpleTypeObj.name.equals("")))
  -            serializedSimpleType.setAttributeNS(schema.SCHEMA_NS, "name", 
  -												simpleTypeObj.name);
  -        if(simpleTypeObj.annotation != null){
  -            Element annotationEl = serializeAnnotation(doc, 
  -													   simpleTypeObj.annotation, schema);
  +        if (simpleTypeObj.id != null)
  +            serializedSimpleType.setAttributeNS(schema.SCHEMA_NS, "id",
  +                                                simpleTypeObj.id);
  +        if ((simpleTypeObj.name != null) && (!simpleTypeObj.name.equals("")))
  +            serializedSimpleType.setAttributeNS(schema.SCHEMA_NS, "name",
  +                                                simpleTypeObj.name);
  +        if (simpleTypeObj.annotation != null) {
  +            Element annotationEl = serializeAnnotation(doc,
  +                                                       simpleTypeObj.annotation, schema);
               serializedSimpleType.appendChild(annotationEl);
           }
  -        if(simpleTypeObj.content != null){
  -            if(simpleTypeObj.content instanceof XmlSchemaSimpleTypeRestriction){
  -                Element restEl = serializeSimpleTypeRestriction(doc, 
  -																(XmlSchemaSimpleTypeRestriction)simpleTypeObj.content, 
  -																schema);
  +        if (simpleTypeObj.content != null) {
  +            if (simpleTypeObj.content instanceof XmlSchemaSimpleTypeRestriction) {
  +                Element restEl = serializeSimpleTypeRestriction(doc,
  +                                                                (XmlSchemaSimpleTypeRestriction) simpleTypeObj.content,
  +                                                                schema);
                   serializedSimpleType.appendChild(restEl);
  -            }else if(simpleTypeObj.content instanceof XmlSchemaSimpleTypeList){
  -                Element listEl = serializeSimpleTypeList(doc, 
  -														 (XmlSchemaSimpleTypeList)simpleTypeObj.content, schema);
  +            } else if (simpleTypeObj.content instanceof XmlSchemaSimpleTypeList) {
  +                Element listEl = serializeSimpleTypeList(doc,
  +                                                         (XmlSchemaSimpleTypeList) simpleTypeObj.content, schema);
                   serializedSimpleType.appendChild(listEl);
  -            }else if(simpleTypeObj.content instanceof XmlSchemaSimpleTypeUnion){
  -                Element unionEl = serializeSimpleTypeUnion(doc, 
  -														   (XmlSchemaSimpleTypeUnion)simpleTypeObj.content, schema);
  +            } else if (simpleTypeObj.content instanceof XmlSchemaSimpleTypeUnion) {
  +                Element unionEl = serializeSimpleTypeUnion(doc,
  +                                                           (XmlSchemaSimpleTypeUnion) simpleTypeObj.content, schema);
                   serializedSimpleType.appendChild(unionEl);
               }/*else 
   			   throw new XmlSchemaSerializerException("Invalid type inserted "
  @@ -672,480 +719,482 @@
           
           return serializedSimpleType;
       }
  -    
  +
       /************************************************************************
  -	 * Element serializeSimpleTypeRestriction(Document doc, 
  -	 *    XmlSchemaSimpleTypeRestriction restrictionObj, XmlSchema schema) 
  -	 *    throws XmlSchemaSerializerException{
  -	 *
  -	 * Each member of simple type will be appended and pass the element
  -	 * created.  Simple type's <restriction> processed according to w3c 
  -	 * Recommendation May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc               - Document the parent use.
  -	 * restrictionObj    - XmlSchemaRestriction that will be serialized.
  -	 * schema            - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of simple type restriction and its child.
  -	 ************************************************************************/
  -    Element serializeSimpleTypeRestriction(Document doc, 
  -										   XmlSchemaSimpleTypeRestriction restrictionObj, XmlSchema schema) 
  -        throws XmlSchemaSerializerException{
  +     * Element serializeSimpleTypeRestriction(Document doc, 
  +     *    XmlSchemaSimpleTypeRestriction restrictionObj, XmlSchema schema) 
  +     *    throws XmlSchemaSerializerException{
  +     *
  +     * Each member of simple type will be appended and pass the element
  +     * created.  Simple type's <restriction> processed according to w3c 
  +     * Recommendation May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc               - Document the parent use.
  +     * restrictionObj    - XmlSchemaRestriction that will be serialized.
  +     * schema            - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of simple type restriction and its child.
  +     ************************************************************************/
  +    Element serializeSimpleTypeRestriction(Document doc,
  +                                           XmlSchemaSimpleTypeRestriction restrictionObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
           //todo: need to implement any attribute that related to non schema namespace
  -        Element serializedRestriction = createNewElement(doc, "restriction" , 
  -														 schema.schema_ns_prefix ,schema.SCHEMA_NS);
  +        Element serializedRestriction = createNewElement(doc, "restriction",
  +                                                         schema.schema_ns_prefix, schema.SCHEMA_NS);
   
  -        if(schema.schema_ns_prefix.length()>0)
  +        if (schema.schema_ns_prefix.length() > 0)
               serializedRestriction.setPrefix(schema.schema_ns_prefix);
  -        if(restrictionObj.baseTypeName != null){
  +        if (restrictionObj.baseTypeName != null) {
               String baseType = resolveQualifiedName(restrictionObj.baseTypeName, schema);
  -            serializedRestriction.setAttributeNS(schema.SCHEMA_NS, "base",baseType);
  -        }else if(restrictionObj.baseType != null && restrictionObj.baseType
  -				 instanceof XmlSchemaSimpleType){
  -            Element inlineSimpleType = serializeSimpleType(doc, 
  -														   (XmlSchemaSimpleType)restrictionObj.baseType, schema);
  +            serializedRestriction.setAttributeNS(schema.SCHEMA_NS, "base", baseType);
  +        } else if (restrictionObj.baseType != null && restrictionObj.baseType
  +                instanceof XmlSchemaSimpleType) {
  +            Element inlineSimpleType = serializeSimpleType(doc,
  +                                                           (XmlSchemaSimpleType) restrictionObj.baseType, schema);
               serializedRestriction.appendChild(inlineSimpleType);
  -        }else 
  +        } else
               throw new XmlSchemaSerializerException("restriction must be define "
  -												   + "with specifying base or inline simpleType");
  -            
  -        if(restrictionObj.id != null)
  -            serializedRestriction.setAttributeNS(schema.SCHEMA_NS, "id", 
  -												 restrictionObj.id);
  -       
  -        if(restrictionObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 restrictionObj.annotation, schema);
  +                                                   + "with specifying base or inline simpleType");
  +
  +        if (restrictionObj.id != null)
  +            serializedRestriction.setAttributeNS(schema.SCHEMA_NS, "id",
  +                                                 restrictionObj.id);
  +
  +        if (restrictionObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     restrictionObj.annotation, schema);
               serializedRestriction.appendChild(annotation);
           }
  -        if(restrictionObj.facets.getCount() >0){
  -            int facetsNum =restrictionObj.facets.getCount(); 
  -            for(int i=0;i<facetsNum;i++){
  -                Element facetEl = serializeFacet(doc, 
  -												 (XmlSchemaFacet)restrictionObj.facets.getItem(i), schema);
  +        if (restrictionObj.facets.getCount() > 0) {
  +            int facetsNum = restrictionObj.facets.getCount();
  +            for (int i = 0; i < facetsNum; i++) {
  +                Element facetEl = serializeFacet(doc,
  +                                                 (XmlSchemaFacet) restrictionObj.facets.getItem(i), schema);
                   serializedRestriction.appendChild(facetEl);
               }
           }
           return serializedRestriction;
  -    }    
  +    }
  +
       /************************************************************************
  -	 * Element serializeFacet(Document doc, XmlSchemaFacet facetObj, 
  -	 *   XmlSchema schema) throws XmlSchemaSerializerException{
  -	 *
  -	 * detect what type of facet and cass appropriatelly, 
  -	 * construct the element and pass it.
  -	 *
  -	 * Parameter:
  -	 * doc       - Document the parent use.
  -	 * facetObj  - XmlSchemaFacet that will be serialized.
  -	 * schema    - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of simple type with facet.
  -	 ************************************************************************/
  -    Element serializeFacet(Document doc, XmlSchemaFacet facetObj, 
  -						   XmlSchema schema) throws XmlSchemaSerializerException{
  -        
  +     * Element serializeFacet(Document doc, XmlSchemaFacet facetObj, 
  +     *   XmlSchema schema) throws XmlSchemaSerializerException{
  +     *
  +     * detect what type of facet and cass appropriatelly, 
  +     * construct the element and pass it.
  +     *
  +     * Parameter:
  +     * doc       - Document the parent use.
  +     * facetObj  - XmlSchemaFacet that will be serialized.
  +     * schema    - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of simple type with facet.
  +     ************************************************************************/
  +    Element serializeFacet(Document doc, XmlSchemaFacet facetObj,
  +                           XmlSchema schema) throws XmlSchemaSerializerException {
  +
           Element serializedFacet;
           String facetName = facetObj.getClass().getName();
  -        
  -        if(facetObj instanceof XmlSchemaMinExclusiveFacet)
  -            serializedFacet = constructFacet(facetObj, doc,schema, 
  -											 "minExclusive");
  -        else if(facetObj instanceof  XmlSchemaMinInclusiveFacet)
  -            serializedFacet = constructFacet(facetObj, doc,schema, 
  -											 "minInclusive");
  -        else if(facetObj instanceof XmlSchemaMaxExclusiveFacet)
  -            serializedFacet = constructFacet(facetObj, doc,schema, 
  -											 "maxExclusive");
  -        else if(facetObj instanceof XmlSchemaMaxInclusiveFacet)   
  -            serializedFacet = constructFacet(facetObj, doc,schema, 
  -											 "maxInclusive");
  -        else if(facetObj instanceof XmlSchemaTotalDigitsFacet)
  -            serializedFacet = constructFacet(facetObj, doc,schema, 
  -											 "totalDigits");
  -        else if(facetObj instanceof XmlSchemaFractionDigitsFacet)
  -            serializedFacet = constructFacet(facetObj, doc,schema, 
  -											 "fractionDigits");
  -        else if(facetObj instanceof XmlSchemaLengthFacet)
  -            serializedFacet = constructFacet(facetObj, doc,schema, 
  -											 "length");
  -        else if(facetObj instanceof XmlSchemaMinLengthFacet)
  -            serializedFacet = constructFacet(facetObj, doc,schema, 
  -											 "minLength");
  -        else if(facetObj instanceof XmlSchemaMaxLengthFacet)
  -            serializedFacet = constructFacet(facetObj, doc,schema,
  -											 "maxLength");
  -        else if(facetObj instanceof XmlSchemaEnumerationFacet)
  -            serializedFacet = constructFacet(facetObj, doc,schema, 
  -											 "enumeration");
  -        else if(facetObj instanceof  XmlSchemaWhiteSpaceFacet)
  -            serializedFacet = constructFacet(facetObj, doc,schema, 
  -											 "whiteSpace");
  -        else if(facetObj instanceof XmlSchemaPatternFacet)
  -            serializedFacet = constructFacet(facetObj, doc,schema, 
  -											 "pattern");
  +
  +        if (facetObj instanceof XmlSchemaMinExclusiveFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "minExclusive");
  +        else if (facetObj instanceof XmlSchemaMinInclusiveFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "minInclusive");
  +        else if (facetObj instanceof XmlSchemaMaxExclusiveFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "maxExclusive");
  +        else if (facetObj instanceof XmlSchemaMaxInclusiveFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "maxInclusive");
  +        else if (facetObj instanceof XmlSchemaTotalDigitsFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "totalDigits");
  +        else if (facetObj instanceof XmlSchemaFractionDigitsFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "fractionDigits");
  +        else if (facetObj instanceof XmlSchemaLengthFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "length");
  +        else if (facetObj instanceof XmlSchemaMinLengthFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "minLength");
  +        else if (facetObj instanceof XmlSchemaMaxLengthFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "maxLength");
  +        else if (facetObj instanceof XmlSchemaEnumerationFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "enumeration");
  +        else if (facetObj instanceof XmlSchemaWhiteSpaceFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "whiteSpace");
  +        else if (facetObj instanceof XmlSchemaPatternFacet)
  +            serializedFacet = constructFacet(facetObj, doc, schema,
  +                                             "pattern");
           else
  -            throw new XmlSchemaSerializerException("facet not exist " 
  -												   + facetObj.getClass().getName() );
  -    
  -        if(facetObj.id != null)
  +            throw new XmlSchemaSerializerException("facet not exist "
  +                                                   + facetObj.getClass().getName());
  +
  +        if (facetObj.id != null)
               serializedFacet.setAttributeNS(schema.SCHEMA_NS, "id", facetObj.id);
  -        if(facetObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, facetObj.annotation, 
  -													 schema);
  +        if (facetObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc, facetObj.annotation,
  +                                                     schema);
               serializedFacet.appendChild(annotation);
           }
  -             
  +
           return serializedFacet;
       }
  -    
  -    private Element constructFacet(XmlSchemaFacet facetObj, Document doc, 
  -								   XmlSchema schema, String tagName){
  -            
  -        Element facetEl = createNewElement(doc, tagName , 
  -										   schema.schema_ns_prefix ,schema.SCHEMA_NS);
   
  -        facetEl.setAttributeNS(schema.SCHEMA_NS, "value", 
  -							   facetObj.value.toString());
  -        if(facetObj.fixed)
  +    private Element constructFacet(XmlSchemaFacet facetObj, Document doc,
  +                                   XmlSchema schema, String tagName) {
  +
  +        Element facetEl = createNewElement(doc, tagName,
  +                                           schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        facetEl.setAttributeNS(schema.SCHEMA_NS, "value",
  +                               facetObj.value.toString());
  +        if (facetObj.fixed)
               facetEl.setAttributeNS(schema.SCHEMA_NS, "fixed", "true");
  -        
  -        if(facetObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 facetObj.annotation,  schema);
  +
  +        if (facetObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     facetObj.annotation, schema);
               facetEl.appendChild(annotation);
           }
           return facetEl;
       }
  -    
  +
       /************************************************************************
  -	 * Element serializeComplexType(Document doc, 
  -	 *    XmlSchemaComplexType complexTypeObj, XmlSchema schema) 
  -	 *    throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc             - Document the parent use.
  -	 * complexTypeObj  - XmlSchemaFacet that will be serialized.
  -	 * schema          - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of complexType.
  -	 ************************************************************************/
  -    Element serializeComplexType(Document doc, 
  -								 XmlSchemaComplexType complexTypeObj, XmlSchema schema) 
  -        throws XmlSchemaSerializerException{
  -        
  +     * Element serializeComplexType(Document doc, 
  +     *    XmlSchemaComplexType complexTypeObj, XmlSchema schema) 
  +     *    throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc             - Document the parent use.
  +     * complexTypeObj  - XmlSchemaFacet that will be serialized.
  +     * schema          - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of complexType.
  +     ************************************************************************/
  +    Element serializeComplexType(Document doc,
  +                                 XmlSchemaComplexType complexTypeObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
  +
           //todo: need to implement abstract, id, mixed
  -        Element serializedComplexType = createNewElement(doc , 
  -														 "complexType", schema.schema_ns_prefix, schema.SCHEMA_NS  );
  -        
  -        if ((complexTypeObj.name != null)&&(!complexTypeObj.name.equals("")))
  -            serializedComplexType.setAttributeNS(schema.SCHEMA_NS, "name", 
  -												 complexTypeObj.name);
  +        Element serializedComplexType = createNewElement(doc,
  +                                                         "complexType", schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if ((complexTypeObj.name != null) && (!complexTypeObj.name.equals("")))
  +            serializedComplexType.setAttributeNS(schema.SCHEMA_NS, "name",
  +                                                 complexTypeObj.name);
           /*if(complexTypeObj.annotation != null){
   		  Element annotationEl = serializeAnnotation(doc, 
   		  complexTypeObj.annotation, schema);
   		  serializedComplexType.appendChild(annotationEl);
   		  }*/
           
  -        if(complexTypeObj.isMixed)
  -            serializedComplexType.setAttributeNS(schema.SCHEMA_NS, 
  -												 "mixed", "true");
  -        if(complexTypeObj.isAbstract)
  -            serializedComplexType.setAttributeNS(schema.SCHEMA_NS, 
  -												 "abstract", "true");
  -        if(complexTypeObj.id != null)
  -            serializedComplexType.setAttributeNS(schema.SCHEMA_NS, "id", 
  -												 complexTypeObj.id);      
  -            
  -        if(complexTypeObj.contentModel instanceof XmlSchemaSimpleContent){
  -            Element simpleContent = serializeSimpleContent(doc, 
  -														   (XmlSchemaSimpleContent)complexTypeObj.contentModel, schema);
  +        if (complexTypeObj.isMixed)
  +            serializedComplexType.setAttributeNS(schema.SCHEMA_NS,
  +                                                 "mixed", "true");
  +        if (complexTypeObj.isAbstract)
  +            serializedComplexType.setAttributeNS(schema.SCHEMA_NS,
  +                                                 "abstract", "true");
  +        if (complexTypeObj.id != null)
  +            serializedComplexType.setAttributeNS(schema.SCHEMA_NS, "id",
  +                                                 complexTypeObj.id);
  +
  +        if (complexTypeObj.contentModel instanceof XmlSchemaSimpleContent) {
  +            Element simpleContent = serializeSimpleContent(doc,
  +                                                           (XmlSchemaSimpleContent) complexTypeObj.contentModel, schema);
               serializedComplexType.appendChild(simpleContent);
  -        }else if(complexTypeObj.contentModel instanceof 
  -				 XmlSchemaComplexContent){
  -            
  -            Element complexContent = serializeComplexContent(doc, 
  -															 (XmlSchemaComplexContent)complexTypeObj.contentModel, schema);
  +        } else if (complexTypeObj.contentModel instanceof
  +                XmlSchemaComplexContent) {
  +
  +            Element complexContent = serializeComplexContent(doc,
  +                                                             (XmlSchemaComplexContent) complexTypeObj.contentModel, schema);
               serializedComplexType.appendChild(complexContent);
           }
   
  -        if(complexTypeObj.particle instanceof XmlSchemaSequence){
  -            Element sequence = serializeSequence(doc, 
  -												 (XmlSchemaSequence)complexTypeObj.particle, schema);
  +        if (complexTypeObj.particle instanceof XmlSchemaSequence) {
  +            Element sequence = serializeSequence(doc,
  +                                                 (XmlSchemaSequence) complexTypeObj.particle, schema);
               serializedComplexType.appendChild(sequence);
  -        }else if(complexTypeObj.particle instanceof XmlSchemaChoice){
  -            Element choice = serializeChoice(doc, 
  -											 (XmlSchemaChoice)complexTypeObj.particle, schema);
  +        } else if (complexTypeObj.particle instanceof XmlSchemaChoice) {
  +            Element choice = serializeChoice(doc,
  +                                             (XmlSchemaChoice) complexTypeObj.particle, schema);
               serializedComplexType.appendChild(choice);
  -        }else if(complexTypeObj.particle instanceof XmlSchemaAll){
  -            Element all = serializeAll(doc, 
  -									   (XmlSchemaAll)complexTypeObj.particle, schema);
  +        } else if (complexTypeObj.particle instanceof XmlSchemaAll) {
  +            Element all = serializeAll(doc,
  +                                       (XmlSchemaAll) complexTypeObj.particle, schema);
               serializedComplexType.appendChild(all);
  -        }else if(complexTypeObj.particle instanceof XmlSchemaGroupRef){
  -            Element group = serializeGroupRef(doc, 
  -											  (XmlSchemaGroupRef)complexTypeObj.particle, schema);
  +        } else if (complexTypeObj.particle instanceof XmlSchemaGroupRef) {
  +            Element group = serializeGroupRef(doc,
  +                                              (XmlSchemaGroupRef) complexTypeObj.particle, schema);
               serializedComplexType.appendChild(group);
           }
  -        
  +
           String block = complexTypeObj.block.getValue();
  -        if(!block.equals("None")){
  +        if (!block.equals("None")) {
               block = convertString(block);
  -            serializedComplexType.setAttributeNS(schema.SCHEMA_NS, 
  -												 "block", block);
  +            serializedComplexType.setAttributeNS(schema.SCHEMA_NS,
  +                                                 "block", block);
           }
           String finalDerivation = complexTypeObj.finalDerivation.getValue();
  -        if(!finalDerivation.equals("None")){
  +        if (!finalDerivation.equals("None")) {
               finalDerivation = convertString(finalDerivation);
  -            serializedComplexType.setAttributeNS(schema.SCHEMA_NS, "final", 
  -												 finalDerivation);
  +            serializedComplexType.setAttributeNS(schema.SCHEMA_NS, "final",
  +                                                 finalDerivation);
           }
  -        
  +
           XmlSchemaObjectCollection attrColl = complexTypeObj.attributes;
  -        if(attrColl.getCount() > 0)
  -            setupAttr(doc, attrColl, schema,serializedComplexType);
  -        
  +        if (attrColl.getCount() > 0)
  +            setupAttr(doc, attrColl, schema, serializedComplexType);
  +
           return serializedComplexType;
  -    } 
  -    
  +    }
  +
       /************************************************************************
  -	 * Element serializeSequence(Document doc, XmlSchemaSequence sequenceObj, 
  -	 *    XmlSchema schema)throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  `Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc             - Document the parent use.
  -	 * sequenceObj  - XmlSchemaFacet that will be serialized.
  -	 * schema          - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of sequence particle.
  -	 ************************************************************************/
  -    Element serializeSequence(Document doc, XmlSchemaSequence sequenceObj, 
  -							  XmlSchema schema)throws XmlSchemaSerializerException{
  -        
  -        Element sequence = createNewElement(doc, "sequence", 
  -											schema.schema_ns_prefix, schema.SCHEMA_NS);
  -       
  -        
  -        if(sequenceObj.id != null)
  +     * Element serializeSequence(Document doc, XmlSchemaSequence sequenceObj, 
  +     *    XmlSchema schema)throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  `Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc             - Document the parent use.
  +     * sequenceObj  - XmlSchemaFacet that will be serialized.
  +     * schema          - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of sequence particle.
  +     ************************************************************************/
  +    Element serializeSequence(Document doc, XmlSchemaSequence sequenceObj,
  +                              XmlSchema schema) throws XmlSchemaSerializerException {
  +
  +        Element sequence = createNewElement(doc, "sequence",
  +                                            schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +
  +        if (sequenceObj.id != null)
               sequence.setAttributeNS(schema.SCHEMA_NS, "id", sequenceObj.id);
   
  -        
  -        if(sequenceObj.maxOccurs < Long.MAX_VALUE && sequenceObj.maxOccurs > 1)
  -            sequence.setAttributeNS(schema.SCHEMA_NS, "maxOccurs", 
  -									sequenceObj.maxOccurs +"");
  -        else if(sequenceObj.maxOccurs == Long.MAX_VALUE)
  -            sequence.setAttributeNS(schema.SCHEMA_NS, "maxOccurs", 
  -									"unbounded");
  +
  +        if (sequenceObj.maxOccurs < Long.MAX_VALUE && sequenceObj.maxOccurs > 1)
  +            sequence.setAttributeNS(schema.SCHEMA_NS, "maxOccurs",
  +                                    sequenceObj.maxOccurs + "");
  +        else if (sequenceObj.maxOccurs == Long.MAX_VALUE)
  +            sequence.setAttributeNS(schema.SCHEMA_NS, "maxOccurs",
  +                                    "unbounded");
           //else not serialized
           
               
  -        if(sequenceObj.minOccurs > 1)
  -            sequence.setAttributeNS(schema.SCHEMA_NS, "minOccurs", 
  -									sequenceObj.minOccurs + "");
  -        
  +        if (sequenceObj.minOccurs > 1)
  +            sequence.setAttributeNS(schema.SCHEMA_NS, "minOccurs",
  +                                    sequenceObj.minOccurs + "");
  +
           XmlSchemaObjectCollection seqColl = sequenceObj.items;
           int containLength = seqColl.getCount();
  -        for(int i=0; i<containLength;i++){
  +        for (int i = 0; i < containLength; i++) {
               XmlSchemaObject obj = seqColl.getItem(i);
  -            if(obj instanceof XmlSchemaElement){
  -                Element el = serializeElement(doc, 
  -											  (XmlSchemaElement)obj, schema);
  +            if (obj instanceof XmlSchemaElement) {
  +                Element el = serializeElement(doc,
  +                                              (XmlSchemaElement) obj, schema);
                   sequence.appendChild(el);
  -            }else if(obj instanceof XmlSchemaGroupRef){
  -                Element group = serializeGroupRef(doc, 
  -												  (XmlSchemaGroupRef)obj, schema);
  +            } else if (obj instanceof XmlSchemaGroupRef) {
  +                Element group = serializeGroupRef(doc,
  +                                                  (XmlSchemaGroupRef) obj, schema);
                   sequence.appendChild(group);
  -            }else if(obj instanceof XmlSchemaChoice){
  -                Element choice = serializeChoice(doc, 
  -												 (XmlSchemaChoice)obj, schema);
  +            } else if (obj instanceof XmlSchemaChoice) {
  +                Element choice = serializeChoice(doc,
  +                                                 (XmlSchemaChoice) obj, schema);
                   sequence.appendChild(choice);
  -            }else if(obj instanceof XmlSchemaSequence){
  -                Element sequenceChild = serializeSequence(doc, 
  -														  (XmlSchemaSequence)obj, schema);
  +            } else if (obj instanceof XmlSchemaSequence) {
  +                Element sequenceChild = serializeSequence(doc,
  +                                                          (XmlSchemaSequence) obj, schema);
                   sequence.appendChild(sequenceChild);
  -            }else if(obj instanceof XmlSchemaAny){
  -                Element any = serializeAny(doc,(XmlSchemaAny)obj, schema);
  +            } else if (obj instanceof XmlSchemaAny) {
  +                Element any = serializeAny(doc, (XmlSchemaAny) obj, schema);
                   sequence.appendChild(any);
               }
           }
           return sequence;
       }
  +
       /************************************************************************
  -	 * Element serializeAttribute(Document doc, XmlSchemaAttribute attributeObj, 
  -	 *    XmlSchema schema) throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  `Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc             - Document the parent use.
  -	 * attributeObj    - XmlSchemaAttribute that will be serialized.
  -	 * schema          - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of attribute.
  -	 ************************************************************************/
  -    Element serializeAttribute(Document doc, XmlSchemaAttribute attributeObj, 
  -							   XmlSchema schema) throws XmlSchemaSerializerException{
  -        
  -		Element attribute = createNewElement(doc, "attribute", 
  -											 schema.schema_ns_prefix, schema.SCHEMA_NS);
  -		if(attributeObj.refName != null){
  -            String refName =  
  -                resolveQualifiedName(attributeObj.refName, schema);
  +     * Element serializeAttribute(Document doc, XmlSchemaAttribute attributeObj, 
  +     *    XmlSchema schema) throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  `Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc             - Document the parent use.
  +     * attributeObj    - XmlSchemaAttribute that will be serialized.
  +     * schema          - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of attribute.
  +     ************************************************************************/
  +    Element serializeAttribute(Document doc, XmlSchemaAttribute attributeObj,
  +                               XmlSchema schema) throws XmlSchemaSerializerException {
  +
  +        Element attribute = createNewElement(doc, "attribute",
  +                                             schema.schema_ns_prefix, schema.SCHEMA_NS);
  +        if (attributeObj.refName != null) {
  +            String refName =
  +                    resolveQualifiedName(attributeObj.refName, schema);
               attribute.setAttributeNS(schema.SCHEMA_NS, "ref", refName);
  -        }
  -        else if(attributeObj.name != null)
  -            attribute.setAttributeNS(schema.SCHEMA_NS, "name", 
  -									 attributeObj.name);
  -            
  -        if(attributeObj.schemaTypeName != null){
  -            String typeName =  
  -                resolveQualifiedName(attributeObj.schemaTypeName, schema);
  +        } else if (attributeObj.name != null)
  +            attribute.setAttributeNS(schema.SCHEMA_NS, "name",
  +                                     attributeObj.name);
  +
  +        if (attributeObj.schemaTypeName != null) {
  +            String typeName =
  +                    resolveQualifiedName(attributeObj.schemaTypeName, schema);
               attribute.setAttributeNS(schema.SCHEMA_NS, "type", typeName);
           }
  -        
  -        if(attributeObj.defaultValue != null)
  +
  +        if (attributeObj.defaultValue != null)
               attribute.setAttributeNS(schema.SCHEMA_NS, "default",
  -									 attributeObj.defaultValue);
  -        if(attributeObj.fixedValue != null)
  -            attribute.setAttributeNS(schema.SCHEMA_NS, "fixed", 
  -									 attributeObj.fixedValue);
  -        
  -        String formType = attributeObj.form.getValue(); 
  -        if(!formType.equals("None")){
  +                                     attributeObj.defaultValue);
  +        if (attributeObj.fixedValue != null)
  +            attribute.setAttributeNS(schema.SCHEMA_NS, "fixed",
  +                                     attributeObj.fixedValue);
  +
  +        String formType = attributeObj.form.getValue();
  +        if (!formType.equals("None")) {
               formType = convertString(formType);
               attribute.setAttributeNS(schema.SCHEMA_NS, "form", formType);
           }
  -        if(attributeObj.id != null)
  +        if (attributeObj.id != null)
               attribute.setAttributeNS(schema.SCHEMA_NS, "id", attributeObj.id);
  -       
  -        String useType =attributeObj.use.getValue(); 
  -        if(!useType.equals("None")){
  +
  +        String useType = attributeObj.use.getValue();
  +        if (!useType.equals("None")) {
               useType = convertString(useType);
               attribute.setAttributeNS(schema.SCHEMA_NS, "use", useType);
           }
  -        if(attributeObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 attributeObj.annotation, schema);
  +        if (attributeObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     attributeObj.annotation, schema);
               attribute.appendChild(annotation);
           }
  -        
  -        
  -        if(attributeObj.schemaType != null){
  -            try{
  -                XmlSchemaSimpleType simpleType = 
  -                    (XmlSchemaSimpleType)attributeObj.schemaType;
  -                Element simpleTypeEl = serializeSimpleType(doc, 
  -														   simpleType, schema);
  +
  +
  +        if (attributeObj.schemaType != null) {
  +            try {
  +                XmlSchemaSimpleType simpleType =
  +                        (XmlSchemaSimpleType) attributeObj.schemaType;
  +                Element simpleTypeEl = serializeSimpleType(doc,
  +                                                           simpleType, schema);
                   attribute.appendChild(simpleTypeEl);
  -            }catch(ClassCastException e){
  +            } catch (ClassCastException e) {
                   throw new XmlSchemaSerializerException(
  -													   "only inline simple type allow as attribute's inline type");
  +                        "only inline simple type allow as attribute's inline type");
               }
           }
  -		
  -		Attr[] unhandled = attributeObj.getUnhandledAttributes();
   
  -		Hashtable namespaces = new Hashtable();
  -		
  -		if (unhandled != null){
  -			
  -			// this is to make the wsdl:arrayType work 
  -			// since unhandles attributes are not handled this is a special case
  -			// but the basic idea is to see if there is any attibute whose value has ":"
  -			// if it is present then it is likely that it is a namespace prefix
  -			// do what is neccesary to get the real namespace for it and make 
  -			// required changes to the prefix 
  -			
  -			for (int i=0;i<unhandled.length;i++){ 
  -				String name = unhandled[i].getNodeName();
  -				String value = unhandled[i].getNodeValue();
  -				if(  name.equals( "xmlns") ) {
  -					namespaces.put( "", value);
  -				}else if( name.startsWith( "xmlns" )){
  -					namespaces.put( name.substring(name.indexOf(":") + 1) , value);
  -				}
  -			}
  +        Attr[] unhandled = attributeObj.getUnhandledAttributes();
  +
  +        Hashtable namespaces = new Hashtable();
  +
  +        if (unhandled != null) {
  +
  +            // this is to make the wsdl:arrayType work 
  +            // since unhandles attributes are not handled this is a special case
  +            // but the basic idea is to see if there is any attibute whose value has ":"
  +            // if it is present then it is likely that it is a namespace prefix
  +            // do what is neccesary to get the real namespace for it and make 
  +            // required changes to the prefix 
   			
  -			for (int i=0;i<unhandled.length;i++){
  -				String value = unhandled[i].getNodeValue();
  -				String nodeName = unhandled[i].getNodeName();
  -				if( value.indexOf( ":") > -1 && ! nodeName.startsWith( "xmlns") ) {
  -					String prefix = value.substring( 0, value.indexOf( ":" ));
  -					String oldNamespace = null;
  -					if(( oldNamespace =  ( String) namespaces.get( prefix )) != null) {
  -						value = value.substring( value.indexOf(":") + 1 );
  -						Hashtable realNamespaces = schema.getPrefixToNamespaceMap();
  -						java.util.Iterator iter = realNamespaces.keySet().iterator();
  -						while( iter.hasNext()){
  -							prefix = ( String) iter.next();
  -							String namespace = ( String ) realNamespaces.get( prefix );
  -							if( namespace.equals( oldNamespace)) 
  -								value = prefix + ":" + value;
  -						}
  -					}
  -					
  -				}
  -				if (unhandled[i].getNamespaceURI()!= null)
  -					attribute.setAttributeNS(unhandled[i].getNamespaceURI(),nodeName,value);
  -			    else
  -					attribute.setAttribute(nodeName,value);
  -			}
  -		}
  +            for (int i = 0; i < unhandled.length; i++) {
  +                String name = unhandled[i].getNodeName();
  +                String value = unhandled[i].getNodeValue();
  +                if (name.equals("xmlns")) {
  +                    namespaces.put("", value);
  +                } else if (name.startsWith("xmlns")) {
  +                    namespaces.put(name.substring(name.indexOf(":") + 1), value);
  +                }
  +            }
  +
  +            for (int i = 0; i < unhandled.length; i++) {
  +                String value = unhandled[i].getNodeValue();
  +                String nodeName = unhandled[i].getNodeName();
  +                if (value.indexOf(":") > -1 && !nodeName.startsWith("xmlns")) {
  +                    String prefix = value.substring(0, value.indexOf(":"));
  +                    String oldNamespace = null;
  +                    if ((oldNamespace = (String) namespaces.get(prefix)) != null) {
  +                        value = value.substring(value.indexOf(":") + 1);
  +                        Hashtable realNamespaces = schema.getPrefixToNamespaceMap();
  +                        java.util.Iterator iter = realNamespaces.keySet().iterator();
  +                        while (iter.hasNext()) {
  +                            prefix = (String) iter.next();
  +                            String namespace = (String) realNamespaces.get(prefix);
  +                            if (namespace.equals(oldNamespace))
  +                                value = prefix + ":" + value;
  +                        }
  +                    }
  +
  +                }
  +                if (unhandled[i].getNamespaceURI() != null)
  +                    attribute.setAttributeNS(unhandled[i].getNamespaceURI(), nodeName, value);
  +                else
  +                    attribute.setAttribute(nodeName, value);
  +            }
  +        }
           return attribute;
       }
  +
       /************************************************************************
  -	 * Element serializeChoice(Document doc, XmlSchemaChoice choiceObj, 
  -	 *   XmlSchema schema) throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc             - Document the parent use.
  -	 * choiceObj       - XmlSchemaChoice that will be serialized.
  -	 * schema          - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of choice schema object.
  -	 ************************************************************************/
  -    Element serializeChoice(Document doc, XmlSchemaChoice choiceObj, 
  -							XmlSchema schema) throws XmlSchemaSerializerException{
  +     * Element serializeChoice(Document doc, XmlSchemaChoice choiceObj, 
  +     *   XmlSchema schema) throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc             - Document the parent use.
  +     * choiceObj       - XmlSchemaChoice that will be serialized.
  +     * schema          - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of choice schema object.
  +     ************************************************************************/
  +    Element serializeChoice(Document doc, XmlSchemaChoice choiceObj,
  +                            XmlSchema schema) throws XmlSchemaSerializerException {
           //todo: handle any non schema attri ?
           
  -        Element choice = createNewElement(doc, "choice", 
  -										  schema.schema_ns_prefix,  schema.SCHEMA_NS);
  -        if(choiceObj.id!= null)
  -            if(choiceObj.id.length()>0)
  +        Element choice = createNewElement(doc, "choice",
  +                                          schema.schema_ns_prefix, schema.SCHEMA_NS);
  +        if (choiceObj.id != null)
  +            if (choiceObj.id.length() > 0)
                   choice.setAttributeNS(schema.SCHEMA_NS, "id", choiceObj.id);
  -        
  -         
  -        if(choiceObj.maxOccurs < Long.MAX_VALUE && choiceObj.maxOccurs > 1)
  -            choice.setAttributeNS(schema.SCHEMA_NS, "maxOccurs", 
  -								  choiceObj.maxOccurs +"");
  -        else if(choiceObj.maxOccurs == Long.MAX_VALUE)
  -            choice.setAttributeNS(schema.SCHEMA_NS, "maxOccurs", 
  -								  "unbounded");
  +
  +
  +        if (choiceObj.maxOccurs < Long.MAX_VALUE && choiceObj.maxOccurs > 1)
  +            choice.setAttributeNS(schema.SCHEMA_NS, "maxOccurs",
  +                                  choiceObj.maxOccurs + "");
  +        else if (choiceObj.maxOccurs == Long.MAX_VALUE)
  +            choice.setAttributeNS(schema.SCHEMA_NS, "maxOccurs",
  +                                  "unbounded");
           //else not serialized
           
  -        if(choiceObj.minOccurs >1)
  -            choice.setAttributeNS(schema.SCHEMA_NS, "minOccurs", 
  -								  choiceObj.minOccurs + "");
  +        if (choiceObj.minOccurs > 1)
  +            choice.setAttributeNS(schema.SCHEMA_NS, "minOccurs",
  +                                  choiceObj.minOccurs + "");
                  
   
           /*
  @@ -1158,342 +1207,343 @@
   		*/  
               
           
  -        if(choiceObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 choiceObj.annotation, schema);
  +        if (choiceObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     choiceObj.annotation, schema);
               choice.appendChild(annotation);
           }
  -            
  -        
  +
  +
           XmlSchemaObjectCollection itemColl = choiceObj.items;
   
  -        if(itemColl != null){
  +        if (itemColl != null) {
               int itemLength = itemColl.getCount();
   
  -            for(int i=0;i<itemLength;i++){
  +            for (int i = 0; i < itemLength; i++) {
                   XmlSchemaObject obj = itemColl.getItem(i);
   
  -                if(obj instanceof  XmlSchemaElement){
  -                    Element el = serializeElement(doc, 
  -												  (XmlSchemaElement)obj, schema);
  +                if (obj instanceof XmlSchemaElement) {
  +                    Element el = serializeElement(doc,
  +                                                  (XmlSchemaElement) obj, schema);
                       choice.appendChild(el);
  -                }else if(obj instanceof XmlSchemaGroupRef){
  -                    Element group = serializeGroupRef(doc, 
  -													  (XmlSchemaGroupRef)obj, schema);
  +                } else if (obj instanceof XmlSchemaGroupRef) {
  +                    Element group = serializeGroupRef(doc,
  +                                                      (XmlSchemaGroupRef) obj, schema);
                       choice.appendChild(group);
  -                }else if(obj instanceof XmlSchemaChoice){
  +                } else if (obj instanceof XmlSchemaChoice) {
                       Element inlineChoice = serializeChoice(doc,
  -														   (XmlSchemaChoice)obj, schema);
  +                                                           (XmlSchemaChoice) obj, schema);
                       choice.appendChild(inlineChoice);
  -                }else if(obj instanceof XmlSchemaSequence){
  -                    Element inlineSequence = serializeSequence(doc, 
  -															   (XmlSchemaSequence)obj, schema);
  +                } else if (obj instanceof XmlSchemaSequence) {
  +                    Element inlineSequence = serializeSequence(doc,
  +                                                               (XmlSchemaSequence) obj, schema);
                       choice.appendChild(inlineSequence);
  -                }else if(obj instanceof XmlSchemaAny){
  -                    Element any = serializeAny(doc, (XmlSchemaAny)obj, schema);
  +                } else if (obj instanceof XmlSchemaAny) {
  +                    Element any = serializeAny(doc, (XmlSchemaAny) obj, schema);
                       choice.appendChild(any);
                   }
               }
           }
           return choice;
       }
  +
       /************************************************************************
  -	 * Element serializeAll(Document doc, XmlSchemaAll allObj, XmlSchema schema) 
  -	 *    throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc             - Document the parent use.
  -	 * allObj          - XmlSchemaAll that will be serialized.
  -	 * schema          - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of particle all.
  -	 ************************************************************************/
  -    Element serializeAll(Document doc, XmlSchemaAll allObj, XmlSchema schema) 
  -        throws XmlSchemaSerializerException{
  -        Element allEl = createNewElement(doc, "all", schema.schema_ns_prefix, 
  -										 schema.SCHEMA_NS);
  -        
  -		if(allObj.minOccurs == 0)
  +     * Element serializeAll(Document doc, XmlSchemaAll allObj, XmlSchema schema) 
  +     *    throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc             - Document the parent use.
  +     * allObj          - XmlSchemaAll that will be serialized.
  +     * schema          - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of particle all.
  +     ************************************************************************/
  +    Element serializeAll(Document doc, XmlSchemaAll allObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
  +        Element allEl = createNewElement(doc, "all", schema.schema_ns_prefix,
  +                                         schema.SCHEMA_NS);
  +
  +        if (allObj.minOccurs == 0)
               allEl.setAttributeNS(schema.SCHEMA_NS, "minOccurs", "0");
   
  -        
  -        if(allObj.annotation != null){
  +
  +        if (allObj.annotation != null) {
               Element annotation = serializeAnnotation(doc, allObj.annotation,
  -													 schema);
  +                                                     schema);
               allEl.appendChild(annotation);
           }
   
           XmlSchemaObjectCollection itemColl = allObj.items;
  -        
  -        if(itemColl != null){
  +
  +        if (itemColl != null) {
               int itemLength = itemColl.getCount();
   
  -            for(int i=0;i<itemLength;i++){
  +            for (int i = 0; i < itemLength; i++) {
                   XmlSchemaObject obj = itemColl.getItem(i);
  -                if(obj instanceof XmlSchemaElement){
  -                    Element el = serializeElement(doc, (XmlSchemaElement)obj, 
  -												  schema);
  +                if (obj instanceof XmlSchemaElement) {
  +                    Element el = serializeElement(doc, (XmlSchemaElement) obj,
  +                                                  schema);
                       allEl.appendChild(el);
  -                }else
  +                } else
                       throw new XmlSchemaSerializerException("Only element "
  -														   + "allowed as child of all model type");
  +                                                           + "allowed as child of all model type");
               }
           }
  -        
  +
           return allEl;
       }
   
       /************************************************************************
  -	 * Element serializeSimpleTypeList(Document doc, 
  -	 *    XmlSchemaSimpleTypeList listObj, XmlSchema schema)
  -	 *        throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc             - Document the parent use.
  -	 * listObj         - XmlSchemaSimpleTypeList that will be serialized.
  -	 * schema          - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of simple type with list method.
  -	 ************************************************************************/
  -    Element serializeSimpleTypeList(Document doc, 
  -									XmlSchemaSimpleTypeList listObj, XmlSchema schema)
  -		throws XmlSchemaSerializerException{
  +     * Element serializeSimpleTypeList(Document doc, 
  +     *    XmlSchemaSimpleTypeList listObj, XmlSchema schema)
  +     *        throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc             - Document the parent use.
  +     * listObj         - XmlSchemaSimpleTypeList that will be serialized.
  +     * schema          - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of simple type with list method.
  +     ************************************************************************/
  +    Element serializeSimpleTypeList(Document doc,
  +                                    XmlSchemaSimpleTypeList listObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
   
  -        Element list = createNewElement(doc, "list" , 
  -										schema.schema_ns_prefix ,schema.SCHEMA_NS);
  +        Element list = createNewElement(doc, "list",
  +                                        schema.schema_ns_prefix, schema.SCHEMA_NS);
   
  -        if(listObj.itemTypeName != null){
  +        if (listObj.itemTypeName != null) {
               String listItemType = resolveQualifiedName(listObj.itemTypeName,
  -													   schema);
  +                                                       schema);
               list.setAttributeNS(schema.SCHEMA_NS, "itemType", listItemType);
           }
  -        if(listObj.id != null)
  +        if (listObj.id != null)
               list.setAttributeNS(schema.SCHEMA_NS, "id", listObj.id);
  -        
  -        else if(listObj.itemType != null){
  -            Element inlineSimpleEl = serializeSimpleType(doc, listObj.itemType, 
  -														 schema);
  +
  +        else if (listObj.itemType != null) {
  +            Element inlineSimpleEl = serializeSimpleType(doc, listObj.itemType,
  +                                                         schema);
               list.appendChild(inlineSimpleEl);
           }
  -        if(listObj.annotation != null){
  +        if (listObj.annotation != null) {
               Element annotation = serializeAnnotation(doc, listObj.annotation, schema);
               list.appendChild(annotation);
           }
           return list;
       }
  -    
  +
       /************************************************************************
  -	 * Element serializeSimpleTypeUnion(Document doc, 
  -	 *    XmlSchemaSimpleTypeUnion unionObj, XmlSchema schema) 
  -	 *    throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc              - Document the parent use.
  -	 * unionObj         - XmlSchemaSimpleTypeUnion that will be serialized.
  -	 * schema           - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of simple type with union method.
  -	 ************************************************************************/
  -    Element serializeSimpleTypeUnion(Document doc, 
  -									 XmlSchemaSimpleTypeUnion unionObj, XmlSchema schema) 
  -        throws XmlSchemaSerializerException{
  -        
  -        
  -        Element union = createNewElement(doc, "union", 
  -										 schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        if(unionObj.id != null)
  +     * Element serializeSimpleTypeUnion(Document doc, 
  +     *    XmlSchemaSimpleTypeUnion unionObj, XmlSchema schema) 
  +     *    throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc              - Document the parent use.
  +     * unionObj         - XmlSchemaSimpleTypeUnion that will be serialized.
  +     * schema           - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of simple type with union method.
  +     ************************************************************************/
  +    Element serializeSimpleTypeUnion(Document doc,
  +                                     XmlSchemaSimpleTypeUnion unionObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
  +
  +
  +        Element union = createNewElement(doc, "union",
  +                                         schema.schema_ns_prefix, schema.SCHEMA_NS);
  +        if (unionObj.id != null)
               union.setAttributeNS(schema.SCHEMA_NS, "id", unionObj.id);
  -        
  -        if(unionObj.memberTypesSource != null)
  -            union.setAttributeNS(schema.SCHEMA_NS, "memberTypes", 
  -								 unionObj.memberTypesSource);
  -        else if(unionObj.baseTypes.getCount() > 0){
  +
  +        if (unionObj.memberTypesSource != null)
  +            union.setAttributeNS(schema.SCHEMA_NS, "memberTypes",
  +                                 unionObj.memberTypesSource);
  +        else if (unionObj.baseTypes.getCount() > 0) {
               int baseTypesLength = unionObj.baseTypes.getCount();
               Element baseType;
  -            for(int i=0; i<baseTypesLength; i++){
  -                try{
  -                    baseType = serializeSimpleType(doc, 
  -												   (XmlSchemaSimpleType)unionObj.baseTypes.getItem(i), 
  -												   schema);
  +            for (int i = 0; i < baseTypesLength; i++) {
  +                try {
  +                    baseType = serializeSimpleType(doc,
  +                                                   (XmlSchemaSimpleType) unionObj.baseTypes.getItem(i),
  +                                                   schema);
                       union.appendChild(baseType);
  -                }catch(ClassCastException e){
  +                } catch (ClassCastException e) {
                       throw new XmlSchemaSerializerException(
  -														   "only inline simple type allow as attribute's "
  -														   + "inline type");
  +                            "only inline simple type allow as attribute's "
  +                            + "inline type");
                   }
               }
           }
  -        if(unionObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, unionObj.annotation, 
  -													 schema);
  +        if (unionObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc, unionObj.annotation,
  +                                                     schema);
               union.appendChild(annotation);
           }
           return union;
  -    }    
  +    }
   
       /************************************************************************
  -	 * Element serializeAny(Document doc, XmlSchemaAny anyObj, XmlSchema schema)
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc              - Document the parent use.
  -	 * anyObj           - XmlSchemaAny that will be serialized.
  -	 * schema           - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of any that is part of its parent.
  -	 ************************************************************************/
  -    Element serializeAny(Document doc, XmlSchemaAny anyObj, XmlSchema schema){
  -        Element anyEl = createNewElement(doc, "any", schema.schema_ns_prefix , 
  -										 schema.SCHEMA_NS);
  -        if(anyObj.id != null)
  -            if(anyObj.id.length()>0)
  +     * Element serializeAny(Document doc, XmlSchemaAny anyObj, XmlSchema schema)
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc              - Document the parent use.
  +     * anyObj           - XmlSchemaAny that will be serialized.
  +     * schema           - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of any that is part of its parent.
  +     ************************************************************************/
  +    Element serializeAny(Document doc, XmlSchemaAny anyObj, XmlSchema schema) {
  +        Element anyEl = createNewElement(doc, "any", schema.schema_ns_prefix,
  +                                         schema.SCHEMA_NS);
  +        if (anyObj.id != null)
  +            if (anyObj.id.length() > 0)
                   anyEl.setAttributeNS(schema.SCHEMA_NS, "id", anyObj.id);
  - 
  -        
  -		if(anyObj.maxOccurs < Long.MAX_VALUE && anyObj.maxOccurs > 1)
  -            anyEl.setAttributeNS(schema.SCHEMA_NS, "maxOccurs", 
  -								 anyObj.maxOccurs +"");
  -        else if(anyObj.maxOccurs == Long.MAX_VALUE)
  -            anyEl.setAttributeNS(schema.SCHEMA_NS, "maxOccurs", 
  -								 "unbounded");
  +
  +
  +        if (anyObj.maxOccurs < Long.MAX_VALUE && anyObj.maxOccurs > 1)
  +            anyEl.setAttributeNS(schema.SCHEMA_NS, "maxOccurs",
  +                                 anyObj.maxOccurs + "");
  +        else if (anyObj.maxOccurs == Long.MAX_VALUE)
  +            anyEl.setAttributeNS(schema.SCHEMA_NS, "maxOccurs",
  +                                 "unbounded");
           //else not serialized
           
  -        if(anyObj.minOccurs >1)
  -            anyEl.setAttributeNS(schema.SCHEMA_NS, "minOccurs", 
  -								 anyObj.minOccurs + "");
  - 
  -        if(anyObj.namespace != null)
  -            anyEl.setAttributeNS(schema.SCHEMA_NS, "namespace", 
  -								 anyObj.namespace);
  -        
  -        if(anyObj.processContent != null){
  +        if (anyObj.minOccurs > 1)
  +            anyEl.setAttributeNS(schema.SCHEMA_NS, "minOccurs",
  +                                 anyObj.minOccurs + "");
  +
  +        if (anyObj.namespace != null)
  +            anyEl.setAttributeNS(schema.SCHEMA_NS, "namespace",
  +                                 anyObj.namespace);
  +
  +        if (anyObj.processContent != null) {
               String value = anyObj.processContent.getValue();
  -            if(!value.equals("None")){
  +            if (!value.equals("None")) {
                   String processContent = convertString(value);
  -                anyEl.setAttributeNS(schema.SCHEMA_NS, "processContents", 
  -									 processContent);
  +                anyEl.setAttributeNS(schema.SCHEMA_NS, "processContents",
  +                                     processContent);
               }
           }
  -        if(anyObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 anyObj.annotation, schema);
  +        if (anyObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     anyObj.annotation, schema);
               anyEl.appendChild(annotation);
           }
  -        
  +
           return anyEl;
       }
  -    
  +
       /************************************************************************
  -	 * Element serializeGroup(Document doc, XmlSchemaGroup groupObj, 
  -	 *    XmlSchema schema) throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc                - Document the parent use.
  -	 * groupObj           - XmlSchemaGroup that will be serialized.
  -	 * schema             - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of group elements.
  -	 ************************************************************************/
  -    Element serializeGroup(Document doc, XmlSchemaGroup groupObj, 
  -						   XmlSchema schema) throws XmlSchemaSerializerException{
  -            
  -        Element group = createNewElement(doc, "group", 
  -										 schema.schema_ns_prefix,schema.SCHEMA_NS);
  -        
  -        if(groupObj.name != null){
  -            if(groupObj.name.length() > 0){
  +     * Element serializeGroup(Document doc, XmlSchemaGroup groupObj, 
  +     *    XmlSchema schema) throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc                - Document the parent use.
  +     * groupObj           - XmlSchemaGroup that will be serialized.
  +     * schema             - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of group elements.
  +     ************************************************************************/
  +    Element serializeGroup(Document doc, XmlSchemaGroup groupObj,
  +                           XmlSchema schema) throws XmlSchemaSerializerException {
  +
  +        Element group = createNewElement(doc, "group",
  +                                         schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if (groupObj.name != null) {
  +            if (groupObj.name.length() > 0) {
                   group.setAttributeNS(schema.SCHEMA_NS, "name", groupObj.name);
               }
  -        }else
  -            throw new XmlSchemaSerializerException("Group must have " + 
  -												   "name or ref");
  -                
  -        
  -        if(groupObj.particle instanceof XmlSchemaSequence){
  -            Element sequence = serializeSequence(doc, 
  -												 (XmlSchemaSequence)groupObj.particle, schema);
  +        } else
  +            throw new XmlSchemaSerializerException("Group must have " +
  +                                                   "name or ref");
  +
  +
  +        if (groupObj.particle instanceof XmlSchemaSequence) {
  +            Element sequence = serializeSequence(doc,
  +                                                 (XmlSchemaSequence) groupObj.particle, schema);
               group.appendChild(sequence);
  -        }else if(groupObj.particle instanceof XmlSchemaChoice){
  -            Element choice = serializeChoice(doc, 
  -											 (XmlSchemaChoice)groupObj.particle, schema);
  +        } else if (groupObj.particle instanceof XmlSchemaChoice) {
  +            Element choice = serializeChoice(doc,
  +                                             (XmlSchemaChoice) groupObj.particle, schema);
               group.appendChild(choice);
  -        }else if(groupObj.particle instanceof XmlSchemaAll){
  -            Element all = serializeAll(doc, 
  -									   (XmlSchemaAll)groupObj.particle, schema);
  +        } else if (groupObj.particle instanceof XmlSchemaAll) {
  +            Element all = serializeAll(doc,
  +                                       (XmlSchemaAll) groupObj.particle, schema);
               group.appendChild(all);
           }
  -        if(groupObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 groupObj.annotation, schema);
  +        if (groupObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     groupObj.annotation, schema);
               group.appendChild(annotation);
           }
           return group;
       }
  -    
  +
       /************************************************************************
  -	 * Element serializeGroupRef(Document doc, XmlSchemaGroupRef groupRefObj, 
  -	 *    XmlSchema schema) throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc                   - Document the parent use.
  -	 * groupRefObj           - XmlSchemaGroupRef that will be serialized.
  -	 * schema                - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of group elements ref inside its parent.
  -	 ************************************************************************/
  -    Element serializeGroupRef(Document doc, XmlSchemaGroupRef groupRefObj, 
  -							  XmlSchema schema) throws XmlSchemaSerializerException{
  -        
  -        Element groupRef = createNewElement(doc, "group", 
  -											schema.schema_ns_prefix,schema.SCHEMA_NS);
  -        
  -        if(groupRefObj.refName != null){
  -            String groupRefName = resolveQualifiedName(groupRefObj.refName, 
  -													   schema);
  +     * Element serializeGroupRef(Document doc, XmlSchemaGroupRef groupRefObj, 
  +     *    XmlSchema schema) throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc                   - Document the parent use.
  +     * groupRefObj           - XmlSchemaGroupRef that will be serialized.
  +     * schema                - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of group elements ref inside its parent.
  +     ************************************************************************/
  +    Element serializeGroupRef(Document doc, XmlSchemaGroupRef groupRefObj,
  +                              XmlSchema schema) throws XmlSchemaSerializerException {
  +
  +        Element groupRef = createNewElement(doc, "group",
  +                                            schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if (groupRefObj.refName != null) {
  +            String groupRefName = resolveQualifiedName(groupRefObj.refName,
  +                                                       schema);
               groupRef.setAttributeNS(schema.SCHEMA_NS, "ref", groupRefName);
  -        }else 
  +        } else
               throw new XmlSchemaSerializerException("Group must have name or ref");
  -        
  -        if(groupRefObj.maxOccurs < Long.MAX_VALUE && groupRefObj.maxOccurs > 1)
  -            groupRef.setAttributeNS(schema.SCHEMA_NS, "maxOccurs", 
  -									groupRefObj.maxOccurs +"");
  -        else if(groupRefObj.maxOccurs == Long.MAX_VALUE)
  -            groupRef.setAttributeNS(schema.SCHEMA_NS, "maxOccurs", 
  -									"unbounded");
  +
  +        if (groupRefObj.maxOccurs < Long.MAX_VALUE && groupRefObj.maxOccurs > 1)
  +            groupRef.setAttributeNS(schema.SCHEMA_NS, "maxOccurs",
  +                                    groupRefObj.maxOccurs + "");
  +        else if (groupRefObj.maxOccurs == Long.MAX_VALUE)
  +            groupRef.setAttributeNS(schema.SCHEMA_NS, "maxOccurs",
  +                                    "unbounded");
           //else not serialized
           
  -        if(groupRefObj.minOccurs >1)
  -            groupRef.setAttributeNS(schema.SCHEMA_NS, "minOccurs", 
  -									groupRefObj.minOccurs + "");
  +        if (groupRefObj.minOccurs > 1)
  +            groupRef.setAttributeNS(schema.SCHEMA_NS, "minOccurs",
  +                                    groupRefObj.minOccurs + "");
   
           
           /*
  @@ -1505,945 +1555,949 @@
   		  "maxOccurs", groupRefObj.maxOccurs + "");
   		*/
           
  -        if(groupRefObj.particle != null){
  +        if (groupRefObj.particle != null) {
               Element particleEl;
  -            if(groupRefObj.particle instanceof XmlSchemaChoice)
  +            if (groupRefObj.particle instanceof XmlSchemaChoice)
                   particleEl = serializeChoice(doc,
  -											 (XmlSchemaChoice)groupRefObj.particle, schema);
  -            else if(groupRefObj.particle instanceof XmlSchemaSequence)
  -                particleEl = serializeSequence(doc, 
  -											   (XmlSchemaSequence)groupRefObj.particle, schema);
  -            else if(groupRefObj.particle instanceof XmlSchemaAll)
  -                particleEl = serializeAll(doc, 
  -										  (XmlSchemaAll)groupRefObj.particle, schema);
  +                                             (XmlSchemaChoice) groupRefObj.particle, schema);
  +            else if (groupRefObj.particle instanceof XmlSchemaSequence)
  +                particleEl = serializeSequence(doc,
  +                                               (XmlSchemaSequence) groupRefObj.particle, schema);
  +            else if (groupRefObj.particle instanceof XmlSchemaAll)
  +                particleEl = serializeAll(doc,
  +                                          (XmlSchemaAll) groupRefObj.particle, schema);
               else
                   throw new XmlSchemaSerializerException("The content of group "
  -													   + "ref particle should be"
  -													   + " sequence, choice or all reference:  " 
  -													   + "www.w3.org/TR/xmlschema-1#element-group-3.7.2");
  -        }
  -        if(groupRefObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 groupRefObj.annotation, schema);
  +                                                       + "ref particle should be"
  +                                                       + " sequence, choice or all reference:  "
  +                                                       + "www.w3.org/TR/xmlschema-1#element-group-3.7.2");
  +        }
  +        if (groupRefObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     groupRefObj.annotation, schema);
               groupRef.appendChild(annotation);
           }
  -        
  +
           return groupRef;
       }
  -    
  +
       /************************************************************************
  -	 * Element serializeSimpleContent(Document doc, 
  -	 *    XmlSchemaSimpleContent simpleContentObj, XmlSchema schema) 
  -	 *        throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc               - Document the parent use.
  -	 * simpleContentObj  - XmlSchemaSimpleContent that will be serialized.
  -	 * schema            - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of complex type simple content.
  -	 ************************************************************************/
  -    Element serializeSimpleContent(Document doc, 
  -								   XmlSchemaSimpleContent simpleContentObj, XmlSchema schema) 
  -		throws XmlSchemaSerializerException{
  -        Element simpleContent = createNewElement(doc, "simpleContent", 
  -												 schema.schema_ns_prefix, schema.SCHEMA_NS);
  -       
  +     * Element serializeSimpleContent(Document doc, 
  +     *    XmlSchemaSimpleContent simpleContentObj, XmlSchema schema) 
  +     *        throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc               - Document the parent use.
  +     * simpleContentObj  - XmlSchemaSimpleContent that will be serialized.
  +     * schema            - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of complex type simple content.
  +     ************************************************************************/
  +    Element serializeSimpleContent(Document doc,
  +                                   XmlSchemaSimpleContent simpleContentObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
  +        Element simpleContent = createNewElement(doc, "simpleContent",
  +                                                 schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
           Element content;
  -        if(simpleContentObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 simpleContentObj.annotation, schema);
  +        if (simpleContentObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     simpleContentObj.annotation, schema);
               simpleContent.appendChild(annotation);
           }
  -        if(simpleContentObj.content instanceof 
  -		   XmlSchemaSimpleContentRestriction)
  -            content = serializeSimpleContentRestriction(doc, 
  -														(XmlSchemaSimpleContentRestriction)simpleContentObj.content, 
  -														schema);
  -        else if(simpleContentObj.content instanceof 
  -				XmlSchemaSimpleContentExtension)
  -            content = serializeSimpleContentExtension(doc, 
  -													  (XmlSchemaSimpleContentExtension)simpleContentObj.content, 
  -													  schema);
  -        else 
  +        if (simpleContentObj.content instanceof
  +                XmlSchemaSimpleContentRestriction)
  +            content = serializeSimpleContentRestriction(doc,
  +                                                        (XmlSchemaSimpleContentRestriction) simpleContentObj.content,
  +                                                        schema);
  +        else if (simpleContentObj.content instanceof
  +                XmlSchemaSimpleContentExtension)
  +            content = serializeSimpleContentExtension(doc,
  +                                                      (XmlSchemaSimpleContentExtension) simpleContentObj.content,
  +                                                      schema);
  +        else
               throw new XmlSchemaSerializerException("content of simple content "
  -												   +"must be restriction or extension");
  -         
  +                                                   + "must be restriction or extension");
  +
           simpleContent.appendChild(content);
           return simpleContent;
       }
  -    
  +
       /************************************************************************
  -	 * Element serializeComplexContent(Document doc, 
  -	 *    XmlSchemaComplexContent complexContentObj, XmlSchema schema) 
  -	 *    throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc                - Document the parent use.
  -	 * complexContentObj  - XmlSchemaComplexContent that will be serialized.
  -	 * schema             - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of complex type complex content.
  -	 ************************************************************************/
  -    Element serializeComplexContent(Document doc, 
  -									XmlSchemaComplexContent complexContentObj, XmlSchema schema) 
  -        throws XmlSchemaSerializerException{
  -        
  -        Element complexContent = createNewElement(doc, "complexContent", 
  -												  schema.schema_ns_prefix, schema.SCHEMA_NS);
  +     * Element serializeComplexContent(Document doc, 
  +     *    XmlSchemaComplexContent complexContentObj, XmlSchema schema) 
  +     *    throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc                - Document the parent use.
  +     * complexContentObj  - XmlSchemaComplexContent that will be serialized.
  +     * schema             - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of complex type complex content.
  +     ************************************************************************/
  +    Element serializeComplexContent(Document doc,
  +                                    XmlSchemaComplexContent complexContentObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
  +
  +        Element complexContent = createNewElement(doc, "complexContent",
  +                                                  schema.schema_ns_prefix, schema.SCHEMA_NS);
   
   
  -        if(complexContentObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 complexContentObj.annotation, schema);
  +        if (complexContentObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     complexContentObj.annotation, schema);
               complexContent.appendChild(annotation);
           }
   
  -        if(complexContentObj.mixed)
  +        if (complexContentObj.mixed)
               complexContent.setAttributeNS(schema.SCHEMA_NS, "mixed", "true");
  -        if(complexContentObj.id != null)
  -            complexContent.setAttributeNS(schema.SCHEMA_NS, "id", 
  -										  complexContentObj.id);
  -        
  +        if (complexContentObj.id != null)
  +            complexContent.setAttributeNS(schema.SCHEMA_NS, "id",
  +                                          complexContentObj.id);
  +
           Element content;
  -        if(complexContentObj.content instanceof 
  -		   XmlSchemaComplexContentRestriction)
  -            
  -            content = serializeComplexContentRestriction(doc, 
  -														 (XmlSchemaComplexContentRestriction)complexContentObj.content, 
  -														 schema);
  -        else if(complexContentObj.content instanceof
  -				XmlSchemaComplexContentExtension)
  -            content = serializeComplexContentExtension(doc, 
  -													   (XmlSchemaComplexContentExtension)complexContentObj.content, 
  -													   schema);
  -        else 
  +        if (complexContentObj.content instanceof
  +                XmlSchemaComplexContentRestriction)
  +
  +            content = serializeComplexContentRestriction(doc,
  +                                                         (XmlSchemaComplexContentRestriction) complexContentObj.content,
  +                                                         schema);
  +        else if (complexContentObj.content instanceof
  +                XmlSchemaComplexContentExtension)
  +            content = serializeComplexContentExtension(doc,
  +                                                       (XmlSchemaComplexContentExtension) complexContentObj.content,
  +                                                       schema);
  +        else
               throw new XmlSchemaSerializerException("content of complexContent "
  -												   +"must be restriction or extension");
  -         
  +                                                   + "must be restriction or extension");
  +
           complexContent.appendChild(content);
  -         
  +
           return complexContent;
       }
  -    
  +
       /************************************************************************
  -	 * Element serializeIdentityConstraint(Document doc, 
  -	 *    XmlSchemaIdentityConstraint constraintObj, XmlSchema schema) 
  -	 *        throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc               - Document the parent use.
  -	 * constraintObj     - XmlSchemaIdentityConstraint that will be serialized.
  -	 * schema            - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of key, keyref or unique that part of its parent.
  -	 ************************************************************************/
  -    Element serializeIdentityConstraint(Document doc, 
  -										XmlSchemaIdentityConstraint constraintObj, XmlSchema schema) 
  -		throws XmlSchemaSerializerException{
  +     * Element serializeIdentityConstraint(Document doc, 
  +     *    XmlSchemaIdentityConstraint constraintObj, XmlSchema schema) 
  +     *        throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc               - Document the parent use.
  +     * constraintObj     - XmlSchemaIdentityConstraint that will be serialized.
  +     * schema            - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of key, keyref or unique that part of its parent.
  +     ************************************************************************/
  +    Element serializeIdentityConstraint(Document doc,
  +                                        XmlSchemaIdentityConstraint constraintObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
   
           Element constraint;
  -        
  -        if(constraintObj instanceof XmlSchemaUnique)
  -            constraint = createNewElement(doc, "unique", 
  -										  schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        else if(constraintObj instanceof XmlSchemaKey)
  -            constraint = createNewElement(doc, "key", 
  -										  schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        else if(constraintObj instanceof XmlSchemaKeyref){
  -            constraint = createNewElement(doc, "keyref", 
  -										  schema.schema_ns_prefix, schema.SCHEMA_NS);
  -            XmlSchemaKeyref keyref = (XmlSchemaKeyref)constraintObj;
  -            if(keyref.refer != null){
  +
  +        if (constraintObj instanceof XmlSchemaUnique)
  +            constraint = createNewElement(doc, "unique",
  +                                          schema.schema_ns_prefix, schema.SCHEMA_NS);
  +        else if (constraintObj instanceof XmlSchemaKey)
  +            constraint = createNewElement(doc, "key",
  +                                          schema.schema_ns_prefix, schema.SCHEMA_NS);
  +        else if (constraintObj instanceof XmlSchemaKeyref) {
  +            constraint = createNewElement(doc, "keyref",
  +                                          schema.schema_ns_prefix, schema.SCHEMA_NS);
  +            XmlSchemaKeyref keyref = (XmlSchemaKeyref) constraintObj;
  +            if (keyref.refer != null) {
                   String keyrefStr = resolveQualifiedName(keyref.refer, schema);
  -                constraint.setAttributeNS(schema.SCHEMA_NS, 
  -										  "refer", keyrefStr);
  +                constraint.setAttributeNS(schema.SCHEMA_NS,
  +                                          "refer", keyrefStr);
               }
  -        }else
  +        } else
               throw new XmlSchemaSerializerException("not valid identity "
  -												   + "constraint");
  -        
  -        if(constraintObj.name != null)
  -            constraint.setAttributeNS(schema.SCHEMA_NS, "name", 
  -									  constraintObj.name);
  -        if(constraintObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 constraintObj.annotation, schema);
  +                                                   + "constraint");
  +
  +        if (constraintObj.name != null)
  +            constraint.setAttributeNS(schema.SCHEMA_NS, "name",
  +                                      constraintObj.name);
  +        if (constraintObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     constraintObj.annotation, schema);
               constraint.appendChild(annotation);
           }
  -        
  -        if(constraintObj.selector != null){
  -            Element selector = serializeSelector(doc, 
  -												 constraintObj.selector, schema);
  +
  +        if (constraintObj.selector != null) {
  +            Element selector = serializeSelector(doc,
  +                                                 constraintObj.selector, schema);
               constraint.appendChild(selector);
           }
           XmlSchemaObjectCollection fieldColl = constraintObj.fields;
  -        if(fieldColl != null){
  +        if (fieldColl != null) {
               int fieldLength = fieldColl.getCount();
  -            for(int i=0; i<fieldLength;i++){
  -                Element field = serializeField(doc, 
  -											   (XmlSchemaXPath)fieldColl.getItem(i), schema);
  +            for (int i = 0; i < fieldLength; i++) {
  +                Element field = serializeField(doc,
  +                                               (XmlSchemaXPath) fieldColl.getItem(i), schema);
                   constraint.appendChild(field);
               }
  -        }       
  +        }
           return constraint;
  -    }    
  +    }
   
       /************************************************************************
  -	 * Element serializeSelector(Document doc, XmlSchemaXPath selectorObj,
  -	 *    XmlSchema schema) throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc               - Document the parent use.
  -	 * selectorObj      - XmlSchemaXPath that will be serialized.
  -	 * schema            - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of selector with collection of xpath as its attrib.  The selector
  -	 * itself is the part of identity type.  eg <key><selector xpath="..."
  -	 ************************************************************************/
  +     * Element serializeSelector(Document doc, XmlSchemaXPath selectorObj,
  +     *    XmlSchema schema) throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc               - Document the parent use.
  +     * selectorObj      - XmlSchemaXPath that will be serialized.
  +     * schema            - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of selector with collection of xpath as its attrib.  The selector
  +     * itself is the part of identity type.  eg <key><selector xpath="..."
  +     ************************************************************************/
       Element serializeSelector(Document doc, XmlSchemaXPath selectorObj,
  -							  XmlSchema schema) throws XmlSchemaSerializerException{
  -    
  -        Element selector = createNewElement(doc, "selector", 
  -											schema.schema_ns_prefix, schema.SCHEMA_NS);
  -    
  -        if(selectorObj.xpath != null)
  -            selector.setAttributeNS(schema.SCHEMA_NS, "xpath", 
  -									selectorObj.xpath);
  +                              XmlSchema schema) throws XmlSchemaSerializerException {
  +
  +        Element selector = createNewElement(doc, "selector",
  +                                            schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if (selectorObj.xpath != null)
  +            selector.setAttributeNS(schema.SCHEMA_NS, "xpath",
  +                                    selectorObj.xpath);
           else
               throw new XmlSchemaSerializerException("xpath can't be null");
  -        
  -        if(selectorObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 selectorObj.annotation, schema);
  +
  +        if (selectorObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     selectorObj.annotation, schema);
               selector.appendChild(annotation);
           }
           return selector;
       }
  -   
  +
       /************************************************************************
  -	 * Element serializeField(Document doc, XmlSchemaXPath fieldObj, 
  -	 *    XmlSchema schema) throws XmlSchemaSerializerException
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc           - Document the parent use.
  -	 * fieldObj      - XmlSchemaXPath that will be serialized.
  -	 * schema        - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * field element that part of constraint.
  -	 ************************************************************************/
  -    Element serializeField(Document doc, XmlSchemaXPath fieldObj, 
  -						   XmlSchema schema) throws XmlSchemaSerializerException{
  -    
  -        Element field = createNewElement(doc, "field", schema.schema_ns_prefix, 
  -										 schema.SCHEMA_NS);
  -    
  -        if(fieldObj.xpath != null)
  +     * Element serializeField(Document doc, XmlSchemaXPath fieldObj, 
  +     *    XmlSchema schema) throws XmlSchemaSerializerException
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc           - Document the parent use.
  +     * fieldObj      - XmlSchemaXPath that will be serialized.
  +     * schema        - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * field element that part of constraint.
  +     ************************************************************************/
  +    Element serializeField(Document doc, XmlSchemaXPath fieldObj,
  +                           XmlSchema schema) throws XmlSchemaSerializerException {
  +
  +        Element field = createNewElement(doc, "field", schema.schema_ns_prefix,
  +                                         schema.SCHEMA_NS);
  +
  +        if (fieldObj.xpath != null)
               field.setAttributeNS(schema.SCHEMA_NS, "xpath", fieldObj.xpath);
           else
               throw new XmlSchemaSerializerException("xpath can't be null");
  -        
  -        if(fieldObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 fieldObj.annotation, schema);
  +
  +        if (fieldObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     fieldObj.annotation, schema);
               field.appendChild(annotation);
           }
  -        
  +
           return field;
       }
  -    
  +
       /************************************************************************
  -	 * Element serializeAnnotation(Document doc, XmlSchemaAnnotation 
  -	 *    annotationObj, XmlSchema schema) 
  -	 *
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc               - Document the parent use.
  -	 * annotationObj      - XmlSchemaAnnotation that will be serialized.
  -	 * schema            - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * annotation element that part of any type. will contain document and 
  -	 * appinfo for child.
  -	 ************************************************************************/
  -    Element serializeAnnotation(Document doc, XmlSchemaAnnotation annotationObj, 
  -								XmlSchema schema){
  -            
  -        Element annotation = createNewElement(doc, "annotation", 
  -											  schema.schema_ns_prefix,schema.SCHEMA_NS);
  -        
  +     * Element serializeAnnotation(Document doc, XmlSchemaAnnotation 
  +     *    annotationObj, XmlSchema schema) 
  +     *
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc               - Document the parent use.
  +     * annotationObj      - XmlSchemaAnnotation that will be serialized.
  +     * schema            - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * annotation element that part of any type. will contain document and 
  +     * appinfo for child.
  +     ************************************************************************/
  +    Element serializeAnnotation(Document doc, XmlSchemaAnnotation annotationObj,
  +                                XmlSchema schema) {
  +
  +        Element annotation = createNewElement(doc, "annotation",
  +                                              schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
           XmlSchemaObjectCollection contents = annotationObj.items;
           int contentLength = contents.getCount();
  -        
  -        for(int i=0; i<contentLength; i++){
  +
  +        for (int i = 0; i < contentLength; i++) {
               XmlSchemaObject obj = contents.getItem(i);
  -            
  -            if(obj instanceof XmlSchemaAppInfo){
  -                XmlSchemaAppInfo appinfo = (XmlSchemaAppInfo)obj;
  +
  +            if (obj instanceof XmlSchemaAppInfo) {
  +                XmlSchemaAppInfo appinfo = (XmlSchemaAppInfo) obj;
                   Element appInfoEl = serializeAppInfo(doc, appinfo, schema);
                   annotation.appendChild(appInfoEl);
  -            }else if(obj instanceof XmlSchemaDocumentation){
  -                XmlSchemaDocumentation documentation = 
  -                    (XmlSchemaDocumentation)obj;
  -                
  -                Element documentationEl = serializeDocumentation(doc, 
  -																 documentation, schema);
  -                
  -                
  +            } else if (obj instanceof XmlSchemaDocumentation) {
  +                XmlSchemaDocumentation documentation =
  +                        (XmlSchemaDocumentation) obj;
  +
  +                Element documentationEl = serializeDocumentation(doc,
  +                                                                 documentation, schema);
  +
  +
                   annotation.appendChild(documentationEl);
               }
           }
  - 
  +
           return annotation;
  -    }    
  - 
  +    }
  +
       /************************************************************************
  -	 * Element serializeAppInfo(Document doc,XmlSchemaAppInfo appInfoObj,
  -	 *    XmlSchema schema)
  -	 *
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc               - Document the parent use.
  -	 * appInfoObj        - XmlSchemaAppInfo that will be serialized.
  -	 * schema            - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * App info element that is part of the annotation.
  -	 ************************************************************************/
  -    Element serializeAppInfo(Document doc,XmlSchemaAppInfo appInfoObj,
  -							 XmlSchema schema){
  -            
  -        Element appInfoEl = createNewElement(doc, "appinfo", 
  -											 schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        if(appInfoObj.source != null)
  -            appInfoEl.setAttributeNS(schema.SCHEMA_NS, "source", 
  -									 appInfoObj.source);
  +     * Element serializeAppInfo(Document doc,XmlSchemaAppInfo appInfoObj,
  +     *    XmlSchema schema)
  +     *
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc               - Document the parent use.
  +     * appInfoObj        - XmlSchemaAppInfo that will be serialized.
  +     * schema            - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * App info element that is part of the annotation.
  +     ************************************************************************/
  +    Element serializeAppInfo(Document doc, XmlSchemaAppInfo appInfoObj,
  +                             XmlSchema schema) {
  +
  +        Element appInfoEl = createNewElement(doc, "appinfo",
  +                                             schema.schema_ns_prefix, schema.SCHEMA_NS);
  +        if (appInfoObj.source != null)
  +            appInfoEl.setAttributeNS(schema.SCHEMA_NS, "source",
  +                                     appInfoObj.source);
   
  -        if(appInfoObj.markup != null){
  +        if (appInfoObj.markup != null) {
               int markupLength = appInfoObj.markup.getLength();
  -            for(int j=0;j<markupLength; j++){
  +            for (int j = 0; j < markupLength; j++) {
                   Node n = appInfoObj.markup.item(j);
  -                switch(n.getNodeType()){
  -				case Node.ELEMENT_NODE:
  -					appendElement(doc, appInfoEl, n, schema);
  -					break;
  -				case Node.TEXT_NODE:
  -					Text t = doc.createTextNode(n.getNodeValue()); 
  -					appInfoEl.appendChild(t);
  -					break;
  -				default:
  -					break;
  +                switch (n.getNodeType()) {
  +                    case Node.ELEMENT_NODE:
  +                        appendElement(doc, appInfoEl, n, schema);
  +                        break;
  +                    case Node.TEXT_NODE:
  +                        Text t = doc.createTextNode(n.getNodeValue());
  +                        appInfoEl.appendChild(t);
  +                        break;
  +                    default:
  +                        break;
                   }
               }
           }
   
           return appInfoEl;
       }
  - 
  +
       /************************************************************************
  -	 * Element serializeDocumentation(Document doc,XmlSchemaDocumentation 
  -	 *    documentationObj, XmlSchema schema){
  -	 *
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc               - Document the parent use.
  -	 * documentationObj        - XmlSchemaAppInfo that will be serialized.
  -	 * schema            - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element representation of documentation that is part of annotation.
  -	 ************************************************************************/
  -    Element serializeDocumentation(Document doc,XmlSchemaDocumentation 
  -								   documentationObj, XmlSchema schema){
  -        
  -            
  -            
  +     * Element serializeDocumentation(Document doc,XmlSchemaDocumentation 
  +     *    documentationObj, XmlSchema schema){
  +     *
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc               - Document the parent use.
  +     * documentationObj        - XmlSchemaAppInfo that will be serialized.
  +     * schema            - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element representation of documentation that is part of annotation.
  +     ************************************************************************/
  +    Element serializeDocumentation(Document doc, XmlSchemaDocumentation
  +            documentationObj, XmlSchema schema) {
  +
  +
           Element documentationEl = createNewElement(doc, "documentation",
  -												   schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        if(documentationObj.source != null)
  -            documentationEl.setAttributeNS(schema.SCHEMA_NS, "source", 
  -										   documentationObj.source);
  -        if(documentationObj.language != null)
  +                                                   schema.schema_ns_prefix, schema.SCHEMA_NS);
  +        if (documentationObj.source != null)
  +            documentationEl.setAttributeNS(schema.SCHEMA_NS, "source",
  +                                           documentationObj.source);
  +        if (documentationObj.language != null)
               documentationEl.setAttributeNS(
  -										   "http://www.w3.org/XML/1998/namespace", "xml:lang",
  -										   documentationObj.language);
  +                    "http://www.w3.org/XML/1998/namespace", "xml:lang",
  +                    documentationObj.language);
   
  -        if(documentationObj.markup != null){
  +        if (documentationObj.markup != null) {
               int markupLength = documentationObj.markup.getLength();
  -            for(int j=0;j<markupLength; j++){
  +            for (int j = 0; j < markupLength; j++) {
                   Node n = documentationObj.markup.item(j);
  -                
  -                switch(n.getNodeType()){
  -				case Node.ELEMENT_NODE:
  -					appendElement(doc, documentationEl, n, schema);
  -					break;
  -				case Node.TEXT_NODE:
  -					Text t = doc.createTextNode(n.getNodeValue()); 
  -					documentationEl.appendChild(t);
  -					break;
  -				default:
  -					break;
  +
  +                switch (n.getNodeType()) {
  +                    case Node.ELEMENT_NODE:
  +                        appendElement(doc, documentationEl, n, schema);
  +                        break;
  +                    case Node.TEXT_NODE:
  +                        Text t = doc.createTextNode(n.getNodeValue());
  +                        documentationEl.appendChild(t);
  +                        break;
  +                    default:
  +                        break;
                   }
               }
           }
           return documentationEl;
  -    }       
  - 
  +    }
  +
       /************************************************************************
  -	 * Element serializeSimpleContentRestriction(Document doc, 
  -	 *    XmlSchemaSimpleContentRestriction restrictionObj, XmlSchema schema) 
  -	 *    throws XmlSchemaSerializerException{
  -	 *
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc               - Document the parent use.
  -	 * restrictionObj    - XmlSchemaSimpleContentRestriction that will be 
  -	 *                       serialized.
  -	 * schema            - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 *   Element of simple content restriction.
  -	 ************************************************************************/
  -    Element serializeSimpleContentRestriction(Document doc, 
  -											  XmlSchemaSimpleContentRestriction restrictionObj, XmlSchema schema) 
  -        throws XmlSchemaSerializerException{
  -        
  -        Element restriction = createNewElement(doc, "restriction", 
  -											   schema.schema_ns_prefix, schema.SCHEMA_NS);
  +     * Element serializeSimpleContentRestriction(Document doc, 
  +     *    XmlSchemaSimpleContentRestriction restrictionObj, XmlSchema schema) 
  +     *    throws XmlSchemaSerializerException{
  +     *
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc               - Document the parent use.
  +     * restrictionObj    - XmlSchemaSimpleContentRestriction that will be 
  +     *                       serialized.
  +     * schema            - Schema Document object of the parent.
  +     *
  +     * Return:
  +     *   Element of simple content restriction.
  +     ************************************************************************/
  +    Element serializeSimpleContentRestriction(Document doc,
  +                                              XmlSchemaSimpleContentRestriction restrictionObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
  +
  +        Element restriction = createNewElement(doc, "restriction",
  +                                               schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if (restrictionObj.baseTypeName != null) {
  +            String baseTypeName =
  +                    resolveQualifiedName(restrictionObj.baseTypeName, schema);
  +
  +            restriction.setAttributeNS(schema.SCHEMA_NS, "base", baseTypeName);
   
  -        if(restrictionObj.baseTypeName != null){
  -            String baseTypeName = 
  -                resolveQualifiedName(restrictionObj.baseTypeName, schema);
  -            
  -            restriction.setAttributeNS(schema.SCHEMA_NS, "base",baseTypeName);
  -        
           }
  -        if(restrictionObj.id != null)
  -			restriction.setAttributeNS(schema.SCHEMA_NS, "id",restrictionObj.id);
  -            
  -        if(restrictionObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 restrictionObj.annotation, schema);
  +        if (restrictionObj.id != null)
  +            restriction.setAttributeNS(schema.SCHEMA_NS, "id", restrictionObj.id);
  +
  +        if (restrictionObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     restrictionObj.annotation, schema);
               restriction.appendChild(annotation);
           }
           int attrCollLength = restrictionObj.attributes.getCount();
  -        for(int i=0; i<attrCollLength;i++){
  +        for (int i = 0; i < attrCollLength; i++) {
               XmlSchemaObject obj = restrictionObj.attributes.getItem(i);
  -            
  -            if(obj instanceof XmlSchemaAttribute){
  -                Element attribute = serializeAttribute(doc, 
  -													   (XmlSchemaAttribute)obj, schema);
  +
  +            if (obj instanceof XmlSchemaAttribute) {
  +                Element attribute = serializeAttribute(doc,
  +                                                       (XmlSchemaAttribute) obj, schema);
                   restriction.appendChild(attribute);
  -            }else if(obj instanceof XmlSchemaAttributeGroupRef){
  -                Element attributeGroup = serializeAttributeGroupRef(doc, 
  -																	(XmlSchemaAttributeGroupRef)obj, schema);
  +            } else if (obj instanceof XmlSchemaAttributeGroupRef) {
  +                Element attributeGroup = serializeAttributeGroupRef(doc,
  +                                                                    (XmlSchemaAttributeGroupRef) obj, schema);
                   restriction.appendChild(attributeGroup);
               }
           }
  -        if(restrictionObj.baseType != null){
  -            Element inlineSimpleType = serializeSimpleType(doc, 
  -														   restrictionObj.baseType, schema);
  +        if (restrictionObj.baseType != null) {
  +            Element inlineSimpleType = serializeSimpleType(doc,
  +                                                           restrictionObj.baseType, schema);
               restriction.appendChild(inlineSimpleType);
           }
  -        if(restrictionObj.anyAttribute != null){
  -            Element anyAttribute = serializeAnyAttribute(doc, 
  -														 restrictionObj.anyAttribute, schema);
  +        if (restrictionObj.anyAttribute != null) {
  +            Element anyAttribute = serializeAnyAttribute(doc,
  +                                                         restrictionObj.anyAttribute, schema);
               restriction.appendChild(anyAttribute);
           }
           XmlSchemaObjectCollection facets = restrictionObj.facets;
           int facetLength = facets.getCount();
  -        for(int i=0;i<facetLength;i++){
  -            Element facet = serializeFacet(doc, 
  -										   (XmlSchemaFacet)facets.getItem(i), schema);
  +        for (int i = 0; i < facetLength; i++) {
  +            Element facet = serializeFacet(doc,
  +                                           (XmlSchemaFacet) facets.getItem(i), schema);
               restriction.appendChild(facet);
           }
           return restriction;
  -    }    
  -    
  +    }
  +
       /************************************************************************
  -	 * Element serializeSimpleContentExtension(Document doc, 
  -	 *    XmlSchemaSimpleContentExtension extensionObj, XmlSchema schema)
  -	 *        throws XmlSchemaSerializerException{
  -	 *
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc                 - Document the parent use.
  -	 * extensionObj        - XmlSchemaSimpleContentExtension 
  -	 *                       that will be serialized.
  -	 * schema              - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 *   Element of simple content extension.
  -	 ************************************************************************/
  -    Element serializeSimpleContentExtension(Document doc, 
  -											XmlSchemaSimpleContentExtension extensionObj, XmlSchema schema)
  -		throws XmlSchemaSerializerException{
  -        
  +     * Element serializeSimpleContentExtension(Document doc, 
  +     *    XmlSchemaSimpleContentExtension extensionObj, XmlSchema schema)
  +     *        throws XmlSchemaSerializerException{
  +     *
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc                 - Document the parent use.
  +     * extensionObj        - XmlSchemaSimpleContentExtension 
  +     *                       that will be serialized.
  +     * schema              - Schema Document object of the parent.
  +     *
  +     * Return:
  +     *   Element of simple content extension.
  +     ************************************************************************/
  +    Element serializeSimpleContentExtension(Document doc,
  +                                            XmlSchemaSimpleContentExtension extensionObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
  +
           Element extension = createNewElement(doc, "extension",
  -											 schema.schema_ns_prefix, schema.SCHEMA_NS);
  -       
  -        if(extensionObj.baseTypeName != null){
  -            String baseTypeName = 
  -                resolveQualifiedName(extensionObj.baseTypeName, schema);
  -            
  +                                             schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if (extensionObj.baseTypeName != null) {
  +            String baseTypeName =
  +                    resolveQualifiedName(extensionObj.baseTypeName, schema);
  +
               extension.setAttributeNS(schema.SCHEMA_NS, "base", baseTypeName);
           }
  -        
  -        if(extensionObj.id != null)
  +
  +        if (extensionObj.id != null)
               extension.setAttributeNS(schema.SCHEMA_NS, "id", extensionObj.id);
  -        
  -        if(extensionObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 extensionObj.annotation, schema);
  +
  +        if (extensionObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     extensionObj.annotation, schema);
               extension.appendChild(annotation);
           }
  -        if(extensionObj.anyAttribute != null){
  +        if (extensionObj.anyAttribute != null) {
               Element anyAttribute = serializeAnyAttribute(doc,
  -														 extensionObj.anyAttribute, schema);
  +                                                         extensionObj.anyAttribute, schema);
               extension.appendChild(anyAttribute);
           }
  -        
  +
           XmlSchemaObjectCollection attributes = extensionObj.attributes;
           int attributeLength = attributes.getCount();
  -        for(int i=0;i<attributeLength;i++){
  +        for (int i = 0; i < attributeLength; i++) {
               XmlSchemaObject obj = attributes.getItem(i);
  -            
  -            if(obj instanceof XmlSchemaAttribute){
  -                Element attribute = serializeAttribute(doc, 
  -													   (XmlSchemaAttribute)obj, schema);
  +
  +            if (obj instanceof XmlSchemaAttribute) {
  +                Element attribute = serializeAttribute(doc,
  +                                                       (XmlSchemaAttribute) obj, schema);
                   extension.appendChild(attribute);
  -            }else if(obj instanceof XmlSchemaAttributeGroupRef){
  -                Element attributeGroupRef = serializeAttributeGroupRef(doc, 
  -																	   (XmlSchemaAttributeGroupRef)obj, schema);
  +            } else if (obj instanceof XmlSchemaAttributeGroupRef) {
  +                Element attributeGroupRef = serializeAttributeGroupRef(doc,
  +                                                                       (XmlSchemaAttributeGroupRef) obj, schema);
                   extension.appendChild(attributeGroupRef);
               }
           }
           return extension;
  -    }    
  +    }
  +
       /************************************************************************
  -	 * Element serializeComplexContentRestriction(Document doc, 
  -	 *    XmlSchemaComplexContentRestriction restrictionObj, XmlSchema schema) 
  -	 *    throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc                 - Document the parent use.
  -	 * restrictionObj        - XmlSchemaSimpleContentRestriction 
  -	 *                       that will be serialized.
  -	 * schema              - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 *   Element of simple content restriction.
  -	 ************************************************************************/
  -    Element serializeComplexContentRestriction(Document doc, 
  -											   XmlSchemaComplexContentRestriction restrictionObj, XmlSchema schema) 
  -        throws XmlSchemaSerializerException{
  -        
  -        Element restriction = createNewElement(doc, "restriction", 
  -											   schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        
  -        if(restrictionObj.baseTypeName != null){
  +     * Element serializeComplexContentRestriction(Document doc, 
  +     *    XmlSchemaComplexContentRestriction restrictionObj, XmlSchema schema) 
  +     *    throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc                 - Document the parent use.
  +     * restrictionObj        - XmlSchemaSimpleContentRestriction 
  +     *                       that will be serialized.
  +     * schema              - Schema Document object of the parent.
  +     *
  +     * Return:
  +     *   Element of simple content restriction.
  +     ************************************************************************/
  +    Element serializeComplexContentRestriction(Document doc,
  +                                               XmlSchemaComplexContentRestriction restrictionObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
  +
  +        Element restriction = createNewElement(doc, "restriction",
  +                                               schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if (restrictionObj.baseTypeName != null) {
               String baseTypeName = resolveQualifiedName(
  -													   restrictionObj.baseTypeName, schema);
  -            restriction.setAttributeNS(schema.SCHEMA_NS, 
  -									   "base", baseTypeName);
  +                    restrictionObj.baseTypeName, schema);
  +            restriction.setAttributeNS(schema.SCHEMA_NS,
  +                                       "base", baseTypeName);
           }
  -        
  -        if(restrictionObj.id != null)
  +
  +        if (restrictionObj.id != null)
               restriction.setAttributeNS(schema.SCHEMA_NS, "id",
  -									   restrictionObj.id);
  -        
  -        if(restrictionObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 restrictionObj.annotation, schema);
  +                                       restrictionObj.id);
  +
  +        if (restrictionObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     restrictionObj.annotation, schema);
               restriction.appendChild(annotation);
           }
   
  -        if(restrictionObj.particle instanceof XmlSchemaSequence){
  +        if (restrictionObj.particle instanceof XmlSchemaSequence) {
               Element sequenceParticle = serializeSequence(doc,
  -														 (XmlSchemaSequence)restrictionObj.particle, schema);
  +                                                         (XmlSchemaSequence) restrictionObj.particle, schema);
               restriction.appendChild(sequenceParticle);
  -        }else if(restrictionObj.particle instanceof XmlSchemaChoice){
  -            Element choiceParticle = serializeChoice(doc, 
  -													 (XmlSchemaChoice)restrictionObj.particle, schema);
  +        } else if (restrictionObj.particle instanceof XmlSchemaChoice) {
  +            Element choiceParticle = serializeChoice(doc,
  +                                                     (XmlSchemaChoice) restrictionObj.particle, schema);
               restriction.appendChild(choiceParticle);
  -        }else if(restrictionObj.particle instanceof XmlSchemaAll){
  -            Element allParticle = serializeAll(doc, 
  -											   (XmlSchemaAll)restrictionObj.particle, schema);
  +        } else if (restrictionObj.particle instanceof XmlSchemaAll) {
  +            Element allParticle = serializeAll(doc,
  +                                               (XmlSchemaAll) restrictionObj.particle, schema);
               restriction.appendChild(allParticle);
  -        }else if(restrictionObj.particle instanceof XmlSchemaGroupRef){
  -            Element groupRefParticle = serializeGroupRef(doc, 
  -														 (XmlSchemaGroupRef)restrictionObj.particle, schema);
  +        } else if (restrictionObj.particle instanceof XmlSchemaGroupRef) {
  +            Element groupRefParticle = serializeGroupRef(doc,
  +                                                         (XmlSchemaGroupRef) restrictionObj.particle, schema);
               restriction.appendChild(groupRefParticle);
           }
  -            
  +
           int attributesLength = restrictionObj.attributes.getCount();
  -        for(int i=0;i<attributesLength;i++){
  +        for (int i = 0; i < attributesLength; i++) {
               XmlSchemaObject obj = restrictionObj.attributes.getItem(i);
  -            
  -            if(obj instanceof XmlSchemaAttribute){
  -                Element attr = serializeAttribute(doc, 
  -												  (XmlSchemaAttribute)obj, schema);
  +
  +            if (obj instanceof XmlSchemaAttribute) {
  +                Element attr = serializeAttribute(doc,
  +                                                  (XmlSchemaAttribute) obj, schema);
                   restriction.appendChild(attr);
  -            }else if(obj instanceof XmlSchemaAttribute){
  -                Element attrGroup = serializeAttributeGroupRef(doc, 
  -															   (XmlSchemaAttributeGroupRef)obj, schema);
  +            } else if (obj instanceof XmlSchemaAttribute) {
  +                Element attrGroup = serializeAttributeGroupRef(doc,
  +                                                               (XmlSchemaAttributeGroupRef) obj, schema);
                   restriction.appendChild(attrGroup);
               }
           }
  -    
  -        if(restrictionObj.anyAttribute != null){
  -            Element anyAttribute = serializeAnyAttribute(doc, 
  -														 restrictionObj.anyAttribute, schema);
  +
  +        if (restrictionObj.anyAttribute != null) {
  +            Element anyAttribute = serializeAnyAttribute(doc,
  +                                                         restrictionObj.anyAttribute, schema);
               restriction.appendChild(anyAttribute);
           }
  -            
  +
           return restriction;
  -    }    
  -    
  +    }
  +
       /************************************************************************
  -	 * Element serializeComplexContentExtension(Document doc, 
  -	 *    XmlSchemaComplexContentExtension extensionObj, XmlSchema schema) 
  -	 *    throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc                 - Document the parent use.
  -	 * extensionObj        - XmlSchemaComplexContentRestriction 
  -	 *                       that will be serialized.
  -	 * schema              - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of complex content extension.
  -	 ************************************************************************/
  -    Element serializeComplexContentExtension(Document doc, 
  -											 XmlSchemaComplexContentExtension extensionObj, XmlSchema schema) 
  -        throws XmlSchemaSerializerException{
  -        
  -        Element extension = createNewElement(doc, "extension", 
  -											 schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        if(extensionObj.baseTypeName != null){
  -            String baseType = resolveQualifiedName(extensionObj.baseTypeName, 
  -												   schema);
  -            extension.setAttributeNS(schema.SCHEMA_NS,"base", baseType);
  -        }
  -        if(extensionObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 extensionObj.annotation, schema );
  +     * Element serializeComplexContentExtension(Document doc, 
  +     *    XmlSchemaComplexContentExtension extensionObj, XmlSchema schema) 
  +     *    throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc                 - Document the parent use.
  +     * extensionObj        - XmlSchemaComplexContentRestriction 
  +     *                       that will be serialized.
  +     * schema              - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of complex content extension.
  +     ************************************************************************/
  +    Element serializeComplexContentExtension(Document doc,
  +                                             XmlSchemaComplexContentExtension extensionObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
  +
  +        Element extension = createNewElement(doc, "extension",
  +                                             schema.schema_ns_prefix, schema.SCHEMA_NS);
  +        if (extensionObj.baseTypeName != null) {
  +            String baseType = resolveQualifiedName(extensionObj.baseTypeName,
  +                                                   schema);
  +            extension.setAttributeNS(schema.SCHEMA_NS, "base", baseType);
  +        }
  +        if (extensionObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     extensionObj.annotation, schema);
               extension.appendChild(annotation);
           }
  -        
   
  -        if(extensionObj.particle instanceof XmlSchemaSequence){
  +
  +        if (extensionObj.particle instanceof XmlSchemaSequence) {
               Element sequenceParticle = serializeSequence(doc,
  -														 (XmlSchemaSequence)extensionObj.particle, schema);
  +                                                         (XmlSchemaSequence) extensionObj.particle, schema);
               extension.appendChild(sequenceParticle);
  -        }else if(extensionObj.particle instanceof XmlSchemaChoice){
  -            Element choiceParticle = serializeChoice(doc, 
  -													 (XmlSchemaChoice)extensionObj.particle, schema);
  +        } else if (extensionObj.particle instanceof XmlSchemaChoice) {
  +            Element choiceParticle = serializeChoice(doc,
  +                                                     (XmlSchemaChoice) extensionObj.particle, schema);
               extension.appendChild(choiceParticle);
  -        }else if(extensionObj.particle instanceof XmlSchemaAll){
  -            Element allParticle = serializeAll(doc, 
  -											   (XmlSchemaAll)extensionObj.particle, schema);
  +        } else if (extensionObj.particle instanceof XmlSchemaAll) {
  +            Element allParticle = serializeAll(doc,
  +                                               (XmlSchemaAll) extensionObj.particle, schema);
               extension.appendChild(allParticle);
  -        }else if(extensionObj.particle instanceof XmlSchemaGroupRef){
  -            Element groupRefParticle = serializeGroupRef(doc, 
  -														 (XmlSchemaGroupRef)extensionObj.particle, schema);
  +        } else if (extensionObj.particle instanceof XmlSchemaGroupRef) {
  +            Element groupRefParticle = serializeGroupRef(doc,
  +                                                         (XmlSchemaGroupRef) extensionObj.particle, schema);
               extension.appendChild(groupRefParticle);
           }
  -            
  +
           int attributesLength = extensionObj.attributes.getCount();
  -        for(int i=0;i<attributesLength;i++){
  +        for (int i = 0; i < attributesLength; i++) {
               XmlSchemaObject obj = extensionObj.attributes.getItem(i);
  -            
  -            if(obj instanceof XmlSchemaAttribute){
  +
  +            if (obj instanceof XmlSchemaAttribute) {
                   Element attr = serializeAttribute(doc,
  -												  (XmlSchemaAttribute)obj, schema);
  +                                                  (XmlSchemaAttribute) obj, schema);
                   extension.appendChild(attr);
  -            }else if(obj instanceof XmlSchemaAttributeGroupRef){
  -                Element attrGroup = serializeAttributeGroupRef(doc, 
  -															   (XmlSchemaAttributeGroupRef)obj, schema);
  +            } else if (obj instanceof XmlSchemaAttributeGroupRef) {
  +                Element attrGroup = serializeAttributeGroupRef(doc,
  +                                                               (XmlSchemaAttributeGroupRef) obj, schema);
                   extension.appendChild(attrGroup);
               }
           }
  -    
  -        if(extensionObj.anyAttribute != null){
  -            Element anyAttribute = serializeAnyAttribute(doc, 
  -														 extensionObj.anyAttribute, schema);
  +
  +        if (extensionObj.anyAttribute != null) {
  +            Element anyAttribute = serializeAnyAttribute(doc,
  +                                                         extensionObj.anyAttribute, schema);
               extension.appendChild(anyAttribute);
           }
  -        
  +
           return extension;
  -    }    
  +    }
  +
       /************************************************************************
  -	 * Element serializeAnyAttribute(Document doc,
  -	 *    XmlSchemaAnyAttribute anyAttributeObj, XmlSchema schema)
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc                 - Document the parent use.
  -	 * anyAttributeObj     - XmlSchemaAnyAttribute 
  -	 *                       that will be serialized.
  -	 * schema              - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of any attribute element.
  -	 ************************************************************************/
  +     * Element serializeAnyAttribute(Document doc,
  +     *    XmlSchemaAnyAttribute anyAttributeObj, XmlSchema schema)
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc                 - Document the parent use.
  +     * anyAttributeObj     - XmlSchemaAnyAttribute 
  +     *                       that will be serialized.
  +     * schema              - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of any attribute element.
  +     ************************************************************************/
       Element serializeAnyAttribute(Document doc,
  -								  XmlSchemaAnyAttribute anyAttributeObj, XmlSchema schema){
  -        
  -        Element anyAttribute = createNewElement(doc, "anyAttribute", 
  -												schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        
  -        
  -        if(anyAttributeObj.namespace != null)
  -            anyAttribute.setAttributeNS(schema.SCHEMA_NS, "namespace", 
  -										anyAttributeObj.namespace);
  -        
  -        if(anyAttributeObj.id != null)
  -            anyAttribute.setAttributeNS(schema.SCHEMA_NS, "id", 
  -										anyAttributeObj.id);
  -        
  -        if(anyAttributeObj.processContent != null){
  +                                  XmlSchemaAnyAttribute anyAttributeObj, XmlSchema schema) {
  +
  +        Element anyAttribute = createNewElement(doc, "anyAttribute",
  +                                                schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +
  +        if (anyAttributeObj.namespace != null)
  +            anyAttribute.setAttributeNS(schema.SCHEMA_NS, "namespace",
  +                                        anyAttributeObj.namespace);
  +
  +        if (anyAttributeObj.id != null)
  +            anyAttribute.setAttributeNS(schema.SCHEMA_NS, "id",
  +                                        anyAttributeObj.id);
  +
  +        if (anyAttributeObj.processContent != null) {
               String processContent = anyAttributeObj.processContent.getValue();
               processContent = convertString(processContent);
  -            anyAttribute.setAttributeNS(schema.SCHEMA_NS, "processContents", 
  -										processContent);
  +            anyAttribute.setAttributeNS(schema.SCHEMA_NS, "processContents",
  +                                        processContent);
           }
  -        if(anyAttributeObj.annotation != null){
  -            Element annotation = serializeAnnotation(doc, 
  -													 anyAttributeObj.annotation, schema);
  +        if (anyAttributeObj.annotation != null) {
  +            Element annotation = serializeAnnotation(doc,
  +                                                     anyAttributeObj.annotation, schema);
               anyAttribute.appendChild(annotation);
           }
   
           return anyAttribute;
  -    }    
  +    }
  +
       /************************************************************************
  -	 * Element serializeAttributeGroupRef(Document doc, 
  -	 *    XmlSchemaAttributeGroupRef attributeGroupObj, XmlSchema schema) 
  -	 *   throws XmlSchemaSerializerException
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc                 - Document the parent use.
  -	 * attributeGroupObj     - XmlSchemaAttributeGroupRef 
  -	 *                       that will be serialized.
  -	 * schema              - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of attribute group ref that part of type.
  -	 ************************************************************************/
  -    Element serializeAttributeGroupRef(Document doc, 
  -									   XmlSchemaAttributeGroupRef attributeGroupObj, XmlSchema schema) 
  -        throws XmlSchemaSerializerException{
  -        
  -        Element attributeGroupRef = createNewElement(doc, "attributeGroup", 
  -													 schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        
  -        if(attributeGroupObj.refName != null){
  -            String refName = resolveQualifiedName(attributeGroupObj.refName, 
  -												  schema);
  +     * Element serializeAttributeGroupRef(Document doc, 
  +     *    XmlSchemaAttributeGroupRef attributeGroupObj, XmlSchema schema) 
  +     *   throws XmlSchemaSerializerException
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc                 - Document the parent use.
  +     * attributeGroupObj     - XmlSchemaAttributeGroupRef 
  +     *                       that will be serialized.
  +     * schema              - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of attribute group ref that part of type.
  +     ************************************************************************/
  +    Element serializeAttributeGroupRef(Document doc,
  +                                       XmlSchemaAttributeGroupRef attributeGroupObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
  +
  +        Element attributeGroupRef = createNewElement(doc, "attributeGroup",
  +                                                     schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if (attributeGroupObj.refName != null) {
  +            String refName = resolveQualifiedName(attributeGroupObj.refName,
  +                                                  schema);
               attributeGroupRef.setAttributeNS(schema.SCHEMA_NS, "ref", refName);
  -        }else
  +        } else
               throw new XmlSchemaSerializerException("Attribute group must have "
  -												   + "ref name set");
  -        
  -        if(attributeGroupObj.id != null)
  -            attributeGroupRef.setAttributeNS(schema.SCHEMA_NS,"id", 
  -											 attributeGroupObj.id);
  -        
  -        if(attributeGroupObj.annotation != null){
  +                                                   + "ref name set");
  +
  +        if (attributeGroupObj.id != null)
  +            attributeGroupRef.setAttributeNS(schema.SCHEMA_NS, "id",
  +                                             attributeGroupObj.id);
  +
  +        if (attributeGroupObj.annotation != null) {
               Element annotation = serializeAnnotation(doc,
  -													 attributeGroupObj.annotation, schema);
  +                                                     attributeGroupObj.annotation, schema);
               attributeGroupRef.appendChild(annotation);
           }
           return attributeGroupRef;
       }
  +
       /************************************************************************
  -	 * Element serializeAttributeGroup(Document doc, 
  -	 *    XmlSchemaAttributeGroup attributeGroupObj, XmlSchema schema) 
  -	 *    throws XmlSchemaSerializerException{
  -	 *   
  -	 * Each member of complex type will be appended and pass the element
  -	 * created.  Complex type processed according to w3c Recommendation
  -	 * May 2 2001. 
  -	 *
  -	 * Parameter:
  -	 * doc                 - Document the parent use.
  -	 * attributeGroupObj     - XmlSchemaAttributeGroup
  -	 *                       that will be serialized.
  -	 * schema              - Schema Document object of the parent.
  -	 *
  -	 * Return:
  -	 * Element of attribute group.
  -	 ************************************************************************/
  -    Element serializeAttributeGroup(Document doc, 
  -									XmlSchemaAttributeGroup attributeGroupObj, XmlSchema schema) 
  -        throws XmlSchemaSerializerException{
  -    
  -        Element attributeGroup = createNewElement(doc, "attributeGroup", 
  -												  schema.schema_ns_prefix, schema.SCHEMA_NS);
  -        
  -        if(attributeGroupObj.name != null)
  -            attributeGroup.setAttributeNS(schema.SCHEMA_NS, "name", 
  -										  attributeGroupObj.name);
  +     * Element serializeAttributeGroup(Document doc, 
  +     *    XmlSchemaAttributeGroup attributeGroupObj, XmlSchema schema) 
  +     *    throws XmlSchemaSerializerException{
  +     *   
  +     * Each member of complex type will be appended and pass the element
  +     * created.  Complex type processed according to w3c Recommendation
  +     * May 2 2001. 
  +     *
  +     * Parameter:
  +     * doc                 - Document the parent use.
  +     * attributeGroupObj     - XmlSchemaAttributeGroup
  +     *                       that will be serialized.
  +     * schema              - Schema Document object of the parent.
  +     *
  +     * Return:
  +     * Element of attribute group.
  +     ************************************************************************/
  +    Element serializeAttributeGroup(Document doc,
  +                                    XmlSchemaAttributeGroup attributeGroupObj, XmlSchema schema)
  +            throws XmlSchemaSerializerException {
  +
  +        Element attributeGroup = createNewElement(doc, "attributeGroup",
  +                                                  schema.schema_ns_prefix, schema.SCHEMA_NS);
  +
  +        if (attributeGroupObj.name != null)
  +            attributeGroup.setAttributeNS(schema.SCHEMA_NS, "name",
  +                                          attributeGroupObj.name);
           else
               throw new XmlSchemaSerializerException("Attribute group must"
  -												   + "have name");
  -        if(attributeGroupObj.id != null)
  -            attributeGroup.setAttributeNS(schema.SCHEMA_NS, "id", 
  -										  attributeGroupObj.id);
  -        
  -        if(attributeGroupObj.annotation != null){
  +                                                   + "have name");
  +        if (attributeGroupObj.id != null)
  +            attributeGroup.setAttributeNS(schema.SCHEMA_NS, "id",
  +                                          attributeGroupObj.id);
  +
  +        if (attributeGroupObj.annotation != null) {
               Element annotation = serializeAnnotation(doc,
  -													 attributeGroupObj.annotation, schema);
  +                                                     attributeGroupObj.annotation, schema);
               attributeGroup.appendChild(annotation);
           }
           int attributesLength = attributeGroupObj.attributes.getCount();
  -        for(int i=0;i<attributesLength;i++){
  +        for (int i = 0; i < attributesLength; i++) {
               XmlSchemaObject obj = attributeGroupObj.attributes.getItem(i);
  -            
  -            if(obj instanceof XmlSchemaAttribute){
  -                Element attr = serializeAttribute(doc, (XmlSchemaAttribute)obj,
  -												  schema);
  +
  +            if (obj instanceof XmlSchemaAttribute) {
  +                Element attr = serializeAttribute(doc, (XmlSchemaAttribute) obj,
  +                                                  schema);
                   attributeGroup.appendChild(attr);
  -            }else if(obj instanceof XmlSchemaAttributeGroupRef){
  -                Element attrGroup = serializeAttributeGroupRef(doc, 
  -															   (XmlSchemaAttributeGroupRef)obj, schema);
  +            } else if (obj instanceof XmlSchemaAttributeGroupRef) {
  +                Element attrGroup = serializeAttributeGroupRef(doc,
  +                                                               (XmlSchemaAttributeGroupRef) obj, schema);
                   attributeGroup.appendChild(attrGroup);
               }
           }
  -    
  -        if(attributeGroupObj.anyAttribute != null){
  -            Element anyAttribute = serializeAnyAttribute(doc, 
  -														 attributeGroupObj.anyAttribute, schema);
  +
  +        if (attributeGroupObj.anyAttribute != null) {
  +            Element anyAttribute = serializeAnyAttribute(doc,
  +                                                         attributeGroupObj.anyAttribute, schema);
               attributeGroup.appendChild(anyAttribute);
           }
  -        
  +
           return attributeGroup;
       }
  -    
  +
       //recursively add any attribute, text and children append all 
       //found children base on parent as its root.
  -    private void appendElement(Document doc, Element parent, 
  -							   Node children, XmlSchema schema){
  +    private void appendElement(Document doc, Element parent,
  +                               Node children, XmlSchema schema) {
           Element elTmp = (Element) children;
  -        Element el = createNewElement(doc, elTmp.getTagName(), 
  -									  schema.schema_ns_prefix, schema.SCHEMA_NS);
  +        Element el = createNewElement(doc, elTmp.getTagName(),
  +                                      schema.schema_ns_prefix, schema.SCHEMA_NS);
           NamedNodeMap attributes = el.getAttributes();
           //check if child node has attribute  
           //create new element and append it if found
           int attributeLength = attributes.getLength();
  -        for(int i=0;i<attributeLength;i++){
  +        for (int i = 0; i < attributeLength; i++) {
               Node n = attributes.item(i); 
               //assuming attributes got to throw exception if not later
  -            el.setAttributeNS(schema.SCHEMA_NS,n.getNodeName(),
  -							  n.getNodeValue());
  +            el.setAttributeNS(schema.SCHEMA_NS, n.getNodeName(),
  +                              n.getNodeValue());
           }
           
           //check any descendant of this node
           //if there then append its child
           NodeList decendants = el.getChildNodes();
           int decendantLength = decendants.getLength();
  -        for(int i=0;i<decendantLength;i++){
  +        for (int i = 0; i < decendantLength; i++) {
               Node n = decendants.item(i);
               short nodeType = n.getNodeType();
  -            if(nodeType == Node.TEXT_NODE){
  +            if (nodeType == Node.TEXT_NODE) {
                   String nValue = n.getNodeValue();
                   Text t = doc.createTextNode(nValue);
                   el.appendChild(t);
  -            }else if(nodeType == Node.ELEMENT_NODE){
  +            } else if (nodeType == Node.ELEMENT_NODE) {
                   appendElement(doc, el, n, schema);
               }
           }
       }
  -    
  +
       //break string with prefix into two parts part[0]:prefix , part[1]:namespace
  -    private static String[] getParts(String name){
  -        String[] parts = new String[2];		
  +    private static String[] getParts(String name) {
  +        String[] parts = new String[2];
   
           int index = name.indexOf(":");
  -        if( index > -1) {
  -			parts[0]= name.substring(0, index);
  -			parts[1]= name.substring(index + 1);
  +        if (index > -1) {
  +            parts[0] = name.substring(0, index);
  +            parts[1] = name.substring(index + 1);
           } else {
  -			parts[0] = "";
  -			parts[1] = name;
  -        }		
  +            parts[0] = "";
  +            parts[1] = name;
  +        }
           return parts;
       }
  -    
  +
       //Convert given string to lower case or w3c standard
  -    private String convertString(String convert){
  +    private String convertString(String convert) {
           String input = convert.trim();
  -        if(input.equals("All")){
  +        if (input.equals("All")) {
               return "#all";
  -        }else
  +        } else
               return input.toLowerCase();
       }
  +
       //Create new element with given local name and namespaces check whether
       //the prefix is there or not.
  -    private Element createNewElement(Document docs, String localName, 
  -									 String prefix, String namespace){
  -        String elementName = ((prefix.length()>0)? prefix += ":"  : "" )   
  -            + localName; 
  +    private Element createNewElement(Document docs, String localName,
  +                                     String prefix, String namespace) {
  +        String elementName = ((prefix.length() > 0)? prefix += ":"  : "")
  +                + localName;
           return docs.createElementNS(namespace, elementName);
       }
   
  @@ -2452,56 +2506,55 @@
       //create new prefix corresponding to that namespace and store that in 
       //hash table.  Finally add the new prefix and namespace to <schema> 
       //element
  -    private String resolveQualifiedName(QualifiedName names, 
  -										XmlSchema schemaObj){
  -        
  +    private String resolveQualifiedName(QualifiedName names,
  +                                        XmlSchema schemaObj) {
  +
           String namespace = names.getNameSpace();
           String type[] = getParts(names.getName());
           String typeName = (type.length > 1)? type[1]: type[0];
           String prefixStr;
  -        
  +
           Object prefix = schema_ns.get(namespace);
  -        
  -        if(prefix==null){
  +
  +        if (prefix == null) {
               int magicNumber = new java.util.Random().nextInt(999);
  -            prefix = "gen" +  magicNumber;
  +            prefix = "gen" + magicNumber;
               schema_ns.put(namespace, prefix);
   
               
               //setting xmlns in schema
  -            schemaElement.setAttributeNS("http://www.w3.org/2000/xmlns/", 
  -										 "xmlns:" +prefix.toString() ,  namespace);
  +            schemaElement.setAttributeNS("http://www.w3.org/2000/xmlns/",
  +                                         "xmlns:" + prefix.toString(), namespace);
           }
  -            
  +
           prefixStr = prefix.toString();
  -        prefixStr = (prefixStr.trim().length()>0)?  prefixStr + ":" : "";
  +        prefixStr = (prefixStr.trim().length() > 0)?  prefixStr + ":" : "";
   
           return prefixStr + typeName;
       }
  -    
  +
       //for each collection if it is an attribute serialize attribute and 
       //append that child to container element.
  -    void setupAttr(Document doc, XmlSchemaObjectCollection collectionObj, 
  -				   XmlSchema schema, Element container) throws XmlSchemaSerializerException{
  +    void setupAttr(Document doc, XmlSchemaObjectCollection collectionObj,
  +                   XmlSchema schema, Element container) throws XmlSchemaSerializerException {
           int collectionLength = collectionObj.getCount();
  -        for(int i=0;i<collectionLength;i++){
  +        for (int i = 0; i < collectionLength; i++) {
               XmlSchemaObject obj = collectionObj.getItem(i);
  -            if(obj instanceof XmlSchemaAttribute){
  -                XmlSchemaAttribute attr = (XmlSchemaAttribute)obj;
  +            if (obj instanceof XmlSchemaAttribute) {
  +                XmlSchemaAttribute attr = (XmlSchemaAttribute) obj;
                   Element attrEl = serializeAttribute(doc, attr, schema);
                   container.appendChild(attrEl);
  -            }
  -            else if (obj instanceof XmlSchemaAttributeGroupRef){
  -                XmlSchemaAttributeGroupRef attr= (XmlSchemaAttributeGroupRef)obj;
  +            } else if (obj instanceof XmlSchemaAttributeGroupRef) {
  +                XmlSchemaAttributeGroupRef attr = (XmlSchemaAttributeGroupRef) obj;
                   Element attrEl = serializeAttributeGroupRef(doc, attr, schema);
                   container.appendChild(attrEl);
               }
           }
       }
  -    
  -	public static class XmlSchemaSerializerException extends Exception {
  -        
  -        public XmlSchemaSerializerException(String msg){
  +
  +    public static class XmlSchemaSerializerException extends Exception {
  +
  +        public XmlSchemaSerializerException(String msg) {
               super(msg);
           }
       }
  
  
  
  1.2       +75 -20    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleContent.java
  
  Index: XmlSchemaSimpleContent.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleContent.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaSimpleContent.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaSimpleContent.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaSimpleContent.java
    *
    * Created on September 27, 2001, 3:19 AM
  @@ -15,29 +70,29 @@
   
   // Vidyanand - 16th Oct - initial implementation
   
  -public class XmlSchemaSimpleContent extends XmlSchemaContentModel{
  +public class XmlSchemaSimpleContent extends XmlSchemaContentModel {
   
       /** Creates new XmlSchemaSimpleContent */
       public XmlSchemaSimpleContent() {
       }
   
  -	/*  One of XmlSchemaSimpleContentRestriction or XmlSchemaSimpleContentExtension. */
  -	XmlSchemaContent content;
  -	
  -	public XmlSchemaContent getContent() {
  -		return this.content;
  -	}
  -	
  -	public void setContent( XmlSchemaContent content ) {
  -		this.content = content;
  -	}
  -	
  -	public String toString(String prefix, int tab) {
  -		String xml = new String();
  -		
  -		if(!prefix.equals("") && prefix.indexOf(":") == -1) {
  -			prefix += ":";	
  -		}
  -		return xml;
  -	}
  +    /*  One of XmlSchemaSimpleContentRestriction or XmlSchemaSimpleContentExtension. */
  +    XmlSchemaContent content;
  +
  +    public XmlSchemaContent getContent() {
  +        return this.content;
  +    }
  +
  +    public void setContent(XmlSchemaContent content) {
  +        this.content = content;
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +
  +        if (!prefix.equals("") && prefix.indexOf(":") == -1) {
  +            prefix += ":";
  +        }
  +        return xml;
  +    }
   }
  
  
  
  1.2       +87 -31    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleContentExtension.java
  
  Index: XmlSchemaSimpleContentExtension.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleContentExtension.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaSimpleContentExtension.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaSimpleContentExtension.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaSimpleContentExtension.java
    *
    * Created on September 27, 2001, 3:18 AM
  @@ -7,6 +62,7 @@
   package org.apache.axis.xsd.xml.schema;
   
   import org.apache.axis.xsd.xml.QualifiedName;
  +
   /**
    * Class for simple types that are derived by extension. Extends the simple
    * type content of the element by adding attributes. Represents the World Wide
  @@ -21,38 +77,38 @@
   
       /** Creates new XmlSchemaSimpleContentExtension */
       public XmlSchemaSimpleContentExtension() {
  -		attributes = new XmlSchemaObjectCollection();
  -    
  +        attributes = new XmlSchemaObjectCollection();
  +
  +    }
  +
  +    /* Allows an XmlSchemaAnyAttribute to be used for the attribute value.*/
  +    XmlSchemaAnyAttribute anyAttribute;
  +
  +    public void setAnyAttribute(XmlSchemaAnyAttribute anyAttribute) {
  +        this.anyAttribute = anyAttribute;
  +    }
  +
  +    public XmlSchemaAnyAttribute getAnyAttribute() {
  +        return this.anyAttribute;
  +    }
  +
  +    /* Contains XmlSchemaAttribute and XmlSchemaAttributeGroupRef. Collection of attributes for the simple type.*/
  +    XmlSchemaObjectCollection attributes;
  +
  +    public XmlSchemaObjectCollection getAttributes() {
  +        return this.attributes;
  +    }
  +
  +    /* Name of the built-in data type, simple type, or complex type.*/
  +    QualifiedName baseTypeName;
  +
  +    public void setBaseTypeName(QualifiedName baseTypeName) {
  +        this.baseTypeName = baseTypeName;
  +    }
  +
  +    public QualifiedName getBaseTypeName() {
  +        return this.baseTypeName;
       }
   
  -	/* Allows an XmlSchemaAnyAttribute to be used for the attribute value.*/
  -	XmlSchemaAnyAttribute anyAttribute;
  -	
  -	public void setAnyAttribute( XmlSchemaAnyAttribute anyAttribute ) {
  -		this.anyAttribute = anyAttribute;
  -	}
  -	
  -	public XmlSchemaAnyAttribute getAnyAttribute() {
  -		return this.anyAttribute;
  -	}
  -	
  -	/* Contains XmlSchemaAttribute and XmlSchemaAttributeGroupRef. Collection of attributes for the simple type.*/
  -	XmlSchemaObjectCollection  attributes;
  -	
  -	public XmlSchemaObjectCollection getAttributes() {
  -		return this.attributes;
  -	}
  -
  -	/* Name of the built-in data type, simple type, or complex type.*/
  -	QualifiedName baseTypeName;
  -	
  -	public void setBaseTypeName( QualifiedName  baseTypeName) {
  -		this.baseTypeName = baseTypeName;
  -	}
  -	
  -	public QualifiedName getBaseTypeName() {
  -		return this.baseTypeName;
  -	}
  -	
   }
   
  
  
  
  1.2       +106 -50   xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleContentRestriction.java
  
  Index: XmlSchemaSimpleContentRestriction.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleContentRestriction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaSimpleContentRestriction.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaSimpleContentRestriction.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaSimpleContentRestriction.java
    *
    * Created on September 27, 2001, 3:18 AM
  @@ -18,59 +73,60 @@
   
   // Vidyanand - 16th Oct - initial implementation
   
  -public class XmlSchemaSimpleContentRestriction extends XmlSchemaContent{
  +public class XmlSchemaSimpleContentRestriction extends XmlSchemaContent {
   
       /** Creates new XmlSchemaSimpleContentRestriction */
       public XmlSchemaSimpleContentRestriction() {
  -		facets = new XmlSchemaObjectCollection();
  -		attributes = new XmlSchemaObjectCollection();
  +        facets = new XmlSchemaObjectCollection();
  +        attributes = new XmlSchemaObjectCollection();
  +    }
  +
  +    /* Allows an XmlSchemaAnyAttribute to be used for the attribute value.*/
  +    XmlSchemaAnyAttribute anyAttribute;
  +
  +    public void setAnyAttribute(XmlSchemaAnyAttribute anyAttribute) {
  +        this.anyAttribute = anyAttribute;
  +    }
  +
  +    public XmlSchemaAnyAttribute getAnyAttribute() {
  +        return this.anyAttribute;
       }
  -	
  -	/* Allows an XmlSchemaAnyAttribute to be used for the attribute value.*/
  -	XmlSchemaAnyAttribute anyAttribute;
  -	
  -	public void setAnyAttribute( XmlSchemaAnyAttribute anyAttribute ) {
  -		this.anyAttribute = anyAttribute;
  -	}
  -	
  -	public XmlSchemaAnyAttribute getAnyAttribute() {
  -		return this.anyAttribute;
  -	}
  -	/* Contains XmlSchemaAttribute and XmlSchemaAttributeGroupRef. Collection of attributes for the simple type.*/
  -	XmlSchemaObjectCollection  attributes;
  -	
  -	public XmlSchemaObjectCollection getAttributes() {
  -		return this.attributes;
  -	}
  -
  -	/*Derived from the type specified by the base value.*/
  -	XmlSchemaSimpleType baseType;
  -	
  -	public void setBaseType( XmlSchemaSimpleType  baseType) {
  -		this.baseType = baseType;
  -	}
  -	
  -	public XmlSchemaSimpleType getBaseType() {
  -		return this.baseType;
  -	}
  -	
  -	/* Name of the built-in data type, simple type, or complex type.*/
  -	QualifiedName baseTypeName;
  -	
  -	public void setBaseTypeName( QualifiedName  baseTypeName) {
  -		this.baseTypeName = baseTypeName;
  -	}
  -	
  -	public QualifiedName getBaseTypeName() {
  -		return this.baseTypeName;
  -	}
  -	
  -	/* One or more of the facet classes: */
  -	XmlSchemaObjectCollection facets;
  -	
  -	public XmlSchemaObjectCollection getFacets() {
  -		return this.facets;
  -	}
  -	
  +
  +    /* Contains XmlSchemaAttribute and XmlSchemaAttributeGroupRef. Collection of attributes for the simple type.*/
  +    XmlSchemaObjectCollection attributes;
  +
  +    public XmlSchemaObjectCollection getAttributes() {
  +        return this.attributes;
  +    }
  +
  +    /*Derived from the type specified by the base value.*/
  +    XmlSchemaSimpleType baseType;
  +
  +    public void setBaseType(XmlSchemaSimpleType baseType) {
  +        this.baseType = baseType;
  +    }
  +
  +    public XmlSchemaSimpleType getBaseType() {
  +        return this.baseType;
  +    }
  +
  +    /* Name of the built-in data type, simple type, or complex type.*/
  +    QualifiedName baseTypeName;
  +
  +    public void setBaseTypeName(QualifiedName baseTypeName) {
  +        this.baseTypeName = baseTypeName;
  +    }
  +
  +    public QualifiedName getBaseTypeName() {
  +        return this.baseTypeName;
  +    }
  +
  +    /* One or more of the facet classes: */
  +    XmlSchemaObjectCollection facets;
  +
  +    public XmlSchemaObjectCollection getFacets() {
  +        return this.facets;
  +    }
  +
   }
   			
  
  
  
  1.2       +86 -31    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleType.java
  
  Index: XmlSchemaSimpleType.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleType.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaSimpleType.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaSimpleType.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaSimpleType.java
    *
    * Created on September 27, 2001, 3:39 AM
  @@ -18,41 +73,41 @@
   
   public class XmlSchemaSimpleType extends XmlSchemaType {
   
  -	XmlSchemaSimpleTypeContent content;
  -	
  +    XmlSchemaSimpleTypeContent content;
  +
       /** Creates new XmlSchemaSimpleType */
       public XmlSchemaSimpleType() {
       }
   
  -	public XmlSchemaSimpleTypeContent getContent() {
  -		return content;
  -	}
  -	
  -	public void setContent(XmlSchemaSimpleTypeContent content) {
  -		this.content = content;
  -	}
  -	
  -	public String toString(String prefix, int tab) {
  -		String xml = new String();
  -		
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		if(!prefix.equals("") && prefix.indexOf(":") == -1)
  -			prefix += ":";
  -	
  -		
  -		xml += "<" + prefix  + "simpleType>\n";
  -		
  -		if(content != null)
  -			xml += content.toString(prefix, (tab+1));
  -		
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		xml += "</" + prefix  + "simpleType>\n";
  -		return xml;
  -	}
  +    public XmlSchemaSimpleTypeContent getContent() {
  +        return content;
  +    }
  +
  +    public void setContent(XmlSchemaSimpleTypeContent content) {
  +        this.content = content;
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        if (!prefix.equals("") && prefix.indexOf(":") == -1)
  +            prefix += ":";
  +
  +
  +        xml += "<" + prefix + "simpleType>\n";
  +
  +        if (content != null)
  +            xml += content.toString(prefix, (tab + 1));
  +
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        xml += "</" + prefix + "simpleType>\n";
  +        return xml;
  +    }
   
   }
   
  
  
  
  1.2       +55 -0     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleTypeContent.java
  
  Index: XmlSchemaSimpleTypeContent.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleTypeContent.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaSimpleTypeContent.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaSimpleTypeContent.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaSimpleTypeContent.java
    *
    * Created on September 27, 2001, 3:38 AM
  
  
  
  1.2       +76 -21    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleTypeList.java
  
  Index: XmlSchemaSimpleTypeList.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleTypeList.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaSimpleTypeList.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaSimpleTypeList.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaSimpleTypeList.java
    *
    * Created on September 27, 2001, 3:38 AM
  @@ -15,30 +70,30 @@
    *
    * @author  mukund
    */
  -public class XmlSchemaSimpleTypeList extends XmlSchemaSimpleTypeContent{
  +public class XmlSchemaSimpleTypeList extends XmlSchemaSimpleTypeContent {
   
       /** Creates new XmlSchemaSimpleTypeList */
       public XmlSchemaSimpleTypeList() {
       }
  -	
  -	XmlSchemaSimpleType itemType;
  -	
  -	public XmlSchemaSimpleType getItemType() {
  -		return this.itemType;
  -	}
  -	
  -	public void setItemType( XmlSchemaSimpleType itemType ) {
  -		this.itemType = itemType;
  -	}
  -	
  -	QualifiedName itemTypeName;
  -	
  -	public QualifiedName getItemTypeName() {
  -		return this.itemTypeName;
  -	}
  -	
  -	public void setItemTypeName( QualifiedName itemTypeName){
  -		this.itemTypeName = itemTypeName;
  -	}
  +
  +    XmlSchemaSimpleType itemType;
  +
  +    public XmlSchemaSimpleType getItemType() {
  +        return this.itemType;
  +    }
  +
  +    public void setItemType(XmlSchemaSimpleType itemType) {
  +        this.itemType = itemType;
  +    }
  +
  +    QualifiedName itemTypeName;
  +
  +    public QualifiedName getItemTypeName() {
  +        return this.itemTypeName;
  +    }
  +
  +    public void setItemTypeName(QualifiedName itemTypeName) {
  +        this.itemTypeName = itemTypeName;
  +    }
   
   }
  
  
  
  1.2       +112 -57   xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleTypeRestriction.java
  
  Index: XmlSchemaSimpleTypeRestriction.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleTypeRestriction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaSimpleTypeRestriction.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaSimpleTypeRestriction.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaSimpleTypeRestriction.java
    *
    * Created on September 27, 2001, 3:38 AM
  @@ -15,66 +70,66 @@
    * @author  mukund
    */
   
  -public class XmlSchemaSimpleTypeRestriction extends XmlSchemaSimpleTypeContent{
  +public class XmlSchemaSimpleTypeRestriction extends XmlSchemaSimpleTypeContent {
   
       /** Creates new XmlSchemaSimpleTypeRestriction */
       public XmlSchemaSimpleTypeRestriction() {
  -		facets = new XmlSchemaObjectCollection();
  +        facets = new XmlSchemaObjectCollection();
  +    }
  +
  +    XmlSchemaSimpleType baseType;
  +
  +    public XmlSchemaSimpleType getBaseType() {
  +        return this.baseType;
  +    }
  +
  +    public void setBaseType(XmlSchemaSimpleType baseType) {
  +        this.baseType = baseType;
  +    }
  +
  +    QualifiedName baseTypeName;
  +
  +    public QualifiedName getBaseTypeName() {
  +        return this.baseTypeName;
  +    }
  +
  +    public void setBaseTypeName(QualifiedName baseTypeName) {
  +        this.baseTypeName = baseTypeName;
  +    }
  +
  +    XmlSchemaObjectCollection facets;// = new XmlSchemaObjectCollection();
  +
  +    public XmlSchemaObjectCollection getFacets() {
  +        return this.facets;
  +    }
  +
  +    public String toString(String prefix, int tab) {
  +        String xml = new String();
  +
  +        if (!prefix.equals("") && prefix.indexOf(":") == -1)
  +            prefix += ":";
  +
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +
  +        xml += "<" + prefix + "restriction ";
  +
  +        if (baseTypeName != null) {
  +            xml += "base =\"" + baseTypeName + "\">\n";
  +        } else {
  +            xml += ">\n";
  +            // inline def
  +            xml += baseType.toString(prefix, (tab + 1));
  +        }
  +
  +        xml += facets.toString(prefix, (tab + 1));
  +        for (int i = 0; i < tab; i++)
  +            xml += "\t";
  +        xml += "</" + prefix + "restriction>\n";
  +
  +
  +        return xml;
  +
       }
  -	
  -	XmlSchemaSimpleType baseType;
  -	
  -	public	XmlSchemaSimpleType getBaseType() {
  -		return this.baseType;
  -	}
  -	
  -	public void setBaseType( XmlSchemaSimpleType baseType ) {
  -		this.baseType = baseType;
  -	}
  -	
  -	QualifiedName baseTypeName;
  -	
  -	public QualifiedName getBaseTypeName(){
  -		return this.baseTypeName;
  -	}
  -	
  -	public void setBaseTypeName( QualifiedName baseTypeName ) {
  -		this.baseTypeName = baseTypeName;
  -	}
  -	
  -	XmlSchemaObjectCollection facets;// = new XmlSchemaObjectCollection();
  -	
  -	public XmlSchemaObjectCollection getFacets() {
  -		return this.facets;
  -	}
  -	
  -	public String toString(String prefix, int tab) {
  -		String xml = new String();
  -		
  -		if(!prefix.equals("") && prefix.indexOf(":") == -1)
  -			prefix += ":";
  -		
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		
  -		xml += "<"+prefix + "restriction ";
  -		
  -		if(baseTypeName != null) {
  -			xml += "base =\"" +  baseTypeName + "\">\n";
  -		} else {
  -			xml += ">\n";
  -			// inline def
  -			xml += baseType.toString(prefix, (tab+1));
  -		}	
  -		
  -		xml += facets.toString(prefix, (tab+1));
  -		for(int i=0;i<tab;i++)
  -			xml += "\t";
  -		xml += "</"+prefix+"restriction>\n";	
  -	
  -		
  -		return xml;
  -			
  -	}
   
   }
  
  
  
  1.2       +80 -24    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleTypeUnion.java
  
  Index: XmlSchemaSimpleTypeUnion.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaSimpleTypeUnion.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaSimpleTypeUnion.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaSimpleTypeUnion.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaSimpleTypeUnion.java
    *
    * Created on September 27, 2001, 3:39 AM
  @@ -7,6 +62,7 @@
   package org.apache.axis.xsd.xml.schema;
   
   import org.apache.axis.xsd.xml.QualifiedName;
  +
   /**
    * Class for the union of simpleType elements. Defines a simpleType element
    * as a list of values of a specified data type. Represents the World 
  @@ -15,30 +71,30 @@
    * @author  mukund
    */
   
  -public class XmlSchemaSimpleTypeUnion extends XmlSchemaSimpleTypeContent{
  +public class XmlSchemaSimpleTypeUnion extends XmlSchemaSimpleTypeContent {
  +
  +    XmlSchemaObjectCollection baseTypes;
  +    String memberTypesSource;
  +    QualifiedName[] memberTypesQNames;
  +
  +    public XmlSchemaSimpleTypeUnion() {
  +        baseTypes = new XmlSchemaObjectCollection();
  +    }
  +
  +    public XmlSchemaObjectCollection getBaseTypes() {
  +        return this.baseTypes;
  +    }
  +
  +    public void setMemberTypesSource(String memberTypesSources) {
  +        this.memberTypesSource = memberTypesSources;
  +    }
  +
  +    public String getMemberTypesSource() {
  +        return this.memberTypesSource;
  +    }
   
  -	XmlSchemaObjectCollection baseTypes;
  -	String memberTypesSource;
  -	QualifiedName[] memberTypesQNames;
  -
  -	public XmlSchemaSimpleTypeUnion() {
  -		baseTypes = new XmlSchemaObjectCollection();
  -	}
  -	
  -	public XmlSchemaObjectCollection getBaseTypes() {
  -		return this.baseTypes;
  -	}
  -	
  -	public void setMemberTypesSource( String memberTypesSources ){
  -		this.memberTypesSource = memberTypesSources;
  -	}
  -	
  -	public String getMemberTypesSource(){
  -		return this.memberTypesSource;
  -	}
  -        
  -	public QualifiedName[] getMemberTypesQNames(){
  -		return this.memberTypesQNames;
  -	}
  +    public QualifiedName[] getMemberTypesQNames() {
  +        return this.memberTypesQNames;
  +    }
   
   }
  
  
  
  1.2       +58 -3     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaTotalDigitsFacet.java
  
  Index: XmlSchemaTotalDigitsFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaTotalDigitsFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaTotalDigitsFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaTotalDigitsFacet.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaTotalDigitsFacet.java
    *
    * Created on September 27, 2001, 3:33 AM
  @@ -21,7 +76,7 @@
       public XmlSchemaTotalDigitsFacet() {
       }
   
  -	public XmlSchemaTotalDigitsFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  +    public XmlSchemaTotalDigitsFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   }
  
  
  
  1.2       +117 -61   xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaType.java
  
  Index: XmlSchemaType.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaType.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaType.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaType.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaType.java
    *
    * Created on September 27, 2001, 3:39 AM
  @@ -7,6 +62,7 @@
   package org.apache.axis.xsd.xml.schema;
   
   import org.apache.axis.xsd.xml.QualifiedName;
  +
   /**
    * The base class for all simple types and complex types.
    *
  @@ -17,65 +73,65 @@
   
   public class XmlSchemaType extends XmlSchemaAnnotated {
   
  -	Object baseSchemaType;
  -	XmlSchemaDatatype dataType;
  -	XmlSchemaDerivationMethod deriveBy, finalDerivation, finalResolved;
  -	boolean isMixed;
  -	
  -	// name of the type
  -	String name;
  -	QualifiedName qualifiedName;
  -	
  -	/** Creates new XmlSchemaType */
  -	public XmlSchemaType() {
  -		finalDerivation = new XmlSchemaDerivationMethod("None");
  -	}
  -	
  -	public Object getBaseSchemaType() {
  -		return baseSchemaType;
  -	}
  -	
  -	public XmlSchemaDatatype getDataType() {
  -		return dataType;
  -	}
  -	
  -	public XmlSchemaDerivationMethod getDeriveBy() {
  -		return deriveBy;
  -	}
  -	
  -	public XmlSchemaDerivationMethod getFinal() {
  -		return finalDerivation;
  -	}
  -	
  -	public void setFinal(XmlSchemaDerivationMethod finalDerivation) {
  -		this.finalDerivation = finalDerivation;
  -	}
  -	
  -	public XmlSchemaDerivationMethod getFinalResolved() {
  -		return finalResolved;
  -	}
  -	
  -	public boolean isMixed() {
  -		return isMixed;
  -	}
  -	
  -	public void setMixed(boolean isMixed) {
  -		this.isMixed = isMixed;
  -	}
  -	
  -	public String getName() {
  -		return name;
  -	}
  -	
  -	public void setName(String name) {
  -		this.name = name;
  -	}
  -	
  -	public QualifiedName getQualifiedName() {
  -		return qualifiedName;
  -	}
  -	
  -	public void setQualifiedName(QualifiedName qName) {
  -		this.qualifiedName = qName;
  -	}
  +    Object baseSchemaType;
  +    XmlSchemaDatatype dataType;
  +    XmlSchemaDerivationMethod deriveBy, finalDerivation, finalResolved;
  +    boolean isMixed;
  +
  +    // name of the type
  +    String name;
  +    QualifiedName qualifiedName;
  +
  +    /** Creates new XmlSchemaType */
  +    public XmlSchemaType() {
  +        finalDerivation = new XmlSchemaDerivationMethod("None");
  +    }
  +
  +    public Object getBaseSchemaType() {
  +        return baseSchemaType;
  +    }
  +
  +    public XmlSchemaDatatype getDataType() {
  +        return dataType;
  +    }
  +
  +    public XmlSchemaDerivationMethod getDeriveBy() {
  +        return deriveBy;
  +    }
  +
  +    public XmlSchemaDerivationMethod getFinal() {
  +        return finalDerivation;
  +    }
  +
  +    public void setFinal(XmlSchemaDerivationMethod finalDerivation) {
  +        this.finalDerivation = finalDerivation;
  +    }
  +
  +    public XmlSchemaDerivationMethod getFinalResolved() {
  +        return finalResolved;
  +    }
  +
  +    public boolean isMixed() {
  +        return isMixed;
  +    }
  +
  +    public void setMixed(boolean isMixed) {
  +        this.isMixed = isMixed;
  +    }
  +
  +    public String getName() {
  +        return name;
  +    }
  +
  +    public void setName(String name) {
  +        this.name = name;
  +    }
  +
  +    public QualifiedName getQualifiedName() {
  +        return qualifiedName;
  +    }
  +
  +    public void setQualifiedName(QualifiedName qName) {
  +        this.qualifiedName = qName;
  +    }
   }
  
  
  
  1.2       +56 -1     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaUnique.java
  
  Index: XmlSchemaUnique.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaUnique.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaUnique.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaUnique.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaUnique.java
    *
    * Created on September 27, 2001, 3:35 AM
  @@ -13,7 +68,7 @@
    * @author  mukund
    */
   
  -public class XmlSchemaUnique extends XmlSchemaIdentityConstraint  {
  +public class XmlSchemaUnique extends XmlSchemaIdentityConstraint {
   
       /** Creates new XmlSchemaUnique */
       public XmlSchemaUnique() {
  
  
  
  1.2       +67 -12    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaUse.java
  
  Index: XmlSchemaUse.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaUse.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaUse.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaUse.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaUse.java
    *
    * Created on September 27, 2001, 3:05 AM
  @@ -15,20 +70,20 @@
    */
   public class XmlSchemaUse extends Enum {
   
  -	static String[] members = new String[] { "None", "Optional", 
  -											 "Prohibited", "Required"};
  -	
  +    static String[] members = new String[]{"None", "Optional",
  +                                           "Prohibited", "Required"};
  +
       /** Creates new XmlSchemaUse */
       public XmlSchemaUse() {
  -		super();
  +        super();
  +    }
  +
  +    public XmlSchemaUse(String value) {
  +        super(value);
  +    }
  +
  +    public String[] getValues() {
  +        return members;
       }
  -	
  -	public XmlSchemaUse(String value) {
  -		super(value);
  -	}
  -	
  -	public String[] getValues() {
  -		return members;
  -	}
   
   }
  
  
  
  1.2       +58 -3     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaWhiteSpaceFacet.java
  
  Index: XmlSchemaWhiteSpaceFacet.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaWhiteSpaceFacet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaWhiteSpaceFacet.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaWhiteSpaceFacet.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaWhiteSpaceFacet.java
    *
    * Created on September 27, 2001, 3:33 AM
  @@ -21,7 +76,7 @@
       public XmlSchemaWhiteSpaceFacet() {
       }
   
  -	public XmlSchemaWhiteSpaceFacet(Object value, boolean fixed) {
  -		super( value, fixed );
  -	}
  +    public XmlSchemaWhiteSpaceFacet(Object value, boolean fixed) {
  +        super(value, fixed);
  +    }
   }
  
  
  
  1.2       +64 -9     xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaXPath.java
  
  Index: XmlSchemaXPath.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSchemaXPath.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSchemaXPath.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSchemaXPath.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSchemaXPath.java
    *
    * Created on September 27, 2001, 3:40 AM
  @@ -21,13 +76,13 @@
       public XmlSchemaXPath() {
       }
   
  -	String xpath;
  -	
  -	public String getXPath() {
  -		return xpath;
  -	}
  -	
  -	public void setXPath(String xpath) {
  -		this.xpath = xpath;
  -	}
  +    String xpath;
  +
  +    public String getXPath() {
  +        return xpath;
  +    }
  +
  +    public void setXPath(String xpath) {
  +        this.xpath = xpath;
  +    }
   }
  
  
  
  1.2       +68 -13    xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSeverityType.java
  
  Index: XmlSeverityType.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/proposals/XmlSchema/src/org/apache/axis/xsd/xml/schema/XmlSeverityType.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- XmlSeverityType.java	17 Nov 2002 23:25:58 -0000	1.1
  +++ XmlSeverityType.java	17 Nov 2002 23:53:19 -0000	1.2
  @@ -1,4 +1,59 @@
   /*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *    Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +/*
    * XmlSeverityType.java
    *
    * Created on September 27, 2001, 3:06 AM
  @@ -14,20 +69,20 @@
    * @author  mukund
    */
   
  -public class XmlSeverityType extends Enum	{
  +public class XmlSeverityType extends Enum {
  +
  +    static String[] members = new String[]{"Error", "Warning"};
   
  -	static String[] members = new String[] { "Error", "Warning"};
  -	
       /** Creates new XmlSeverityType */
       public XmlSeverityType() {
  -		super();
  -	}
  -	
  -	public XmlSeverityType(String value) {
  -		super(value);
  -	}
  -	
  -	public String[] getValues() {
  -		return members;
  -	}
  +        super();
  +    }
  +
  +    public XmlSeverityType(String value) {
  +        super(value);
  +    }
  +
  +    public String[] getValues() {
  +        return members;
  +    }
   }
  
  
  

Mime
View raw message