I was reading this excellent post on google collections by Sune Simonsen and decided to re-factor some code of mine. I have an immutable results object used in a multi-threaded application. I wanted to feel the difference using the google ImmutableList. My existing class provides immutability in a very similar way to the google classes. Static methods are used to instantiate the object. An array is used to back a list collection. Defensive copies are made to protect the immutability of the object. Moving to google collections is easy and makes my implementation simple whilst reducing test overhead.












