<path-permission>
English Original: http://developer.android.com/guide/topics/manifest/path-permission-element.html
Acquisition (update) Date: 2014-7-1
Moved from the original blog: http://blog.sina.com.cn/s/blog_48d491300100zmut.html
-
-
Grammar:
-
-
<android:path= "string" android:pathprefix= "string" android:pathpattern= "string" android:permission= "string" android:readpermission= "string" android:writepermission= " String "/>
-
-
Included in:
-
-
<provider>
-
-
Description
-
-
defines the path and access permissions for a subset of data within a Content Provider. This element can be defined more than once to specify multiple paths.
-
-
Property:
-
-
-
android:path
-
-
Content Provider The full URI path of a subset of the data. Only this part of the data indicated on this path will be authorized. If Content Provider is used to provide search suggestions, it must be followed by "/search_suggest_query".
-
-
android:pathPrefix
-
-
Content Provider The beginning of the URI path of the data subset. All data that is prefixed with this path can be authorized.
-
-
android:pathPattern
-
-
Content Provider the full URI path to the subset of data, except that you can use the following wildcard characters:
- asterisk ("
* "). Matches 0 or more occurrences of the first character immediately following it.
- The period is followed by an asterisk ("
.* "). Matches 0 or more occurrences of any character.
When reading a string from XML (before parsing as an expression), ' \ is used as an escape character and therefore requires two escapes: for example, ' * should be written ', ' ' \\* \ should be written ' \\\\ . This is basically the same as the syntax for constructing strings in Java code.
For more information about these three expressions, see the description of Pattern_literal, Pattern_prefix, and Pattern_simple_glob in the Patternmatcher class.
-
-
android:permission
-
-
the name of the permission that the client must have to read and write Content Provider data. This property provides a convenient way to set both read and write permissions. However,
readPermission
writePermission properties can override this setting.
-
-
android:readPermission
-
-
the permissions that the client must have to query the Content Provider data.
-
-
android:writePermission
-
-
the permissions that the client must have to modify the data that the Content Provider controls.
Introduced from:
API Level 4
See:
SearchManager
Manifest.permission
Security and Permissions
Android Development-api Guide-<path-permission>