Interface ValueHolder<T>
- Type Parameters:
T
- The type of the value held by the implementor.
- All Known Implementing Classes:
AbstractValueHoldingSwingGadget
public interface ValueHolder<T>
Aspect definition for a persistency object holder of a specified type of value.
The parameterization of T must correspond to the concrete value type of a Gadget component.
The outer framework guarantees that none of this interface's methods gets invoked before the gadget's component was requested.
The AbstractValueHoldingSwingGadget
provides an abstract implementation with supporting functionality
and a small sub-type API. It is recommended, but not obligatory to sub-class the abstract implementation.
- Since:
- 4.2.405
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final AspectType<ValueHolder<?>>
The aspect's generic type to access the value holding container in an unchecked way. -
Method Summary
-
Field Details
-
TYPE
The aspect's generic type to access the value holding container in an unchecked way.- Since:
- 4.2.405
-
-
Method Details
-
getValue
Get the current value stored by this value holder.- Returns:
- The currently stored value.
- Since:
- 4.2.405
-
setValue
Set the given value to be stored by this value holder.The outer framework guarantees, that this method will always be invoked from within the
event dispatcher thread
!- Parameters:
value
- A value to store.- Since:
- 4.2.405
-
isEmpty
boolean isEmpty()Indicates that the currently hold value is considered to represent an empty value.- Returns:
true
, if value is considered empty.- Since:
- 4.2.405
-