Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > xs:anyType

Reply
Thread Tools

xs:anyType

 
 
Igor Akkerman
Guest
Posts: n/a
 
      07-31-2003
Hi,

why does

<xs:element name="any" type="xs:anyType" />

not validate

<any><foo><bar>blah</bar></foo></any> ?

Isn't xs:anyType meant to accept any well-formed xml-tree?

Igor
 
Reply With Quote
 
 
 
 
Jesper Zedlitz
Guest
Posts: n/a
 
      07-31-2003
> why does
> <xs:element name="any" type="xs:anyType" />
> not validate
> <any><foo><bar>blah</bar></foo></any> ?
>
> Isn't xs:anyType meant to accept any well-formed xml-tree?
>

No, "xs:anyType" is the root *type* of W3C's type definitions (like
java.lang.Object).
What you are looking for is the <xs:any/> element.
http://www.w3.org/TR/xmlschema-1/#element-any

Jesper

--
Jesper Zedlitz eMail : http://www.velocityreviews.com/forums/(E-Mail Removed)
Homepage : http://www.zedlitz.de
ICQ# : 23890711
PGP-Key : http://zedlitz.de/pub_key.asc
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off




Advertisments