Content Provider Permissions

  A provider's application can specify permissions that other applications must have in order to access the provider's data. These permissions ensure that the user knows what data an application will try to access. Based on the provider's requirements, other applications request the permissions they need in order to access the provider. End users see the requested permissions when they install the application.

  发布provider的应用可以给它指定个权限,没有这个权限,外部应用不可访问这个provider。

  If a provider's application doesn't specify any permissions, then other applications have no access to the provider's data. However, components in the provider's application always have full read and write access, regardless of the specified permissions.

  如果没有定义权限,那么只能本应用内访问这个 provider。

  As noted previously, the User Dictionary Provider requires the android.permission.READ_USER_DICTIONARY permission to retrieve data from it. The provider has the separate android.permission.WRITE_USER_DICTIONARY permission for inserting, updating, or deleting data.

  To get the permissions needed to access a provider, an application requests them with a <uses-permission> element in its manifest file. When the Android Package Manager installs the application, a user must approve all of the permissions the application requests. If the user approves all of them, Package Manager continues the installation; if the user doesn't approve them, Package Manager aborts the installation.

  The following <uses-permission> element requests read access to the User Dictionary Provider:

<uses-permission android:name="android.permission.READ_USER_DICTIONARY">

  The impact of permissions on provider access is explained in more detail in the Security and Permissions guide.

ContentProvider官方教程(4)ContentResolver权限的更多相关文章

  1. ContentProvider官方教程(5)ContentResolver插入、更新、删除 示例

    Inserting, Updating, and Deleting Data In the same way that you retrieve data from a provider, you a ...

  2. ContentProvider官方教程(3)ContentResolver查询、遍历 示例

    Retrieving Data from the Provider This section describes how to retrieve data from a provider, using ...

  3. ContentProvider官方教程(9)定义一个provider完整示例:实现方法,定义权限等

    Creating a Content Provider In this document Designing Data Storage Designing Content URIs Implement ...

  4. ContentProvider官方教程(7)3种访问形式:批处理、异步访问、intent间接访问(临时URI权限)

    Alternative Forms of Provider Access Three alternative forms of provider access are important in app ...

  5. ContentProvider官方教程(2)简介、Content URIs

    In this document Overview Accessing a provider Content URIs Content Provider Basics A content provid ...

  6. ContentProvider官方教程(10)<provider>元素及属性介绍

    The <provider> Element Like Activity and Service components, a subclass of ContentProvider mus ...

  7. ContentProvider官方教程(1)何时用content provider

    Content Providers Content providers manage access to a structured set of data. They encapsulate the ...

  8. ContentProvider官方教程(6)provider支持的数据类型

    Provider Data Types Content providers can offer many different data types. The User Dictionary Provi ...

  9. ContentProvider官方教程(11)Calendar Provider、Contacts Provider、Storage Access Framework

    Calendar Provider: guide/topics/providers/calendar-provider.html Contacts Provider: guide/topics/pro ...

随机推荐

  1. Android自定义ScrollView实现一键置顶功能

    效果图如下: (ps:动态图有太大了,上传不了,就给大家口述一下要实现的功能吧) 要实现的功能:当ScrollView向上滑动超过一定距离后,就渐变的出现一个置顶的按钮,当滑动距离小于我们指定的距离时 ...

  2. PHP与jquery前后台交互的小程序

    1 <!DOCTYPE HTML> <html> <head> <meta charset = "utf-8"> <scrip ...

  3. paper 28 :一些常见常用数据库的下载网站集锦

    做图像处理+模式识别的童鞋怎么可以没有数据库呢? 但是,如果自己做一个数据库,费时费力费钱先不说,关键是建立的数据库的公信力一般不会高,做出的算法也别人也不好比较,所以呢,下载比较权威的公共数据库还是 ...

  4. 关于nandflash与norflash

    读取速度:nor > nand 写入速度:nand > nor 擦除速度:nand 4ms,nor 5s nand的擦除单元更小,相应的擦除电路更少. nand的实际应用方式比nor复杂, ...

  5. Java高效编程之一【创建和销毁对象】

    一.考虑用静态工厂方法替代构造函数 代表实现:java.util.Collection Framework Boolean类的简单例子: public static Boolean valueOf ( ...

  6. android之‘com.example.android.apis.view’的代码段

    1.AutoCompleteTextView ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, and ...

  7. 如何自动生成Facade 的EJB

    1.jbuilder中连接数据库,注意:java:/DataSource 2.选择数据表,右健选择"create cmp 2.x..." 3.添加"findAll&quo ...

  8. android 中 listview 设置自动匹配高度

    1.布局文件 <ScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:l ...

  9. pstack使用和原理【转】

    转自:http://www.cnblogs.com/mumuxinfei/p/4366708.html 前言: 最近小组在组织<<深入剖析Nginx>>的读书会, 里面作者提到 ...

  10. ARM多核处理器启动过程分析【转】

    转自:http://blog.csdn.net/qianlong4526888/article/details/27695173 版权声明:本文为博主原创文章,未经博主允许不得转载. 说明: 该流程图 ...