The manifest. Permission class defines 106 permissions for Android.

Source: Internet
Author: User

In androidmanifest. XML, We need to declare permissions for operations required by some software,
For example, if our software can send text messages, we need to make the following statement in androidmanifest. xml:

<? XML version = "1.0" encoding = "UTF-8"?>
<Manifest xmlns: Android = "http://schemas.android.com/apk/res/android"
Package = "cn.com. fetion. Android"
Android: versioncode = "1"
Android: versionname = "1.0.0">
<Application Android: icon = "@ drawable/icon" Android: Label = "@ string/app_name">
<Activity Android: Name = ". welcomactivity"
Android: Label = "@ string/app_name">
<Intent-filter>
<Action Android: Name = "android. Intent. Action. Main"/>
<Category Android: Name = "android. Intent. Category. launcher"/>
</Intent-filter>
</Activity>
</Application>
<Uses-Permission Android: Name = "android. Permission. send_sms"> </uses-Permission>
</Manifest>

Note the boldCodeIt means that the software has the function of sending text messages. If you do not declare this permission to call this function, an exception will occur,
The system does not report any specific exceptions.

What permissions do Android have to declare?
We can find the answer in the documentation provided by Android
For more information, see
Android-sdk-windows-1.6_r1 \ docs \ reference \ Android \ manifest.permission.html

 

The manifest. Permission class defines 106 permissions for Android.

Http://blog.csdn.net/kome2000/archive/2009/10/23/4716891.aspx for details

Related Article

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.