普通广播:sendBroadcast

  有序广播:sendOrderedBroadcast,有序广播优先级可以再manifest中设置,数值越大,最先收到。-1000~1000

 <receiver android:name=".B">
       <intent-filter android:priority="3">
           <action android:name="action.string" />
       </intent-filter>         
   </receiver>

  有序广播可以被停止: this.abortBroadcast();,普通广播调用该方法会抛异常!

  广播是可以跨进程的。

相关文章:

  • 2022-03-10
  • 2021-12-23
  • 2021-07-16
  • 2021-07-31
  • 2022-01-14
  • 2021-05-17
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-01-08
  • 2022-12-23
  • 2021-05-12
  • 2021-09-02
  • 2021-05-19
  • 2022-12-23
  • 2021-06-10
相关资源
相似解决方案