Closed GoogleCodeExporter closed 9 years ago
But can't you model it as a Map<ConstructionParameters, Instance>?
Original comment by jim.andreou
on 7 Nov 2010 at 5:43
I could, if Guava had tuples. :)
Original comment by harmathdenes
on 7 Nov 2010 at 6:13
Don't be shy, roll your own, everybody does :)
Original comment by jim.andreou
on 7 Nov 2010 at 9:32
If you want a concurrent set, just make a concurrent map using MapMaker and
then call Sets.newSetFromMap(concurrentMap);
Original comment by kurt.kluever
on 8 Nov 2010 at 6:33
That said, SetMaker is coming soon enough anyway. A ListMaker with equivalent
functionality to these is nowhere on the horizon, though; the List type doesn't
mesh well with references, concurrency, etc.
Original comment by kevinb@google.com
on 9 Nov 2010 at 7:38
"One frequent use case is computing sets when writing factories that have to
return the same instance for identical construction parameters." -- if you
don't want to think of this as a Map<ConstructionParameters, Instance>, then I
think what you want is our Interner; have you tried it?
I'm realizing that the SetMaker we're working on may not have any connection to
this particular request.
Original comment by kevinb@google.com
on 12 Jan 2011 at 11:09
This bug needs clarification in order to stay open.
We are working on a SetMaker, but that's little more than a MapMaker that wraps
in newSetFromMap() when it's done; it doesn't sound like what you're looking
for (which may be an interner).
Original comment by kevinb@google.com
on 26 Jan 2011 at 2:53
Original comment by kevinb@google.com
on 27 Jan 2011 at 6:00
This issue has been migrated to GitHub.
It can be found at https://github.com/google/guava/issues/<id>
Original comment by cgdecker@google.com
on 1 Nov 2014 at 4:15
Original comment by cgdecker@google.com
on 3 Nov 2014 at 9:09
Original issue reported on code.google.com by
harmathdenes
on 7 Nov 2010 at 1:37