The fact that an element can be nil is defined in the element
definition and short-circuits all the content type definitions. It
may be used for simple types, complex content, and simple content
complex types; and it may be used even if the content model forbids
empty contents. In this case, the
"nillable" character of the element
takes precedence over the content model, and empty contents will be
accepted when marked as nil. Again, since the fact that a value is
nil is expressed using an attribute in the instance document, the
mechanism does not apply to attributes that cannot have a null value.
One last thing to note before we look at some examples is that
attributes are not affected by the fact that an element is nil, and
they are still allowed or required if defined in the element.