FileDocCategorySizeDatePackage
XSTypeDefinition.javaAPI DocApache Xerces 3.0.14222Fri Sep 14 20:33:54 BST 2007org.apache.xerces.xs

XSTypeDefinition

public interface XSTypeDefinition implements XSObject
This interface represents a complex or simple type definition.

Fields Summary
public static final short
COMPLEX_TYPE
The object describes a complex type.
public static final short
SIMPLE_TYPE
The object describes a simple type.
Constructors Summary
Methods Summary
public booleanderivedFrom(java.lang.String namespace, java.lang.String name, short derivationMethod)
Convenience method which checks if this type is derived from the given ancestor type.

param
namespace An ancestor type namespace.
param
name An ancestor type name.
param
derivationMethod A bit combination representing a subset of { DERIVATION_RESTRICTION, DERIVATION_EXTENSION, DERIVATION_UNION, DERIVATION_LIST }.
return
True if this type is derived from ancestorType using only derivation methods from the derivationMethod .

public booleanderivedFromType(org.apache.xerces.xs.XSTypeDefinition ancestorType, short derivationMethod)
Convenience method which checks if this type is derived from the given ancestorType.

param
ancestorType An ancestor type definition.
param
derivationMethod A bit combination representing a subset of { DERIVATION_RESTRICTION, DERIVATION_EXTENSION, DERIVATION_UNION, DERIVATION_LIST }.
return
True if this type is derived from ancestorType using only derivation methods from the derivationMethod .

public booleangetAnonymous()
Convenience attribute. A boolean that specifies if the type definition is anonymous.

public org.apache.xerces.xs.XSTypeDefinitiongetBaseType()
{base type definition}: either a simple type definition or a complex type definition.

public shortgetFinal()
For complex types the returned value is a bit combination of the subset of {DERIVATION_EXTENSION, DERIVATION_RESTRICTION} corresponding to final set of this type or DERIVATION_NONE. For simple types the returned value is a bit combination of the subset of { DERIVATION_RESTRICTION, DERIVATION_EXTENSION, DERIVATION_UNION, DERIVATION_LIST } corresponding to final set of this type or DERIVATION_NONE.

public shortgetTypeCategory()
Return whether this type definition is a simple type or complex type.

public booleanisFinal(short restriction)
{final}. For a complex type definition it is a subset of {extension, restriction}. For a simple type definition it is a subset of {extension, list, restriction, union}.

param
restriction Extension, restriction, list, union constants (defined in XSConstants).
return
True if restriction is in the final set, otherwise false.