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

Re: What should TrAX look like? (Was: Re: Articleon


Re:  What should TrAX look like? (Was: Re:  Articleon
Michael Kay wrote:


> You know the answer to your question. But it doesn't address my point. You
> claimed that defining the interface to accept Source was no better than
> defining it to accept Object. I pointed out that it was better, because
> defining it as Source would catch many type errors. 

I think the Python folks have pretty well convinced me that this doesn't 
help nearly as much as I used to think. I find it hard to imagine a case 
where I'd pass the wrong object to a transform method, and it would 
survive more than the first test run. These sorts of errors are caught 
so quickly they really don't need special compiler support to help them.

Marker interfaces have their places. Serializable doesn't bother me, for 
instance, because whether an object is serializable or not. An object 
that implements it is probably serializable. An object that doesn't 
isn't. Yes, I know there are exceptions to this; but that's basically 
how it works. Declare an object Serializable and ObjectOutputStream will 
try to serialize it. Declare that an object implements Source, and 
there's little a transformer can do.

-- 
Elliotte Rusty Harold  elharo@m...
XML in a Nutshell 3rd Edition Just Published!
http://www.cafeconleche.org/books/xian3/
http://www.amazon.com/exec/obidos/ISBN=0596007647/cafeaulaitA/ref=nosim

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.