I agree, but then I think that defaulted attributes are one of the
annoying features of XML and SGML.   

-----Original Message-----
From: PREMIS Implementors Group Forum [mailto:[log in to unmask]] On Behalf Of
Priscilla Caplan
Sent: Monday, September 12, 2005 11:28 AM
To: [log in to unmask]
Subject: Re: [PIG] opinions on schema style

Gee, actually the second is easier for me to read, as a human, because I
don't have to look up what the default is.


Ray Denenberg, Library of Congress wrote:
> Consider the following:
>  <sequence>
>    <element name="a"/>
>     <element name="b" />
>     <element name="c" />
>     <element name="d"  type="anyURI" />
>     <element name="e" maxOccurs="unbounded" />
>     <element name="f" minOccurs="0"/>
>     <element name="g"  minOccurs="0" maxOccurs="unbounded"/> .....
> It says: "elements a, b, c, d occur exactly once; e is mandatory and 
> repeatable, f is optional (not repeatable), g is optional and 
> repeatable; all are type string except d which is type anyURI."
> And consider:
>  <sequence>
>    <element name="a" minOccurs="1" maxOccurs="1" type="string">
>    <element name="b" minOccurs="1" maxOccurs="1" type="string"/>
>     <element name="c" minOccurs="1" maxOccurs="1" type="string"/>
>     <element name="d"  minOccurs="1" maxOccurs="1" type="anyURI" />
>     <element name="e" minOccurs="1" maxOccurs="unbounded" type
="string" />
>     <element name="f" minOccurs="0" maxOccurs="1" type="string"/>
>     <element name="g"  minOccurs="0" maxOccurs="unbounded" 
> type="string"/> .....
> It says exactly the same thing.   Which one is more readable?  I.e.
> one of the two styles better facilitates comprehension?
> Why would you want to say it in the second form when you can say it in

> the first?
> Obviously my perspective is a bit different, that human readability is

> a critical element in the ultimate success of these schemas --  Let 
> the machines do the hard work.
> --Ray