[Registry-dev] Minor change to the Registry design
Sanjiva Weerawarana
sanjiva at wso2.com
Tue Aug 28 18:13:05 PDT 2007
Glen Daniels wrote:
>
> Honestly, I don't like this for the Java API - it just doesn't feel like
> good object design. Why don't you want the Directory (or Collection,
> which I agree w/Sanjiva is nicer) class? Isn't your suggestion like
> saying "let's have one Fruit class and then we can put isApple(),
> isOrange(), etc. methods on it"?
>
> A Directory/Collection ISA special kind of a Resource which has
> children. In fact in our model ONLY Collections have children. Sounds
> like a perfect case for a subclass to me. If we leave the separate
> class, all child-related APIs are contained in the Directory/Collection
> objects. If we change it as you propose, these notions bleed
> (inappropriately, to my eye) into the APIs for *all* Resources and for
> the whole Registry.
>
> I would prefer we did not make this change.
Hmmm .. +1 for not changing it now ;-). Glen convinced me that its not a
bad thing to have. Directory/Collection does extend Resource right? So we
get all the standard stuff out of it and an additional method to get its
list of child paths.
Sanjiva.
--
Sanjiva Weerawarana, Ph.D.
Founder, Chairman & CEO; WSO2, Inc.; http://www.wso2.com/
email: sanjiva at wso2.com; cell: +94 77 787 6880; fax: +1 509 691 2000
"Oxygenating the Web Service Platform."
More information about the Registry-dev
mailing list