On Fri, 02 Nov 2012 21:12:07 +0100, clay <claytonw...@gmail.com> wrote:

In hindsight, a simpler solution (with static import of custom toIterable
method) would be:

final List<String> zips2 = new ArrayList<String>();
for (Person p : people) { for (Address a : toIterable(p.addressOption)) {
for (String z : toIterable(a.zipOption)) { zips2.add(z); } } }

Honestly, I don't find it particularly readable.


--
Fabrizio Giudici - Java Architect @ Tidalwave s.a.s.
"We make Java work. Everywhere."
http://tidalwave.it/fabrizio/blog - fabrizio.giud...@tidalwave.it

--
You received this message because you are subscribed to the Google Groups "Java 
Posse" group.
To post to this group, send email to javaposse@googlegroups.com.
To unsubscribe from this group, send email to 
javaposse+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/javaposse?hl=en.

Reply via email to