- From: Priya Lakshminarayanan <priyal@microsoft.com>
- Date: Thu, 31 Jan 2002 12:57:42 -0800
- To: "Stanley Guan" <stanley.guan@oracle.com>, "Schema XML" <xmlschema-dev@w3.org>
If an element is declared without specifying its type, then its implicit
type is the built-in anyType.
From the spec: http://www.w3.org/TR/xmlschema-1/#cElement_Declarations
The type definition corresponding to the <simpleType> or <complexType>
element information item in the [children], if either is present,
otherwise the type definition *resolved* to by the *actual value* of the
type [attribute], otherwise the {type definition} of the element
declaration *resolved* to by the *actual value* of the substitutionGroup
[attribute], if present, otherwise the *ur-type definition*.
2.2.1.1 Type Definition Hierarchy
[Definition:] A distinguished ur-type definition is present in each
*XML Schema*, serving as the root of the type definition hierarchy for
that schema. The ur-type definition, whose name is anyType, has the
unique characteristic that it can function as a complex or a simple type
definition, according to context.
In this case, it would be the ur-type definition which is the built-in
anyType.
Thanks,
Priya
-----Original Message-----
From: Stanley Guan [mailto:stanley.guan@oracle.com]
Sent: Tuesday, January 29, 2002 3:11 PM
To: Schema XML
Subject: xsd:anyType
Hi,
I think if an element is declared as:
<xsd:element name="anything">
it should accept empty content as its content. But, can someone
point out to me where in the specification this validation rule is
covered?
Thanks,
-Stanley
Received on Thursday, 31 January 2002 15:58:20 UTC