Custom stream extensions

Brian Goetz brian.goetz at
Sun Feb 3 16:34:34 PST 2013

>     Right.  During initial development, all these classes were public,
>     mostly for convenience of testing.

Just to give you an idea of how hard we make life for ourselves...

The "standard" testing trick for unit-testing package-private classes is 
to have a parallel source hierarchy for tests:


so the tests can be in the same package as the source.  But, that 
doesn't work for the JDK.  Unfortunately, you can't load java.* classes 
except from the bootclasspath.  Which means that big chunks of the 
tests, along with framework pieces like testng, end up on the 
bootclasspath in our test environment.  Which is a pain (and also means 
we're testing in a slightly different environment than our customers 
will run.)

So this is why the classes were all public until we bit the bullet and 
reorg'ed the tests into the appropriate bootclasspath/non-bootclasspath 

I've got it on my list to see if I can shave down that set of 
bootclasspath classes further.  Which will almost certainly require 
nasty tricks :(

More information about the lambda-dev mailing list