T
- The type of the value held by the implementor.public interface ValueHolder<T>
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.
AbstractValueHoldingSwingGadget
Modifier and Type | Field and Description |
---|---|
static AspectType<ValueHolder<?>> |
TYPE
The aspect's generic type to access the value holding container in an unchecked way.
|
Modifier and Type | Method and Description |
---|---|
T |
getValue()
Get the current value stored by this value holder.
|
boolean |
isEmpty()
Indicates that the currently hold value is considered to represent an empty value.
|
void |
setValue(T value)
Set the given value to be stored by this value holder.
|
static final AspectType<ValueHolder<?>> TYPE
@Nullable T getValue()
@RunsInEDT void setValue(@Nullable T value)
The outer framework guarantees, that this method will always be invoked from within
the event dispatcher thread
!
value
- A value to store.boolean isEmpty()
true
, if value is considered empty.Copyright © 2014 e-Spirit AG. All Rights Reserved. Build 5.0_BETA.500