DESY ACOP Beans Home

Package com.cosylab.gui.displayers

A package containing framework for building displayer components.

See:
          Description

Interface Summary
AsynchronousNumberConsumer NumericAsynchronousConsumer is consumer, which receives update request and returns some time later respons with detail information about request.
AsynchronousObjectConsumer NumericAsynchronousConsumer is consumer, which receives update request and returns some time later respons with detail information about request.
AsynchronousStringConsumer NumericAsynchronousConsumer is consumer, which receives update request and returns some time later respons with detail information about request.
CommonDisplayer CommonDisplayer defines interface common to multiple and single displayers.
ConditionDescriptor This interface returns specific Color for Condition and otherwise
ConvertibleDisplayer ConvertibleDisplayer enables usage of Converters.
DataConsumer DataConsumer interface defines receiver for udates of dynamic value change dynamic value quality (or state) change dynamic value characteristics
DataSource DataSource is interface for generic data source.
DataStateProvider DataStateProvider interface marks those components, which can provide DataState Java property to describe theier data quality state.
Displayer Displayer interface describes GUI component, which is able to dispaly on screen single dynamic data source.
DoubleConsumer DoubleConsumer is data consumer for receiveing updates of double dynamic values.
DoubleDisplayer A specialization of the Displayer interface for Java primitive type double.
DoubleSeqConsumer DoubleSeqConsumer is data consumer for receiveing updates of double[] dynamic values.
DoubleSeqDisplayer A specialization of the Displayer interface for Java primitive type double[].
EnumDisplayer A specialization of Displayer interface for enumerations.
IconDisplayer IconDisplayer can display long values (similar to LongDisplayer) but instead of showing the number value it shows different icons for each of the received values.
LongConsumer LongConsumer is data consumer for receiveing updates of long dynamic values.
LongDisplayer A specialization of Displayer interface for Java primitive type long.
LongSeqConsumer LongSeqConsumer is data consumer for receiveing updates of long[] dynamic values.
MultipleDataConsumer MultipleDataConsumer is data consumer, which is able to process at the same time several dynamic data sources by allocation own simple data consumer for each source.
MultipleDisplayer MultipleDisplayer interface describes GUI component, which is able to dispaly on screen single dynamic data source.
NonblockingNumberConsumer NonblockingNumberConsumer is data consumer for Number data, which does not block or fail update request.
NonblockingObjectConsumer NonblockingObjectConsumer is data consumer for Object data, which does not block or fail update request.
NonblockingStringConsumer NonblockingStringConsumer is data consumer for String data, which does not block or fail update request.
NumberConsumer NumberConsumer is data consumer for receiveing updates of Number dynamic values, which will block call until update is completer and throws exception on fail.
ObjectConsumer ObjectConsumer is data consumer for receiveing updates of Object dynamic values.
ObjectDisplayer A specialization of the Displayer interface for Object Java type.
ObjectSeqConsumer ObjectSeqConsumer is data consumer for receiveing updates of Object[] dynamic values.
PatternConsumer PatternConsumer is data consumer for receiveing updates of BitSet dynamic values.
PatternDisplayer A specialization of Displayer interface for patterns.
StringConsumer StringConsumer is data consumer for receiveing updates of String dynamic values.
StringDisplayer A specialization of the Displayer interface for String Java type.
StringSeqConsumer StringSeqConsumer is data consumer for receiveing updates of String[] dynamic values.
SynchronousNumberConsumer NumberConsumer is data consumer for receiveing updates of Number dynamic values, which will block call until update is completer and throws exception on fail.
SynchronousObjectConsumer ObjectConsumer is data consumer for receiveing updates of Object dynamic values.
SynchronousStringConsumer StringConsumer is data consumer for receiveing updates of String dynamic values.
UpdateRequestListener UpdateRequestListener receives response for asynchronous update request.
 

