TvAdView.TvAdCallback
public
static
abstract
class
TvAdView.TvAdCallback
extends Object
| java.lang.Object | |
| ↳ | android.media.tv.ad.TvAdView.TvAdCallback |
Callback used to receive various status updates on the TvAdView.
Summary
Public constructors | |
|---|---|
TvAdCallback()
|
|
Public methods | |
|---|---|
void
|
onRequestCurrentChannelUri(String serviceId)
This is called when |
void
|
onRequestCurrentTvInputId(String serviceId)
This is called when |
void
|
onRequestCurrentVideoBounds(String serviceId)
This is called when |
void
|
onRequestSigning(String serviceId, String signingId, String algorithm, String alias, byte[] data)
This is called when
|
void
|
onRequestTrackInfoList(String serviceId)
This is called when |
void
|
onStateChanged(String serviceId, int state, int err)
This is called when the state of corresponding AD service is changed. |
Inherited methods | |
|---|---|
Public constructors
TvAdCallback
public TvAdCallback ()
Public methods
onRequestCurrentChannelUri
public void onRequestCurrentChannelUri (String serviceId)
This is called when TvAdService.Session.requestCurrentChannelUri() is
called.
| Parameters | |
|---|---|
serviceId |
String: The ID of the AD service bound to this view.
This value cannot be null. |
onRequestCurrentTvInputId
public void onRequestCurrentTvInputId (String serviceId)
This is called when TvAdService.Session.requestCurrentTvInputId() is called.
| Parameters | |
|---|---|
serviceId |
String: The ID of the AD service bound to this view.
This value cannot be null. |
onRequestCurrentVideoBounds
public void onRequestCurrentVideoBounds (String serviceId)
This is called when TvAdService.Session.requestCurrentVideoBounds()
is called.
| Parameters | |
|---|---|
serviceId |
String: The ID of the TV AD service bound to this view.
This value cannot be null. |
onRequestSigning
public void onRequestSigning (String serviceId, String signingId, String algorithm, String alias, byte[] data)
This is called when
TvAdService.Session.requestSigning(String, String, String, byte[]) is called.
| Parameters | |
|---|---|
serviceId |
String: The ID of the AD service bound to this view.
This value cannot be null. |
signingId |
String: the ID to identify the request.
This value cannot be null. |
algorithm |
String: the standard name of the signature algorithm requested, such as
MD5withRSA, SHA256withDSA, etc.
This value cannot be null. |
alias |
String: the alias of the corresponding KeyStore.
This value cannot be null. |
data |
byte: the original bytes to be signed.
This value cannot be null. |
onRequestTrackInfoList
public void onRequestTrackInfoList (String serviceId)
This is called when TvAdService.Session.requestTrackInfoList() is called.
| Parameters | |
|---|---|
serviceId |
String: The ID of the AD service bound to this view.
This value cannot be null. |
onStateChanged
public void onStateChanged (String serviceId, int state, int err)
This is called when the state of corresponding AD service is changed.
| Parameters | |
|---|---|
serviceId |
String: The ID of the AD service bound to this view.
This value cannot be null. |
state |
int: the current state.
Value is TvAdManager.SESSION_STATE_STOPPED, TvAdManager.SESSION_STATE_RUNNING, or TvAdManager.SESSION_STATE_ERROR |
err |
int: the error code for error state. TvAdManager.ERROR_NONE
is used when the state is not
TvAdManager.SESSION_STATE_ERROR.
Value is TvAdManager.ERROR_NONE, TvAdManager.ERROR_UNKNOWN, TvAdManager.ERROR_NOT_SUPPORTED, TvAdManager.ERROR_WEAK_SIGNAL, TvAdManager.ERROR_RESOURCE_UNAVAILABLE, TvAdManager.ERROR_BLOCKED, TvAdManager.ERROR_ENCRYPTED, or TvAdManager.ERROR_UNKNOWN_CHANNEL |