@@ -0,0 +1,1210 @@
+package com.wizzardo.tools.misc;%0A%0A/**%0A * Created by wizzardo on 06/07/16.%0A */%0Apublic class Lazy%3CT%3E %7B%0A    private volatile Holder%3CT%3E holder;%0A%0A    public Lazy(final Supplier%3CT%3E supplier) %7B%0A        holder = new HolderWithSupplier%3CT%3E(new Supplier%3CT%3E() %7B%0A            @Override%0A            public T supply() %7B%0A                synchronized (Lazy.this) %7B%0A                    if (holder.getClass() != Holder.class)%0A                        holder = new Holder%3CT%3E(supplier.supply());%0A                %7D%0A                return holder.value;%0A            %7D%0A        %7D);%0A    %7D%0A%0A    public static %3CT%3E Lazy%3CT%3E of(Supplier%3CT%3E supplier) %7B%0A        return new Lazy%3CT%3E(supplier);%0A    %7D%0A%0A    public T get() %7B%0A        return holder.get();%0A    %7D%0A%0A    static class Holder%3CT%3E %7B%0A        final T value;%0A%0A        Holder(T value) %7B%0A            this.value = value;%0A        %7D%0A%0A        T get() %7B%0A            return value;%0A        %7D%0A    %7D%0A%0A    static class HolderWithSupplier%3CT%3E extends Holder%3CT%3E %7B%0A        Supplier%3CT%3E supplier;%0A%0A        HolderWithSupplier(Supplier%3CT%3E supplier) %7B%0A            super(null);%0A            this.supplier = supplier;%0A        %7D%0A%0A        @Override%0A        T get() %7B%0A            return supplier.supply();%0A        %7D%0A    %7D%0A%7D%0A

add Lazy class