Package com.brightcove.cast
Class DefaultOptionsProvider
- java.lang.Object
-
- com.brightcove.cast.DefaultOptionsProvider
-
- All Implemented Interfaces:
com.google.android.gms.cast.framework.OptionsProvider
public class DefaultOptionsProvider extends java.lang.Object implements com.google.android.gms.cast.framework.OptionsProvider
This class configures three key components of the Google Cast: The Cast Receiver App Id, the Expanded Controller Activity and the Notification Target Activity. By Default, only the Cast Receiver App Id is set, which is under the strings.xml file with the key cast_receiver_app_id. You can replace this id by overriding the same key in your strings.xmk file. You need to set the ExpandedControllerActivity through the AndroidManifest as meta-data as shown below:<meta-data android:name="com.brightcove.cast.DefaultOptionsProvider.EXPANDED_CONTROLLER_ACTIVITY_CLASS_NAME" android:value="com.brightcove.cast.DefaultExpandedControllerActivity" />
In the same way, you can set the Notification Target Activity, for example:<meta-data android:name="com.brightcove.cast.DefaultOptionsProvider.OPTIONS_PROVIDER_CLASS_NAME" android:value="com.brightcove.cast.DefaultExpandedControllerActivity" />
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
EXPANDED_CONTROLLER_ACTIVITY_CLASS_NAME
static java.lang.String
NOTIFICATION_TARGET_ACTIVITY_CLASS_NAME
static java.lang.String
TAG
-
Constructor Summary
Constructors Constructor Description DefaultOptionsProvider()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<com.google.android.gms.cast.framework.SessionProvider>
getAdditionalSessionProviders(android.content.Context context)
com.google.android.gms.cast.framework.CastOptions
getCastOptions(android.content.Context context)
-
-
-
Field Detail
-
TAG
public static final java.lang.String TAG
-
EXPANDED_CONTROLLER_ACTIVITY_CLASS_NAME
public static final java.lang.String EXPANDED_CONTROLLER_ACTIVITY_CLASS_NAME
- See Also:
- Constant Field Values
-
NOTIFICATION_TARGET_ACTIVITY_CLASS_NAME
public static final java.lang.String NOTIFICATION_TARGET_ACTIVITY_CLASS_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
getCastOptions
public com.google.android.gms.cast.framework.CastOptions getCastOptions(android.content.Context context)
- Specified by:
getCastOptions
in interfacecom.google.android.gms.cast.framework.OptionsProvider
-
getAdditionalSessionProviders
public java.util.List<com.google.android.gms.cast.framework.SessionProvider> getAdditionalSessionProviders(android.content.Context context)
- Specified by:
getAdditionalSessionProviders
in interfacecom.google.android.gms.cast.framework.OptionsProvider
-
-