|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.saxonica.schema.SchemaStructure
com.saxonica.schema.AttributeDecl
An XML Schema Attribute Declaration. This includes global attribute declarations, local attribute declarations, and "attribute uses". It corresponds to either (a) an attribute declaration schema component for a global attribute, or (b) an attribute declaration schema component for a local attribute, plus an attribute use referencing that attribute declaration, or (c) an attribute use referencing a global attribute declaration.
| Field Summary |
| Fields inherited from interface net.sf.saxon.type.SchemaComponent |
FIXED_UP, INCOMPLETE, INVALID, UNVALIDATED, VALIDATED, VALIDATING |
| Constructor Summary | |
AttributeDecl(PreparedSchema schema)
Creates a new AttrDecl in the given schema. |
|
| Method Summary | |
boolean |
fixup(PreparedSchema schema)
Check references from this component to other components |
java.lang.String |
getDefaultValue()
Returns the default value of this attribute declaration. |
java.lang.String |
getDisplayName()
Returns the name of the attribute defined by this AttributeDecl. |
int |
getFingerprint()
Gets the fingerprint of this attribute name |
Value |
getFixedValue()
Returns the fixed value of this attribute declaration. |
int |
getNameCode()
Get the nameCode of the name of this element declaration in the namePool |
SimpleType |
getSimpleType()
Get the type associated with this Attribute Declaration. |
SchemaType |
getType()
Get the type: satisfies SchemaDeclaration interface |
boolean |
isSameDeclaration(AttributeDecl other)
Test whether this is the same type as another type. |
void |
setDefaultValue(java.lang.String value)
Sets the DEFAULT value. |
void |
setFixedValue(Value value)
Sets the FIXED value. |
void |
setNameCode(int nameCode)
Set the fingerprint for this attribute name. |
void |
setNamespaceResolver(NamespaceResolver resolver)
Set the namespace resolver for resolving QName-valued fixed and default values |
void |
setSimpleType(UserSimpleType simpleType)
Sets the SimpleType for this attribute declaration. |
void |
setTypeFingerprint(int fingerprint)
Set the namepool fingerprint of the name of the element's type. |
boolean |
testFixedValue(java.lang.CharSequence value,
NamespaceResolver resolver)
Test a value against the fixed value. |
boolean |
validate(PreparedSchema schema)
Checks the validity of this Attribute declaration |
| Methods inherited from class com.saxonica.schema.SchemaStructure |
getColumnNumber, getFixupStatus, getLineNumber, getPublicId, getSchema, getSystemId, getValidationStatus, lookForCycles, setFixupStatus, setLineNumber, setLocator, setSchema, setSystemId, setValidationStatus |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.saxonica.schema.UserSchemaComponent |
lookForCycles |
| Methods inherited from interface net.sf.saxon.type.SchemaComponent |
getValidationStatus |
| Constructor Detail |
public AttributeDecl(PreparedSchema schema)
schema - the schema that contains the new attrDecl| Method Detail |
public java.lang.String getDisplayName()
public void setNameCode(int nameCode)
public int getFingerprint()
public int getNameCode()
public SimpleType getSimpleType()
throws UnresolvedReferenceException
UnresolvedReferenceException
public SchemaType getType()
throws UnresolvedReferenceException
getType in interface SchemaDeclarationUnresolvedReferenceExceptionpublic void setTypeFingerprint(int fingerprint)
public java.lang.String getDefaultValue()
public Value getFixedValue()
public void setSimpleType(UserSimpleType simpleType)
simpleType - the SimpleType for this attribute
declarationpublic void setDefaultValue(java.lang.String value)
public void setFixedValue(Value value)
public void setNamespaceResolver(NamespaceResolver resolver)
public boolean fixup(PreparedSchema schema)
throws SchemaException,
UnresolvedReferenceException
fixup in interface UserSchemaComponentschema - The schema is used for reporting errors
SchemaException
UnresolvedReferenceException
public boolean validate(PreparedSchema schema)
throws SchemaException,
ValidationException
validate in interface UserSchemaComponentschema - if this is not null, any errors that are detected should
be reported using the error() method of this schema.
SchemaException - if the error listener decides an error is fatal
ValidationException
public boolean testFixedValue(java.lang.CharSequence value,
NamespaceResolver resolver)
throws ValidationException
value - the value to be tested
ValidationException - if the value is not valid for this typepublic boolean isSameDeclaration(AttributeDecl other)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||