Class Summary
AbstractDisplayerPanel AbstractDisplayerPanel is a displayer that provides common feature of a Displayer interface.
DataSourceSupport DataSourceSupport is conveniencee implementation base for DataSource interface.
DataState DataState describes quality of dinamic value.
DefaultConditionDescriptor DefaultConditionDescriptor take cares of Condition Colors , it defines default colors for Conditions , sets Conditions other Colors.
DisplayerParameters DisplayerParameters holds various properties of some displayed value.
DisplayerUtilities DisplayerUtilities contains set of usefull methods and fields which help to implement various Displayer interfaces.
DoubleConsumerMulticaster DoubleConsumerMulticaster casts different data consumers to DoubleConsumer.
DoubleSeqConsumerMulticaster DoubleSeqConsumerMulticaster casts different data consumers to DoubleSeqConsumer.
LongConsumerMulticaster LongConsumerMulticaster casts different data consumers to LongConsumer.
MinimalDataConsumer MinimalDataConsumer is minimal implementation of DataConsumer as convenience for cunsumer implementators.
ObjectConsumerMulticaster ObjectConsumerMulticaster delegates all defined data sources to ObjectConsumer delegate.
PatternConsumerMulticaster PatternConsumerMulticaster casts different data consumers to PatternConsumer.
StringConsumerMulticaster StringConsumerMulticaster casts different data consumers to StringConsumer.
UpdateRequest This update request is sent to NumericAsynchonousConsumer to inform it that the source value has changed.
 

Package com.cosylab.gui.displayers Description

A package containing framework for building displayer components.

Package Specification

.

The displayer package contains the interfaces that need to be implemented to provide displayer capability to the GUI components. A displayer is a graphical component able to render a changing value in its context (units, limits, display format etc). Such "changing value" is called dynamic value. A displayer may also be a setter, thus providing not only the display (read-only access) but also data changing (read-write access). An example of a displayer is a gauge component, specialized for the display of double values. Such gauge might have a minimum, maximum, units, title as a context and the value itself as a dynamic value.

Displayers communicate with their data sources with the help of adapters. Adapters are contained in a specialized package.

Displayers are JavaBeans components. They have a number of properties and communicate with other components by firing events. Displayers specified by this package are single displayers, meaning that each displays a single dynamic value of a given data type (double, int, may also be class type).

The main interface of this package is Displayer interface. This interface is not concerned with the GUI capabilities of the displayers - this is the task for the Displayer implementations. However, Displayer IF defines exactly displayer lifecycle, data states, data changes and several common displayer properties. Each displayer can be in one state at one time and must be in some state at any given instant. The states correspond roughly to two groups: a "clean" state, in which the displayer finds itself after successful construction; and "connected" state, when it communicates with modeling layer through an adapter.

As a cannonical implementation, DisplayerSupport class is provided. This class is intended to be used as a delegate (similar to PropertyChangeSupport) to be instantiated by GUI components. PanelDisplayerSupport exemplifies this paradigm by extending JPanel and delegating to DisplayerSupport. The DisplayerSupport implementation is serializable, thread safe and follows the Displayer designs by optimizing on speed and memory consumption by employing lazy creation (listener containers, events) and fast event dispatching (ListenerLists) for value change events.

Setter interface provides a separate capability for mutating the dynamic value. Setter IF may (but need not) be implemented by the same class as Displayer IF. However, the setter is always completely controlled by the displayer and its adapter and has no lifecycle control of its own. Setter also communicates with events, by which it informs the listeners about the requested value changes for the dynamic value. Such requested new value is called a "target value". A target value only becomes equal to the dynamic value when the change is confirmed by the modeling layer. The synchronization between adapter, setter and displayer is exacly prescribed by the interfaces in this package.

Setters can be thread safe (which implies a performance penalty and is rarely necessary) but need not be. SetterSupport provides a cannonical setter implementation optimized for speed. The optimization is based on the assumption, that most of the time only the adapter will listen to the set request events.

Related Documentation

JavaDoc

@see com.cosylab.gui.displayers.Displayer

See Also:
com.cosylab.gui.displayers.DisplayerSupport, com.cosylab.gui.displayers.Setter, com.cosylab.gui.displayers.SetterSupport, com.cosylab.gui.adapters.Adapter


Copyright © 2010. All Rights Reserved.