Oct. 17th, 2006 [entries|reading|network|archive]
simont

[ userinfo | dreamwidth userinfo ]
[ archive | journal archive ]

Tue 2006-10-17 11:36
XML OF DEATH

If you're designing an XML representation of some type of data, and you want a key-value sort of organisation, this is inherently reasonably well supported by XML. If you want to set the key ‘foo’ to the value ‘bar’, you can simply set up your DTD so that it lets you write

<sometagorother foo=bar />

Now occasionally I can understand that you might want to layer your own key-value structure on top of this:

<set key="foo" value="bar" />

because this approach gives you the ability to add extra attributes alongside each key/value pair, which might be useful for all sorts of vaguely sensible reasons: expiry dates, permissions, conditionalisation, you name it. Also it doesn't require you to specify the full set of possible keys in the DTD, which is obviously useful.

However, when I see a third layer of key-value structure on top of even that …

<method name="SetVariable">
<arg key="name" value="foo" />
<arg key="value" value="bar" />
</method>

… I really do start to wonder whether someone's brain has been EATEN BY PARASITIC XML MEMES OF DEATH.

Link14 comments | Reply
Tue 2006-10-17 20:27
Linguistic synaesthesia

Today I wrote a random comment on somebody's LJ, and five minutes after I posted it I suddenly realised I'd inadvertently used the phrase ‘sounds good on paper’. Not sure how something does that. Does it rustle pleasantly, perhaps?

I suspect that mental crossover was simply due to my brain being momentarily indecisive between ‘sounds good’ and ‘looks good on paper’, and the fact that what I was thinking was an entirely abstract thought about the superficial plausibility of the comment I was responding to, to which either of the phrases I was considering would have been at best an approximation.

A more interesting case of linguistic synaesthesia showed up in a mathematical proof I jotted down in 2001 and recently found lying around on my computer, which described a nasty algebraic mess as ‘the following smelly-looking polynomial’. I suppose that in the age of the television, ‘smelly-looking’ would be a perfectly reasonable concept to apply to something seen on a screen, but I'm inclined to feel that when I used the phrase it was probably an unconscious reflection of my sensory deficiency: for practical purposes, when I hear the word ‘smelly’ I can generally take it to mean that the object thus described is something unpleasant which you don't want to go too near if you can help it. Thus, it didn't seem the least bit incongruous to describe a polynomial as looking as if it had that property; after all, how else could I judge something to be smelly?

Link11 comments | Reply
navigation
[ viewing | October 17th, 2006 ]
[ go | Previous Day|Next Day ]