一部のデバイスでこのランダムな例外が発生しています。私は何が間違っているのだろうか。私がこの問題にどのような情報を提供できるか教えてください。私は、この質問をより有用にするのに役立つために他に何を提供できるのかわからない。私は私のアプリからのヒントを得ていない。キーがcom.google.android.gms.cast.framework.OPTIONS_PROVIDER_CLASS_NAMEのAndroidManifest.xml
0 java.lang.RuntimeException: Unable to create service com.google.android.gms.cast.framework.media.MediaNotificationService: java.lang.IllegalStateException: The fully qualified name of the implementation of OptionsProvider must be provided as a metadata in the AndroidManifest.xml with key com.google.android.gms.cast.framework.OPTIONS_PROVIDER_CLASS_NAME.
1 at android.app.ActivityThread.handleCreateService(ActivityThread.java:2474)
2 at android.app.ActivityThread.access$1600(ActivityThread.java:130)
3 at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1293)
4 at android.os.Handler.dispatchMessage(Handler.java:99)
5 at android.os.Looper.loop(Looper.java:137)
6 at android.app.ActivityThread.main(ActivityThread.java:4847)
7 at java.lang.reflect.Method.invokeNative(Native Method)
8 at java.lang.reflect.Method.invoke(Method.java:535)
9 at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)
10 at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)
11 at dalvik.system.NativeStart.main(Native Method)
12 Caused by: java.lang.IllegalStateException: The fully qualified name of the implementation of OptionsProvider must be provided as a metadata in the AndroidManifest.xml with key com.google.android.gms.cast.framework.OPTIONS_PROVIDER_CLASS_NAME.
13 at com.google.android.gms.cast.framework.CastContext.zzbd(Unknown Source)
14 at com.google.android.gms.cast.framework.CastContext.getSharedInstance(Unknown Source)
15 at com.google.android.gms.cast.framework.media.MediaNotificationService.onCreate(Unknown Source)
16 at android.app.ActivityThread.handleCreateService(ActivityThread.java:2458)
17 ... 10 more
18 java.lang.IllegalStateException: The fully qualified name of the implementation of OptionsProvider must be provided as a metadata in the AndroidManifest.xml with key com.google.android.gms.cast.framework.OPTIONS_PROVIDER_CLASS_NAME.
19 at com.google.android.gms.cast.framework.CastContext.zzbd(Unknown Source)
20 at com.google.android.gms.cast.framework.CastContext.getSharedInstance(Unknown Source)
21 at com.google.android.gms.cast.framework.media.MediaNotificationService.onCreate(Unknown Source)
22 at android.app.ActivityThread.handleCreateService(ActivityThread.java:2458)
23 at android.app.ActivityThread.access$1600(ActivityThread.java:130)
24 at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1293)
25 at android.os.Handler.dispatchMessage(Handler.java:99)
26 at android.os.Looper.loop(Looper.java:137)
27 at android.app.ActivityThread.main(ActivityThread.java:4847)
28 at java.lang.reflect.Method.invokeNative(Native Method)
29 at java.lang.reflect.Method.invoke(Method.java:535)
30 at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)
31 at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)
32 at dalvik.system.NativeStart.main(Native Method)
編集 - ManifestFile
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.mcruiseon.buseeta">
<!-- For Options menu call support -->
<uses-permission android:name="android.permission.CALL_PHONE"/>
<!-- To auto-complete the email text field in the login form with the user's emails -->
<uses-permission android:name="android.permission.READ_PHONE_STATE"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<!-- To auto-complete the email text field in the login form with the user's emails -->
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES"/>
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
<!-- For the background service to run forever -->
<uses-permission android:name="android.permission.WAKE_LOCK"/>
<!-- For Current Location on Driver App -->
<permission
android:name="${manifestApplicationId}.permission.MAPS_RECEIVE"
android:protectionLevel="signature"/>
<uses-permission android:name="${manifestApplicationId}.permission.MAPS_RECEIVE"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<!-- For QR Code -->
<uses-permission android:name="android.permission.WRITE_INTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.CAMERA"/>
<uses-feature android:name="android.hardware.Camera"/>
<uses-permission android:name="android.permission.GET_TASKS"/>
<!-- Google Cloud Messaging -->
<uses-permission
android:name="${manifestApplicationId}.permission.C2D_MESSAGE"
android:protectionLevel="signature"/>
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE"/>
<uses-feature
android:glEsVersion="0x00020000"
android:required="true"/>
<application
android:name="com.mcruiseon.buseeta.InitializingApplication"
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:largeHeap="true"
android:supportsRtl="true"
android:theme="@style/AppTheme.NoActionBar">
<meta-data
android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version"/>
<meta-data
android:name="com.google.android.geo.API_KEY"
android:value="${mapsKey}"/>
<activity
-- MY ACTIVITIES --
</activity>
</application>
</manifest>
あなたのmanifest.xmlを共有していただけますか?任意のOptionsProviderやCastContextの実装をあなたのアプリケーション(依存するlib、モジュールからも)にも持っていますか? – Devrim
このページを見て、あなたのマニフェストには情報が欠けているか、そこには情報がありません。あなたの 'CastOptionsProvider'はフルネームをそのキーの値に入れて、インスタンス化するものを知る必要があります。 https://developers.google.com/android/reference/com/google/android/gms/cast/framework/CastContext –
CastOptionsProviderを使用するアクティビティや呼び出しはありません。 – Siddharth