W3C home > Mailing lists > Public > www-xml-schema-comments@w3.org > April to June 1999

Element/Attribute Usage Suggestions

From: Richard Rathmann <rrathmann@csc.noaa.gov>
Date: Fri, 28 May 1999 13:49:08 -0400
Message-Id: <4.1.19990528132016.00a1b6f0@mailsrv.csc.noaa.gov>
To: www-xml-schema-comments@w3.org
Should there be a "usage" or similar attribute on <elementType> and
<attrDecl> elements (or even inheritable from other schema elements) which
suggests a guideline for when to use an element or attribute?

Elements currently don't have this, beyond setting the number of times it
may occur within a given content model.  Attributes are limited to being
required (#REQUIRED), fixed (#FIXED), or defaulted/optional (I group these
two together as #IMPLIED is essentially equivalent to defaulting to a
"null" value).  In addition to adding these three options to a "usage"
attribute for elements, additional values may be provided for
"mandatory/required when applicable," "recommended," and "recommended when
applicable."  In the Text Encoding Initiative's Guidelines for Electronic
Text Encoding and Interchange element/attribute reference list
(<http://etext.lib.virginia.edu/bin/tei-tocs?div=DIV1&id=REFTAG>) they use
three letter codes (REQ, MWA, REC, RWA, and OPT) for usage field values
when describing attributes for each element.  I feel that these (with the
possible addition of FIX) would make suitable enumerated values for a
"usage" attribute.

  Richard E. Rathmann           
  REMSA Contractor              
  NOAA Coastal Services Center  
  2234 S Hobson Ave             
  Charleston, SC  29405-2413    
  (843) 740-1314                
  (843) 740-1224  (fax)         
Received on Friday, 28 May 1999 13:49:15 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 23:08:45 UTC