[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Engineering versus Science, Anecdote versus Evidence... [W

  • From: Greg Hunt <greg@firmansyah.com>
  • To: Andrew Welch <andrew.j.welch@gmail.com>
  • Date: Wed, 4 Jan 2012 22:16:25 +1100

Re:  Engineering versus Science
What is astonishing is how bad XML document designs frequently are.  Its as though people make up a schema and never look at the documents that they define or at the documents that are generated based on those schemas.  The android schema below is a good example.  Another example is one that I was given by some developers a few months ago.  They were frankly puzzled by what they were being sent by a partner organisation and by how long it was taking to process.  It had thousands of distinct namespace prefixes and hundreds of distinct namespaces.  There was a separate namespace for every element and it was not a small document.  

The qualities of documents: their ease of understanding, the ease of writing the things, maximised simplicity, maximised performance, just general aesthetics, all seem to get lost at times when things are expected to just technically work.  Addressing this type of design madness through rules (an engineering approach) would require definition of all possible pathologies so that rules could be defined.  The role of aesthetics in engineering seems to be less well understood than the role of aesthetics in the traditional sciences, but plugging into the aesthetics of what we do seems to be the simplest answer sometimes. 

On Wed, Jan 4, 2012 at 9:10 PM, Andrew Welch <andrew.j.welch@gmail.com> wrote:
... snip...
 
To bring it kind of back on topic, in Android (which uses Java so
would be the better choice for your friend) you can use XML for
specifying the layout, however whoever designed it made a bad mistake
- the elements are in no namespace, but the attributes are in the
android namespace... so you end up with the 'android' prefix
everywhere:

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
             android:layout_width="fill_parent"
             android:layout_height="fill_parent"
             android:orientation="vertical" >
   <TextView android:id="@+id/text"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
             android:text="Hello, I am a TextView" />
   <Button android:id="@+id/button"
           android:layout_width="wrap_content"
           android:layout_height="wrap_content"
           android:text="Hello, I am a Button" />
</LinearLayout>

...so as you can imagine, the xml layout isn't very popular.



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.