Steve Maine
responds to my rant against attributes with some interesting and quite revealing comments about the centrality of attributes to the Indigo programming model. I'll leave aside the assumption that I want a new language, as I've already dealt with that. I want focus on Steve's comment about attributes:
I can see where John’s coming from; other frameworks have used CLR attributes to convey “extra stuff” that’s not really central to the core programming model. In Indigo, though, attributes are central to the programming model and are by no means “second-class” or unimportant. Indigo uses CLR types to denote two equivalent representations of the same underlying concept that exist simultaneously. Each representation is equally important, and external contracts aren’t relegated to subservient status just because they’re defined in attributes.
Hogwash! The "other frameworks" are actually doing the right thing and it's Indigo that's in the wrong here. The word "attribute" has a specific meaning in the English language and that meaning is reflected in the nature of attributes in the CLR. An attribute is a quality or characteristic inherent in someone or something. Grammatically, an attribute is a word or phrase syntactically subordinate to another word or phrase that it modifies. It is quite obvious that CLR designers chose the name "attribute" for the programming construct because it fits perfectly. A CLR attribute is both syntactically subordinate to the construct it modifies and expresses a quality or characteristic of that construct. Consciously or not, by using attributes for the CLR version of the contract, the Indigo team is making a value judgment about how we should design our applications. That is clearly reflected in Steve's example:
These two supposedly equal representations aren't equal at all. It's fairly obvious how to go from the CLR representation to the XML Schema, but how would one reverse the process? You can't. The Indigo team has been quite clear that if you want to design the message first, they "will get out of your way" which is just another way of saying they won't help at all. I will say it again. What I'm asking for is not difficult or bizarre, but it is something that is best done by Microsoft. It won't be done, because Microsoft (especially the Indigo team) doesn't believe that it has value. They are too wrapped up in OO orthodoxy to see what's plainly there. Writing true service oriented applications requires service oriented analysis and design, not half-baked, after the fact, sprinkling magic SO pixie dust on your same-old object model.
Posted
May 10 2005, 11:35 PM
by
john-cavnar-johnson