Android Wing of mucchin | related API Reference



Uses-feature for Android app to write to the XML manifest


What makes sense to describe the manifest XML uses-feature of Android app?

Android Update This site is a long time.
Practices are a little busy, was away from the Android programming.
Time so that I finally, and I do Let's make the camera app on Android, began to make Bochibochi.
Meanwhile I think, about the tags that describe the manifest for some reason it caught in a strange "uses-feature", and today I want to write the article.


To use the camera feature in Android, the manifest XML file, you need a declaration of permission as follows.


<uses-permission android:name="android.permission.CAMERA">
</ Uses-permission>


However, There were many'm working on the site and let me look a lot, and there must be such as the following description.


<uses-feature android:name="android.hardware.camera" />
<uses-feature android:name="android.hardware.camera.autofocus" />




What is it "uses-feature" this?
And, wondering who would not do to others.

I now feel somehow mess.
Has given permission even though separately, why Why do we need this description.

Because it was Shakti or do not know why but apparent reason, and put this description of the uses-feature, this uses-feature without giving First of all, I tried to boot the camera function to implement.

Then, it worked without problems.
Also in the emulator, even Xperia.

Non-existence, this description of the uses-feature of what might be something for ... Ja.
I became more and more.

What would appear in a document of Android? I tried looking for.
Then, there was a description Rashiki it.

In the docs folder of the Android SDK, the following is the URL.
※ The installation, part of the head may be different.
C: \ android \ android-sdk-windows \ docs \ guide \ topics \ manifest \ uses-feature-element.html

Is a partial excerpt, short,
Is the implication seems to feature Android app is using and This is it, that you are declaring.
For example, in a non-terminal-equipped Android in Android Market, if you try to download an Android app that has this declaration, it is not allowed to download the camera.

I think as far as fine or better behavior and what I do not know, uses-feature is described by the above you, and who would be good for Android app also available for developers.

For developers, or will not have the advantage that it would not be suspected as the quality of Android's apps.

For example, suppose you have been up to the Android Market, the Android application with auto-focus camera.
Then, with the camera function but, Android user terminal equipped with a camera equipped with a non-auto focus, if you download the app.
Then, the user is, if you take a picture using the Android app, what would happen.
Perhaps, I will surely result in an error.
Then, "What, the camera this app! I can not take one or not photo! Also. ★ 's comments I'll Kusoapuri" might be.

However, that you describe the uses-feature, you can avoid such a misfortune.
Therefore, I think uses-feature, the developer Android, would be beneficial both describing the user.


I actually was, or how to become such behavior, or until it becomes really is not downloaded, but I do not mean that the verification, there is no loss to describe place.
uses-feature, let's on to describe as necessary!

2 3 Page 3 of a one two 3