Monday, 2 January 2012

XSD and Namespaces

  • NCName = non-colonized name, QName = qualified name
  • a schema is not required to have a namespace. The noNamespaceSchemaLocation attribute provides hints for the locations of schema documents that do not have target namespaces (like schemaLocation)
  • import refers to declarations or definitions that are in a different target namespace while include refers to the same target namespace. Only global schema components can be imported
  • To validate a traditional XML 1.0 document which does not use namespaces at all, you must provide a schema with no target namespace
  • The redefine attribute allows simple and complex types, groups, and attribute groups that are obtained from external schema files to be redefined in the current schema