Skip to content

Instantly share code, notes, and snippets.

@klaplume
klaplume / GuavaTest
Last active January 2, 2016 02:39
Snippet that show the speed increase with (Guava) memoized Supplier
@Test
public void testGuavaSuppliers() throws InterruptedException
{
Supplier<Dummy> s = Suppliers.memoize(new Supplier<Dummy>()
{
@Override
public Dummy get()
{
return Dummy.foo;
}