Sending JSON as extra data in an android broadcast via ADB gets incorrectly formatted

前端 未结 4 686
暖寄归人
暖寄归人 2021-01-04 07:42

I\'m trying to send JSON data as extra on an Android broadcast which I send via ADB to the device. But it looks like the data which gets to the device is not as expected.

4条回答
  •  情书的邮戳
    2021-01-04 07:54

    ok, I just found a solution. I first have to enter the devices shell via adb shell and then execute am broadcast -a com.test.android.ACTION_TEST_FEATURE -n com.test.android/.receivers.TestsReceiver --es "notify" '{"debug": false, "title": "Application update!"}'

提交回复
热议问题