OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Hyphens vs underscores in element names

[ Lists Home | Date Index | Thread Index ]
  • From: Warren Hedley <w.hedley@auckland.ac.nz>
  • To: xml-dev@ic.ac.uk
  • Date: Wed, 26 Jan 2000 18:26:22 +1300

Hello XML-DEV

One of the more popular arguments between the development team for
FieldML regards a convention for the naming of elements and
attributes in our ML collection. The debate focuses over whether
we should use underscores (num_elements), hyphens (num-elements),
capitalisation (numElements) or runtogether (numelements). We've
eliminated capitalisation and runtogether because they don't
look as nice, and are now reduced to hyphens vs. underscores. The
older part of the development team is familiar with Fortran and C
and are keen to use underscores. However I've noticed in a brief
survey (results below) that most of the W3C-endorsed stuff seems
to feature minus signs.

Can anyone suggest any compelling reasons for going either way?
Does anyone want to add more data to my survey?

The Fortran coders also argued that there might be confusion with
arithmetic minus signs, if an application was to display something
like "mesh-1 - element-1", where "mesh-1" and "element-1" are
identifying attributes of type NMTOKEN (would have used ID but we
don't require uniqueness within a file). However since I cannot
prevent someone from using hyphens in an attribute value (without
resorting to schema validation), I don't think this holds. The
argument continued that users would be encouraged to use underscores
in identifiers if the element names also used underscores.

Begin Survey Results
====================

Hyphens (last 2 not XML applications, but W3C) :

XSLT = <for-each>, <call-template>, etc.
XPath & XPointer = ancestor-or-self, etc
SMIL = <root-layout> @skip-content
W3C spec names = REC-DOM-Level-1-19981001
XHTML module names = xhtml11-tableb-1.mod

Underscores :

BioML = <dna_type> <keep_space> (not W3C)

Runtogether (I suspect this was chosen for legacy reasons ??) :

MathML = <maligngroup>
XHTML = <textarea> @colspan

Capitalisation (not all W3C WDs or Notes) :

XML-Schema = <unparsedEntity> @schemaName
SVG (Scalable Vector Graphics) = <animateMotion>
CDF (Channel Description Format) = <PublicationDate>
TEI (Text Encoding Initiative) = <docImprint>
OCS (Open Content Syndication) = <updatePeriod>

End Survey Results
==================

In case anyone is interested, FieldML is a language for marking up
spatially and time varying fields, targeted at finite element
packages (in particular some software developed at Auckland called
CMISS). The development of FieldML can be followed here

http://www.esc.auckland.ac.nz/sites/physiome/fieldml/pages/

-- 
Warren Hedley
Department of Engineering Science
Auckland University
New Zealand

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ or CD-ROM/ISBN 981-02-3594-1
Unsubscribe by posting to majordom@ic.ac.uk the message
unsubscribe xml-dev  (or)
unsubscribe xml-dev your-subscribed-email@your-subscribed-address

Please note: New list subscriptions now closed in preparation for transfer to OASIS.






 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS