> The spec is the contract. If an impl returns something other then a
> string then the impl is broken.
>
> > Would you work with a resource object on the Resource level
> getting content
> > out of it without knowing what actual resource it is? e.g. do
> you do things
> > like:
> >
> > if (resource instanceof XMLResource)
> >         String bla = (String)getObject();
> >
> > If not then I think get and setContent should be moved down a level from
> > Resource to XMLResource and Binary Resource and have the return and
> > parameter types changed.
>
> That is exactly how I see it being used.

OK, I understand how you are reasoning now. Thanks for your help and sorry
for being such a pain. I do not think there would be need to add
getResourceAsText() to XMLResource then.

Best regards,
Per


----------------------------------------------------------------------
Post a message:         mailto:[EMAIL PROTECTED]
Unsubscribe:            mailto:[EMAIL PROTECTED]
Contact adminstrator:   mailto:[EMAIL PROTECTED]
Read archived messages: http://archive.xmldb.org/
----------------------------------------------------------------------

Reply via email to