ViewProvider
@UnstableApi
public interface ViewProvider
MediaRouteButtonViewProvider |
A provider of a media route button view to be displayed in the player UI. |
Provider of a view to be displayed in the player UI.
Summary
Public methods |
|
|---|---|
abstract ListenableFuture<View> |
Returns a |
Public methods
getView
abstract ListenableFuture<View> getView(ViewGroup viewGroup)
Returns a ListenableFuture with the view.
If the view cannot be provided, the future may fail with an exception. Consumers should handle the failure gracefully, for example by not showing the view.
The callback of the returned ListenableFuture may be called on a different thread than the caller's thread. If the caller wants to update the UI in the callbacks, it is responsible for forwarding the callback to the UI thread.
| Returns | |
|---|---|
ListenableFuture<View> |
A |