[GemStone-Smalltalk] What should the species of a Reduced Conflict collection be?

Paul Baumann paul.baumann at theice.com
Wed Oct 23 12:46:48 PDT 2013


A GS post? The list still lives!

IMO, the result should not be an RcKeyValueDictionary. Look at #speciesForSelect for other examples (CanonStringDict, RcIdentityBag, RcQueue, Repository, UserProfile, and any subclasses).

A worthy fight, but vendors don't like to change existing code even if the argument is won. It is Smalltalk, just implement what you need. For example, the Efficient GemStone Enumeration framework now implements methods like #arraySelect: as a way to gather results into an efficient form. Arguing for each of hundreds of optimizations would have been a waste of time. I've been there too many times. The GemStone release model is outdated, but is convenient for legacy customers that value a painless upgrade and are not too sensitive about inefficiencies. Once you go the route of fixing problems yourself then it is actually a blessing that vendors don't change code.

GS still implements #selectValuesAsArray: but it is commented as being obsolete in GemStone 5.0. You might use #selectValuesAsArray: until it is removed. You could add RcKeyValueDictionary>>speciesForSelect to answer Dictionary. You could implement your own.

Paul Baumann


-----Original Message-----
From: gemstone-smalltalk-bounces at lists.gemtalksystems.com [mailto:gemstone-smalltalk-bounces at lists.gemtalksystems.com] On Behalf Of Richard Sargent
Sent: Wednesday, October 23, 2013 14:42
To: gemstone-smalltalk at lists.gemtalksystems.com
Subject: [GemStone-Smalltalk] What should the species of a Reduced Conflict collection be?

We had a customer inquiry about the species of a RcKeyValueDictionary. We all realize that the species of a collection should be as close as possible to the receiver's class. Obvious exceptions are Interval for which one cannot generally have a selection subset that is also an Interval and weak collections for which a selection subset should not be weak.

Should the reduced conflict aspect of a collection also be dropped when doing a select?
Conversely, in what scenario would one want to preserve the reduced conflict aspect when doing a select?




--
View this message in context: http://forum.world.st/What-should-the-species-of-a-Reduced-Conflict-collection-be-tp4716694.html
Sent from the Gemstone/S mailing list archive at Nabble.com.
_______________________________________________
GemStone-Smalltalk mailing list
GemStone-Smalltalk at lists.gemtalksystems.com
http://lists.gemtalksystems.com/mailman/listinfo/gemstone-smalltalk


This message may contain confidential information and is intended for specific recipients unless explicitly noted otherwise. If you have reason to believe you are not an intended recipient of this message, please delete it and notify the sender. This message may not represent the opinion of IntercontinentalExchange, Inc. (ICE), its subsidiaries or affiliates, and does not constitute a contract or guarantee. Unencrypted electronic mail is not secure and the recipient of this message is expected to provide safeguards from viruses and pursue alternate means of communication where privacy or a binding message is desired.



More information about the GemStone-Smalltalk mailing list