Android:exported 属性知识

791 阅读1分钟

1、android:exported 是 Android中的四大组件 Activity,Service,Provider,Receiver 四大组件中都会有的一个属性。
2、android:exported 代表是否能被其他应用隐式调用。
3、true允许被启动,false不允许被启动。
4、android:exported 默认值是由有无intent-filter决定的,如果有intent-filter,默认值为true,否则为false。
5、android:exported = false的情况下,这个Activity将只会被当前Application或者拥有同样user ID的Application的组件调用,对于其他应用,即使有intent-filter匹配,也无法打开,即无法被其他应用隐式调用。

本文转自 blog.csdn.net/wl724120268…allfirst_rank_ecpm_v1~times_rank-8-123108211-null-null.142^v59^new_blog_pos_by_title,201^v3^control_2&utm_term=Android&spm=1018.2226.3001.4187,如有侵权,请联系删除。