caching via XMLObject ?

Brent Putman putmanb at georgetown.edu
Tue Aug 20 18:10:34 EDT 2013


On 8/20/13 5:56 PM, Cantor, Scott wrote:
> I had asked about whether we wanted to expose Guava interfaces in our
> APIs, and we were coming down on the side of not doing that, but of course
> this would be a case of having to invent one, so maybe that changes the
> answer.

True, I had forgotten about that decision (which post-dates Chad's old
Jira suggestion to consider implementing the Guava interface).  I don't
see a strong reason to change that answer. I wouldn't see a problem with
having XMLObject return our own concrete class in the API, there's not
much to be gained by an interface if we don't have plans to support
multiple impls.

Another thing I just noticed is that their Multimap interface, as all
Java "map"-type interfaces, has a put(key, value) API.  Ours doesn't,
you never specify the key(s) on insertion, because it's implicit.  So
off-hand I'm not actually sure how well their interface is going to work.

Actually, I think our current ClassToInstanceMultiMap isn't really a
true Java "map".  I think it's more correctly described as a
"multiply-class-indexed multiset/bag ".  As where our old
ClassIndexedSet, which is very similar, has a more accurate name and is
a "singly-class-indexed set".



More information about the dev mailing list