Class JohnzonBuilder.Lazy<T>

  • All Implemented Interfaces:
    java.util.function.Supplier<T>
    Enclosing class:
    JohnzonBuilder

    private abstract static class JohnzonBuilder.Lazy<T>
    extends java.lang.Object
    implements java.util.function.Supplier<T>
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.util.concurrent.atomic.AtomicReference<T> ref  
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private Lazy()  
    • Field Detail

      • ref

        private final java.util.concurrent.atomic.AtomicReference<T> ref
    • Constructor Detail

      • Lazy

        private Lazy()
    • Method Detail

      • get

        public T get()
        Specified by:
        get in interface java.util.function.Supplier<T>
      • doCreate

        protected abstract T doCreate()