Package net.sf.saxon.type

## Interface SchemaComponent

- All Known Subinterfaces:
    `AtomicType`, `ComplexType`, `ListType`, `SchemaType`, `SimpleType`, `UserSchemaComponent`
  All Known Implementing Classes:
    `AllModelGroup`, `AnySimpleType`, `AnyType`, `Assertion`, `AttributeDecl`, `AttributeGroupDecl`, `AttributeUse`, `AttributeWildcard`, `BuiltInAtomicType`, `BuiltInListType`, `ChoiceModelGroup`, `Edge.MaxOccursParticle`, `ElementDecl`, `ElementParticle`, `ElementWildcard`, `ErrorType`, `IdentityConstraint`, `Key`, `KeyRef`, `ModelGroup`, `ModelGroupDefinition`, `ModelGroupParticle`, `Notation`, `NumericType`, `Particle`, `SequenceModelGroup`, `SimpleTypeDefinition`, `TypeAlternative`, `Unique`, `Untyped`, `UserAtomicType`, `UserComplexType`, `UserDefinedType`, `UserListType`, `UserSimpleType`, `UserUnionType`, `Wildcard`

      public interface SchemaComponent

  This is a marker interface that represents any "schema component" as defined in the XML Schema specification. This may be a user-defined schema component or a built-in schema component. Since all built-in schema components are types, every SchemaComponent in practice is either a `UserSchemaComponent` or a `SchemaType` or both.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Interface | Description
    --- | --- | ---
    `static class` | `SchemaComponent.ValidationStatus` |

  - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `static FunctionItemType` | `COMPONENT_FUNCTION_TYPE` | The function type of the function returned by getComponentAsFunction()

  - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `Function` | `getComponentAsFunction()` | Get the schema component in the form of a function item.
    `int` | `getRedefinitionLevel()` | Get the redefinition level.
    `SchemaComponent.ValidationStatus` | `getValidationStatus()` | Get the validation status of this component.

- - ### Field Detail

    - #### COMPONENT_FUNCTION_TYPE

          static final FunctionItemType COMPONENT_FUNCTION_TYPE

      The function type of the function returned by getComponentAsFunction()

  - ### Method Detail

    - #### getValidationStatus

          SchemaComponent.ValidationStatus getValidationStatus()

      Get the validation status of this component.
      Returns:
        one of the values `SchemaComponent.ValidationStatus.UNVALIDATED`, `SchemaComponent.ValidationStatus.VALIDATING`, `SchemaComponent.ValidationStatus.VALIDATED`, `SchemaComponent.ValidationStatus.INVALID`, `SchemaComponent.ValidationStatus.INCOMPLETE`

    - #### getRedefinitionLevel

          int getRedefinitionLevel()

      Get the redefinition level. This is zero for a component that has not been redefined; for a redefinition of a level-0 component, it is 1; for a redefinition of a level-N component, it is N+1. This concept is used to support the notion of "pervasive" redefinition: if a component is redefined at several levels, the top level wins, but it is an error to have two versions of the component at the same redefinition level.
      Returns:
        the redefinition level

    - #### getComponentAsFunction

          Function getComponentAsFunction()

      Get the schema component in the form of a function item. This allows schema information to be made visible to XSLT or XQuery code. The function makes available the contents of the schema component as defined in the XSD specification. The function takes a string as argument representing a property name, and returns the corresponding property of the schema component. There is also a property "class" which returns the kind of schema component, for example "Attribute Declaration".
      Returns:
        the schema component represented as a function from property names to property values.