Google is committed to advancing racial equity for Black communities. See how.

DataBufferObserver

public interface DataBufferObserver
Known Indirect Subclasses

An interface for notifying an observer about changes to a DataBuffer.

To support adding multiple observers, see DataBufferObserverSet. It allows you to delegate addObserver and removeObserver to it and it will handle distributing all the notifications to all registered observers.

See Also

Nested Class Summary

interface DataBufferObserver.Observable Interface a data buffer can implement to expose the fact that it supports observation. 

Public Method Summary

abstract void
onDataChanged()
Called when the overall data changes.
abstract void
onDataRangeChanged(int position, int count)
Called when a range of items changes.
abstract void
onDataRangeInserted(int position, int count)
Called when a range of items is inserted.
abstract void
onDataRangeMoved(int fromPosition, int toPosition, int count)
Called when a range of items is moved.
abstract void
onDataRangeRemoved(int position, int count)
Called when a range of items is removed.

Public Methods

public abstract void onDataChanged ()

Called when the overall data changes.

public abstract void onDataRangeChanged (int position, int count)

Called when a range of items changes.

public abstract void onDataRangeInserted (int position, int count)

Called when a range of items is inserted.

public abstract void onDataRangeMoved (int fromPosition, int toPosition, int count)

Called when a range of items is moved.

public abstract void onDataRangeRemoved (int position, int count)

Called when a range of items is removed.