public abstract class


extends DataAdapter<Tx, Ty>
implements DataAdapter.OnDataChangedListener
   ↳ com.shinobicontrols.charts.DataAdapter<Tx, Ty>
     ↳ com.shinobicontrols.advancedcharting.core.DataAdapterWrapper<Tx, Ty>
Known Direct Subclasses
Known Indirect Subclasses

Class Overview

Base class for implementations that wrap a given DataAdapter, passing through all method calls to it with the exception of notifyDataChanged(), addOnDataChangedListener(OnDataChangedListener) and removeOnDataChangedListener(OnDataChangedListener).

For data changed notifications, this DataAdapterWrapper registers itself as an com.shinobicontrols.charts.DataAdapter.OnDataChangedListener of the wrapped DataAdapter. By maintaining its own list of com.shinobicontrols.charts.DataAdapter.OnDataChangedListeners it is able to notify these when it receives a notification from the wrapped DataAdapter.

Consequently this retains the notification policy of the wrapped DataAdapter regardless of whether data points are added/removed/etc. to and from this DataAdapterWrapper or the wrapped DataAdapter directly.


protected final DataAdapter<Tx, Ty> dataAdapter
Public Constructors
DataAdapterWrapper(DataAdapter<Tx, Ty> dataAdapter)
Public Methods
boolean add(Data<Tx, Ty> dataPoint)
void add(int location, Data<Tx, Ty> dataPoint)
boolean addAll(int location, Collection<? extends Data<Tx, Ty>> dataPoints)
boolean addAll(Collection<? extends Data<Tx, Ty>> dataPoints)
void clear()
boolean contains(Object object)
boolean containsAll(Collection<?> collection)
Data<Tx, Ty> get(int location)
abstract List<Data<Tx, Ty>> getDataPointsForDisplay()
Implementations of this method should return a list of data points which are to be displayed on the chart.
int indexOf(Object object)
boolean isEmpty()
Iterator<Data<Tx, Ty>> iterator()
int lastIndexOf(Object object)
void onDataChanged()
Data<Tx, Ty> remove(int location)
boolean remove(Object object)
boolean removeAll(Collection<?> collection)
boolean retainAll(Collection<?> collection)
Data<Tx, Ty> set(int location, Data<Tx, Ty> dataPoint)
int size()
<T> T[] toArray(T[] array)
Object[] toArray()
Inherited Methods
From class com.shinobicontrols.charts.DataAdapter
From class java.lang.Object
From interface com.shinobicontrols.charts.DataAdapter.OnDataChangedListener
From interface java.lang.Iterable


protected final DataAdapter<Tx, Ty> dataAdapter

Public Constructors

public DataAdapterWrapper (DataAdapter<Tx, Ty> dataAdapter)

Public Methods

public boolean add (Data<Tx, Ty> dataPoint)

public void add (int location, Data<Tx, Ty> dataPoint)

public boolean addAll (int location, Collection<? extends Data<Tx, Ty>> dataPoints)

public boolean addAll (Collection<? extends Data<Tx, Ty>> dataPoints)

public void clear ()

public boolean contains (Object object)

public boolean containsAll (Collection<?> collection)

public Data<Tx, Ty> get (int location)

public abstract List<Data<Tx, Ty>> getDataPointsForDisplay ()

Implementations of this method should return a list of data points which are to be displayed on the chart. This method is called by the chart framework in response to notifyDataChanged(). It is not normally called by client code, though there is no harm in doing so.

  • a list of data points which are to be displayed on the chart

public int indexOf (Object object)

public boolean isEmpty ()

public Iterator<Data<Tx, Ty>> iterator ()

public int lastIndexOf (Object object)

public void onDataChanged ()

public Data<Tx, Ty> remove (int location)

public boolean remove (Object object)

public boolean removeAll (Collection<?> collection)

public boolean retainAll (Collection<?> collection)

public Data<Tx, Ty> set (int location, Data<Tx, Ty> dataPoint)

public int size ()

public T[] toArray (T[] array)

public Object[] toArray ()