Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > The following XML Schema restrictions donít make sense

Reply
Thread Tools

The following XML Schema restrictions donít make sense

 
 
sqlsurfing sqlsurfing is offline
Junior Member
Join Date: Jan 2010
Posts: 1
 
      01-27-2010
hi

1) As far as I can tell, only elements can be declared inside <group>declaration, but not attributes. Thus the following text will cause Xml Schema validator to report an error:

Code:
  <group name="NameGroup">
    <sequence>
        <element name="first" type="string"></element>
        <attribute name="title" type="string"/> 
    </sequence>
  </group>
Is there a particular reason why allowing attributes to be declared within <group>declaration would be a bad idea?



2) minOccurs and maxOccurs attributes are not permitted within global element declarations. Why is that?



3) Is the reason why weíre only able to refer ( using ref attribute ) to global elements but not local elements due to the fact that only they are guaranteed to have a unique name, while that is not the case with local elements?



4) An element declaration canít use type attribute to refer to global type and at the same time create local type. But what if you want this element declaration to also have an attribute which isnít declared within a global type?



thanx
 
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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Does the following java programming architecture make sense? mike Java 1 04-20-2005 06:21 PM
Does the following programming architecture make sense? mike Java 0 04-05-2005 05:21 PM
Does the following programming architecture make sense? mike C Programming 0 04-05-2005 08:42 AM
Does the following programming architecture make sense? mike Java 0 04-05-2005 08:35 AM
Does the following programming architecture make sense? mike Java 0 03-28-2005 07:32 AM



Advertisments