Android Development-api Guide-<path-permission>

Source: Internet
Author: User

<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>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.