XML Tutorial/XML Schema/anyAttribute — различия между версиями

Материал из Web эксперт
Перейти к: навигация, поиск
 
м (1 версия)
 
(нет различий)

Текущая версия на 11:26, 26 мая 2010

Attribute Wildcards

   <source lang="xml">

To declare an attribute wildcard, use the <anyAttribute>declaration: <anyAttribute namespace="allowable namespaces"

             processContents="lax or skip or strict"> 

The <anyAttribute>declaration can appear only within a <complexType> or <attributeGroup> declaration. You are not allowed to create global <anyAttribute> declarations. The namespace attribute allows several values:

    1. any allows attributes from all namespaces to be included as part of the wildcard
    2. other allows attributes from namespaces other than the targetNamespace to be included as part of the wildcard
    3. targetNamespace allows attributes from only the targetNamespace to be included as part of the wildcard
    4. local allows attributes that are not qualified by a namespace to be included as part of the wildcard

Whitespace-separated list of allowable namespace URIs allows attributes from any listed namespaces to be included

 as part of the wildcard. Possible list values also include ##targetNamespaceand ##local.</source>