org.apache.ws.jaxme.xs.impl

Class XSSchemaImpl

Implemented Interfaces:
XSObject, XSOpenAttrs, XSSchema
Known Direct Subclasses:
JAXBSchemaImpl

public class XSSchemaImpl
extends java.lang.Object
implements XSSchema

Implementation of an XML Schema, as defined by the XSSchema interface.
Author:
Jochen Wiedmann

Constructor Summary

XSSchemaImpl(XSContext pContext, XsESchema pSchema)
Creates a new logical schema by loading data, which represents the given syntactical schema pSchema and uses the given context pContext for acquiring additional information.

Method Summary

void
add(XSAnnotation pAnnotation)
void
add(XSAttribute pAttribute)
void
add(XSAttributeGroup pGroup)
void
add(XSElement pElement)
void
add(XSGroup pGroup)
void
add(XSIdentityConstraint ic)
void
add(XSKeyRef rf)
void
add(XSNotation pNotation)
void
add(XSType pType)
protected void
addChild(Object pChild)
Adds a new child to the array returned by getChilds().
XSAnnotation[]
getAnnotations()
XSAttribute
getAttribute(XsQName pQName)
XSAttributeGroup
getAttributeGroup(XsQName pName)
XSAttributeGroup[]
getAttributeGroups()
XSAttribute[]
getAttributes()
XSType[]
getBuiltinTypes()
Object[]
getChilds()
XSContext
getContext()
XSElement
getElement(XsQName pName)
XSElement[]
getElements()
XSGroup
getGroup(XsQName pName)
XSGroup[]
getGroups()
Map
getIdentityConstraints()
Map
getKeyRefs()
Locator
getLocator()
Attributes
getOpenAttributes()
XSObject
getParentObject()
XsAnyURI
getTargetNamespace()
XSType
getType(XsQName pName)
XSType[]
getTypes()
XSObjectFactory
getXSObjectFactory()
XSSchema
getXSSchema()
protected XsESchema
getXsESchema()
boolean
isTopLevelObject()
protected boolean
isValidated()
void
redefine(XSAttributeGroup pGroup)
void
redefine(XSGroup pGroup)
void
redefine(XSType pType)
protected void
replace(Object pOldChild, Object pNewChild)
Replaces the existing child pOldChild with the replacement object pNewChild.
void
validate()
protected void
validate(Object pChild)

Constructor Details

XSSchemaImpl

public XSSchemaImpl(XSContext pContext,
                    XsESchema pSchema)
Creates a new logical schema by loading data, which represents the given syntactical schema pSchema and uses the given context pContext for acquiring additional information.

Method Details

add

public void add(XSAnnotation pAnnotation)
Specified by:
add in interface XSSchema

add

public void add(XSAttribute pAttribute)
            throws SAXException
Specified by:
add in interface XSSchema

add

public void add(XSAttributeGroup pGroup)
            throws SAXException
Specified by:
add in interface XSSchema

add

public void add(XSElement pElement)
            throws SAXException
Specified by:
add in interface XSSchema

add

public void add(XSGroup pGroup)
            throws SAXException
Specified by:
add in interface XSSchema

add

public void add(XSIdentityConstraint ic)
            throws SAXException
Specified by:
add in interface XSSchema

add

public void add(XSKeyRef rf)
            throws SAXException
Specified by:
add in interface XSSchema

add

public void add(XSNotation pNotation)
Specified by:
add in interface XSSchema

add

public void add(XSType pType)
            throws SAXException
Specified by:
add in interface XSSchema

addChild

protected void addChild(Object pChild)

getAnnotations

public XSAnnotation[] getAnnotations()
Specified by:
getAnnotations in interface XSSchema

getAttribute

public XSAttribute getAttribute(XsQName pQName)
Specified by:
getAttribute in interface XSSchema

getAttributeGroup

public XSAttributeGroup getAttributeGroup(XsQName pName)
Specified by:
getAttributeGroup in interface XSSchema

getAttributeGroups

public XSAttributeGroup[] getAttributeGroups()
Specified by:
getAttributeGroups in interface XSSchema

getAttributes

public XSAttribute[] getAttributes()
Specified by:
getAttributes in interface XSSchema

getBuiltinTypes

public XSType[] getBuiltinTypes()
Specified by:
getBuiltinTypes in interface XSSchema

getChilds

public Object[] getChilds()
Specified by:
getChilds in interface XSSchema

getContext

public XSContext getContext()
Specified by:
getContext in interface XSSchema

getElement

public XSElement getElement(XsQName pName)
Specified by:
getElement in interface XSSchema

getElements

public XSElement[] getElements()
Specified by:
getElements in interface XSSchema

getGroup

public XSGroup getGroup(XsQName pName)
Specified by:
getGroup in interface XSSchema

getGroups

public XSGroup[] getGroups()
Specified by:
getGroups in interface XSSchema

getIdentityConstraints

public Map getIdentityConstraints()
Specified by:
getIdentityConstraints in interface XSSchema

getKeyRefs

public Map getKeyRefs()
Specified by:
getKeyRefs in interface XSSchema

getLocator

public Locator getLocator()
Specified by:
getLocator in interface XSObject

getOpenAttributes

public Attributes getOpenAttributes()
Specified by:
getOpenAttributes in interface XSOpenAttrs

getParentObject

public XSObject getParentObject()
Specified by:
getParentObject in interface XSObject

getTargetNamespace

public XsAnyURI getTargetNamespace()
Specified by:
getTargetNamespace in interface XSSchema

getType

public XSType getType(XsQName pName)
Specified by:
getType in interface XSSchema

getTypes

public XSType[] getTypes()
Specified by:
getTypes in interface XSSchema

getXSObjectFactory

public XSObjectFactory getXSObjectFactory()
Specified by:
getXSObjectFactory in interface XSSchema

getXSSchema

public XSSchema getXSSchema()
Specified by:
getXSSchema in interface XSObject

getXsESchema

protected XsESchema getXsESchema()

isTopLevelObject

public boolean isTopLevelObject()
Specified by:
isTopLevelObject in interface XSObject

isValidated

protected boolean isValidated()

redefine

public void redefine(XSAttributeGroup pGroup)
            throws SAXException
Specified by:
redefine in interface XSSchema

redefine

public void redefine(XSGroup pGroup)
            throws SAXException
Specified by:
redefine in interface XSSchema

redefine

public void redefine(XSType pType)
            throws SAXException
Specified by:
redefine in interface XSSchema

replace

protected void replace(Object pOldChild,
                       Object pNewChild)
Replaces the existing child pOldChild with the replacement object pNewChild. This method is used from within the various redefine() methods.

validate

public void validate()
            throws SAXException
Specified by:
validate in interface XSObject

validate

protected void validate(Object pChild)
            throws SAXException