org.jbind.xml.schema.cmp
Class AttrRef
java.lang.Object
org.jbind.xml.schema.cmp.Component
org.jbind.xml.schema.cmp.AttrDesc
org.jbind.xml.schema.cmp.AttrRefOrDecl
org.jbind.xml.schema.cmp.AttrRef
- All Implemented Interfaces:
- IAttrDesc, IAttrRef, IAttrRefOrDecl, IComponent, IDataDesc, IDataRefOrDecl, IDefaultTextContentProvider, IHasBindingAttributes, IHasLocation, ISourceInfo
- public class AttrRef
- extends AttrRefOrDecl
- implements IAttrRef
Methods inherited from class org.jbind.xml.schema.cmp.Component |
addSubComponent, getAnnotation, getBindings, getDefaultedLocalStringBindingAttribute, getGlobalRef, getLocalStringBindingAttribute, getLocation, getName, getNamespace, getParentComponent, getPrefixToNamespaceMapping, getStringBindingAttribute, isAnonymous, isTopLevelComponent, setBindings, setParentComponent, visitSubComponents |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.jbind.xml.core.cmp.IComponent |
addSubComponent, getBindings, getGlobalRef, getName, getNamespace, getParentComponent, getSymbolspace, isAnonymous, isTopLevelComponent, setBindings, setParentComponent, validate |
AttrRef
public AttrRef(ISourceInfo aSourceInfo,
AttributeOccurence anOccurence,
IAttrRefOrDecl anAttr)
accept
public void accept(IComponentVisitor aVisitor)
throws XmlException
- Description copied from interface:
IComponent
- Accepts a visitor. The implementation calls the corresponding visitXXXStart
and vistXXXEnd methods of the visitor (e.g.
visitComplexTypeStart
and visitComplexTypeEnd
).
- Specified by:
accept
in interface IComponent
- Parameters:
aVisitor
- (required).
- Throws:
XmlException
addValueConstraints
public void addValueConstraints(java.lang.String aDefault,
java.lang.String aFixed,
IConstraintViolations aViolations)
- Specified by:
addValueConstraints
in interface IDataRefOrDecl
getType
public IAnyType getType()
- Description copied from interface:
IDataDesc
- Gets the data type.
- Specified by:
getType
in interface IDataDesc
- Returns:
- (required).
hasDefaultType
public boolean hasDefaultType()
- Description copied from interface:
IAttrRefOrDecl
- Indicates if the attribute declaration has an explicitly assigned type or
if it got the "anySimpleType" by default.
- Specified by:
hasDefaultType
in interface IAttrRefOrDecl
- Returns:
- Returns
true
iff the declaration got the default type.
isReference
public boolean isReference()
- Description copied from interface:
IComponent
- Checks if this component is defined as a reference to another component.
- Specified by:
isReference
in interface IComponent
- Returns:
- Returns
true
iff this component is a reference to
another component.
getBindingAttribute
public IAttribute getBindingAttribute(java.lang.String aName)
- Description copied from interface:
IHasBindingAttributes
- Gets the specified binding attribute. The attribute may be searched in different
contexts (for example a schema component may asked its ancestor component
and its schema for the specified attribute. The the first occurence is returned.
- Specified by:
getBindingAttribute
in interface IHasBindingAttributes
- Overrides:
getBindingAttribute
in class Component
getLocalBindingAttribute
public IAttribute getLocalBindingAttribute(java.lang.String aName)
- Description copied from interface:
IHasBindingAttributes
- Gets a local binding attribute.
- Specified by:
getLocalBindingAttribute
in interface IHasBindingAttributes
- Overrides:
getLocalBindingAttribute
in class Component
getDefaultedLocalBindingAttribute
public IAttribute getDefaultedLocalBindingAttribute(java.lang.String aName)
- Description copied from interface:
IHasBindingAttributes
- Gets a local binding attribute. If the binding attribute is not
specified locally then a default value is looked for.
Default values can be specified on schema elements. If a schema is included
by another schema then the default values of the parent schema are considered too.
- Specified by:
getDefaultedLocalBindingAttribute
in interface IHasBindingAttributes
- Overrides:
getDefaultedLocalBindingAttribute
in class Component