shrinkwrap / descriptors

ShrinkWrap subproject for creating Archive Descriptors
Apache License 2.0
26 stars 30 forks source link

Prototype #90

Open rbattenfeld opened 11 years ago

rbattenfeld commented 11 years ago

Factory based API proposal

ALRubinger commented 11 years ago

Overall I think the method naming and capitalization conventions here need to be reviewed. And I'm not sure the prototype offers a complete view of all the types we'll encounter. Also I'd like to see some JavaDocs/explanation of some of the method names where noted.

The factory approach taken here, however (and I'm changing my mind on this position), is clearly preferable to the hierarchical object model approach we'd taken with "up()", so that's good. Last I spoke to @aslakknutsen on it, that was his opinion as well.

rbattenfeld commented 11 years ago

Thanks for your comments. I also see this the preferable way. Do you want that I cleanup the prototype?

You are absolutely right, there are naming and capitalization convention not applied I was just hacking in something that shows the concept and is executable.

Shall I wait until you, Aslak and others are able to make their or more comments suggestions?

For me, one important thing is the Factory class. I prefer a class like this. It makes it very simple to create a new objects, especially within IDEs. If you all agree in such a class, then I see it as a static class but how such a static class can be made visible to the users? This class must be generated. Perhaps there is a second factory class that defines all the convenient classes.