Interface
caplin.chart

MessageService

The class is still an Alpha release. It should only be used for experimental development as substantial changes may occur.
Interface that classes that wish to provide communication with a backend system for charting data must implement.

The service provided by a class that implements this interface is aliased by caplin.chart-message-service. The default implementation is caplin.chart.service.message.CaplinPlatform which knows how to obtain chart data from Caplin Platform.

MessageService is used by caplin.chart.Series.

Constructor Summary

Attributes Name and Description
caplin.chart.MessageService()

Method Summary

Attributes Name and Description
void subscribe(Object oSeriesRequest, Object oListener)

Subscribe to recieve chart series data.

void unsubscribe(Object oSeriesRequest, Object oListener)

Unsubscribe from receiving chart series data for the given request.

Constructor Detail

caplin.chart.MessageService()

Method Detail

void subscribe(Object oSeriesRequest, Object oListener)

Subscribe to recieve chart series data.

Parameters
Object oSeriesRequest A caplin.chart.series.Request object that holds all the information that the message service needs to retrieve the correct chart series data.
Object oListener Object that implements callbacks that the message service will call when it has chart series data.

void unsubscribe(Object oSeriesRequest, Object oListener)

Unsubscribe from receiving chart series data for the given request.

Parameters
Object oSeriesRequest The caplin.chart.series.Request object that was used to subscribe.
Object oListener The listener object that will be unsubscribed as a listener.