Class ValueHolder<V>

  • Type Parameters:
    V - the value type

    public class ValueHolder<V>
    extends java.lang.Object
    The class to hold a value (No Thread-Safe)
    Since:
    1.0.0
    Author:
    Mercy
    • Constructor Detail

      • ValueHolder

        public ValueHolder()
      • ValueHolder

        public ValueHolder​(V value)
    • Method Detail

      • getValue

        public V getValue()
      • setValue

        public void setValue​(V value)
      • reset

        public void reset()
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • of

        public static <V> ValueHolder<V> of​(V value)