Class ObjectValueHolder<T>

java.lang.Object
de.intarsys.nativec.api.ObjectValueHolder<T>
All Implemented Interfaces:
IValueHolder<T>

public class ObjectValueHolder<T> extends Object implements IValueHolder<T>
A object holding nothing but a value This can easily be plugged in for a IValueHolder.
  • Constructor Details

    • ObjectValueHolder

      public ObjectValueHolder(T value)
  • Method Details

    • get

      public T get()
      Description copied from interface: IValueHolder
      Dereference the IValueHolder.
      Specified by:
      get in interface IValueHolder<T>
      Returns:
      The referenced object.
    • set

      public T set(T newValue)
      Description copied from interface: IValueHolder
      Assign a new value.
      Specified by:
      set in interface IValueHolder<T>
      Returns:
      The previous value (optional)