Class NullableObject<T>

java.lang.Object
com.espertech.esper.common.internal.util.NullableObject<T>
All Implemented Interfaces:
Serializable

public class NullableObject<T> extends Object implements Serializable
A generic class to hold an object that may itself be a null value versus an undefined (not existing) value.

The presence of a reference indicates that a value exists, the absence of a reference to this object indicates that there is no value (similar to a Pair<Object, Boolean>).

See Also:
  • Constructor Details

    • NullableObject

      public NullableObject(T object)
      Ctor.
      Parameters:
      object - the object to contain
  • Method Details

    • getObject

      public T getObject()
      Returns the contained value.
      Returns:
      contained value
    • setObject

      public void setObject(T object)
      Sets a new contained value.
      Parameters:
      object - value to set