|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.cosylab.gui.displayers.MinimalDataConsumer
public class MinimalDataConsumer
MinimalDataConsumer
is minimal implementation of
DataConsumer
as convenience for cunsumer implementators.
Field Summary | |
---|---|
protected DataState |
dataState
|
static java.lang.Class[] |
EMPTY_CLASS_ARRAY
Zero length array. |
static java.lang.String[] |
EMPTY_STRING_ARRAY
Zero length array. |
protected java.lang.String |
name
|
Constructor Summary | |
---|---|
MinimalDataConsumer()
Creates new instance. |
Method Summary | ||
---|---|---|
|
getDataConsumer(java.lang.Class<D> type)
Returns data consumer for requested data consumer type. |
|
DataConsumer |
getDefaultDataConsumer()
Returns the implementation of default consumer type supported by this data consumer. |
|
java.lang.String |
getName()
Returns name of this data consumer. |
|
java.lang.String[] |
getSupportedCharacteristics()
Resturns array with names of supported characteristics. |
|
java.lang.Class[] |
getSupportedConsumerTypes()
Returns array of supported data consumer types, which can be used as parameter and returnned with getDataCosnumer(Class)
method. |
|
void |
setCharacteristics(java.util.Map characteristics)
Sets new dynamic value characteristics to this data consumer. |
|
void |
updateDataState(DataState state)
Push data state (quality) update change for dynamic value. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String[] EMPTY_STRING_ARRAY
public static final java.lang.Class[] EMPTY_CLASS_ARRAY
protected DataState dataState
protected java.lang.String name
Constructor Detail |
---|
public MinimalDataConsumer()
Method Detail |
---|
public DataConsumer getDefaultDataConsumer()
DataConsumer
getDefaultDataConsumer
in interface DataConsumer
public void updateDataState(DataState state)
DataConsumer
updateDataState
in interface DataConsumer
state
- new data state(quality) descriptorpublic void setCharacteristics(java.util.Map characteristics)
DataConsumer
setCharacteristics
in interface DataConsumer
characteristics
- the Map
with attripublic java.lang.String getName()
DataConsumer
getName
in interface DataConsumer
public java.lang.String[] getSupportedCharacteristics()
DataConsumer
null
is returned, than
consumer expect all existing characteristics from data source.
getSupportedCharacteristics
in interface DataConsumer
public java.lang.Class[] getSupportedConsumerTypes()
DataConsumer
getDataCosnumer(Class)
method.
getSupportedConsumerTypes
in interface DataConsumer
public <D extends DataConsumer> D getDataConsumer(java.lang.Class<D> type)
DataConsumer
Returns data consumer for requested data consumer type. If this data
consumer does not support required data consumer, null
is
returned.
If this data cosnumer does not support specific data consumer type, then it means, that it is not desirable to cast data of that type to any by this consumer supported data consumer types.
getDataConsumer
in interface DataConsumer
type
- Class of specific data consumer (e.g. DoubleConsumer)
null
if
not supported
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |