Child pages
  • XML Validation

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3
Info
titleStatus

This page is under development. Nothing has been finalized.

All XML stored in the repository must validate against a standard format, such as an XML schema or DTD.

General validation requirements

  • Validation files (schemas, DTDs, etc.) should normally be referenced at their "primary" location (the location normally published as the home of the files).
  • In cases where an end-user process includes a validation step, the process should use a copy of the the validation files stored at IU, to provide adequate performance and availability.
    • It is preferable that local copies of validation files accessible via a URL beginning with "http://dlib.indiana.edu/xml/".

XML Schema requirements

Rquirements for schemas:

  • XML that validates against a schema must declare the schema in an xsi:schemaLocation attribute.

For schemas created at IU:

  • The schema namespace must begin with "http://dlib.indiana.edu/xml/"
  • The schema namespace and actual schema location must be as similar as possible.
  • Both the schema namespace and schema location must contain a verson number.

Sample IU schema:

XML Schemas defined by us

Schema name

Namespace

Root element

Description

IUDL Admin

http://dlib.indiana.edu/xml/iudlAdmin/version1.0/

iudlAdmin

This schema is used by SRU/W when returning search results

Fedora Administrative

(propose a namespace. e.g. http://www.dlib.indiana.edu/xml/itemAdmin/version1.0/)

iudlAdmin

This schema is used for storing the status of an item in our Fedora repository. The root element is given the same name as the IUDL Admin and should possibly be renamed to avoid confusion in the future. This schema does not have a schema definition.

RDF Relationships

http://dlib.indiana.edu/lib/xml/infrastructure/rdfRelations#

 

This is used in the RELS-EXT XML and refer to our extensions (for example, for the sequence number for pages). This does not have an explicit schema definition. Note that this has an extra lib in the namespace and no version info.

Collection-Specific DTDs or other resources

When a DTD is collection specific, we have a PURL format that may resolve to that file. Ultimately these files might be stored in the collection object in fedora, but for now they resolve to the above mentioned URLs.