am 1014b9aa: Merge "docs: remove references to resource browser; point to SDK instead" into klp-modular-docs

* commit '1014b9aa491d4d7dd4d4fc2510e7b6e6b3b4654d':
  docs: remove references to resource browser; point to SDK instead
This commit is contained in:
Scott Rowe
2014-08-29 21:04:16 +00:00
committed by Android Git Automerger

View File

@ -28,12 +28,6 @@ page.tags="devicepolicymanager","policy","security"
<li>{@link android.app.admin.DevicePolicyManager}</li> <li>{@link android.app.admin.DevicePolicyManager}</li>
<li>{@link android.app.admin.DeviceAdminInfo}</li> <li>{@link android.app.admin.DeviceAdminInfo}</li>
</ol> </ol>
<h2>Related samples</h2>
<ol>
<li><a
href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/app/DeviceAdminSample.html">
DeviceAdminSample</a></li>
</ol>
</div> </div>
</div> </div>
@ -232,18 +226,12 @@ Administration API lets you do the following:</p> <ul>
<h2 id="sample">Sample Application</h2> <h2 id="sample">Sample Application</h2>
<p>The examples used in this document are based on the <a <p>The examples used in this document are based on the Device Administration API
href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/app/DeviceAdminSample.html"> sample, which is included in the SDK samples (available through the
Device Administration API Android SDK Manager) and located on your system as
sample</a>, which is included in the SDK samples. For information on downloading and <code>&lt;sdk_root&gt;/ApiDemos/app/src/main/java/com/example/android/apis/app/DeviceAdminSample.java</code>.</p>
installing the SDK samples, see <a
href="{@docRoot}resources/samples/get.html"> <p>The sample application offers a demo of device admin features. It presents users
Getting the Samples</a>. Here is the <a
href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/app/DeviceAdminSample.html">
complete code</a> for
the sample. </p>
<p>The
sample application offers a demo of device admin features. It presents users
with a user interface that lets them enable the device admin application. Once with a user interface that lets them enable the device admin application. Once
they've enabled the application, they can use the buttons in the user interface they've enabled the application, they can use the buttons in the user interface
to do the following:</p> to do the following:</p>
@ -676,7 +664,8 @@ mDPM.setMaximumTimeToLock(mDeviceAdminSample, timeMs);
<p>You can also programmatically tell the device to lock immediately:</p> <p>You can also programmatically tell the device to lock immediately:</p>
<pre> <pre>
DevicePolicyManager mDPM; DevicePolicyManager mDPM;
mDPM.lockNow();</pre> mDPM.lockNow();
</pre>
@ -692,12 +681,12 @@ wiped after a specific number of failed password attempts.</p>
<pre> <pre>
DevicePolicyManager mDPM; DevicePolicyManager mDPM;
mDPM.wipeData(0);</pre> mDPM.wipeData(0);</pre>
<p>The {@link android.app.admin.DevicePolicyManager#wipeData wipeData()} method takes as its parameter a bit mask of <p>The {@link android.app.admin.DevicePolicyManager#wipeData wipeData()} method takes as its
additional options. Currently the value must be 0. </p> parameter a bit mask of additional options. Currently the value must be 0. </p>
<h4>Disable camera</h4> <h4>Disable camera</h4>
<p>Beginning with Android 4.0, you can disable the camera. Note that this doesn't have to be a permanent disabling. The camera can be enabled/disabled dynamically based on context, time, and so on. </p> <p>Beginning with Android 4.0, you can disable the camera. Note that this doesn't have to be a permanent disabling. The camera can be enabled/disabled dynamically based on context, time, and so on. </p>
<p>You control whether the camera is disabled by using the <p>You control whether the camera is disabled by using the
{@link android.app.admin.DevicePolicyManager#setCameraDisabled(android.content.ComponentName, boolean) setCameraDisabled()} method. For example, this snippet sets the camera to be enabled or disabled based on a checkbox setting:</p> {@link android.app.admin.DevicePolicyManager#setCameraDisabled(android.content.ComponentName, boolean) setCameraDisabled()} method. For example, this snippet sets the camera to be enabled or disabled based on a checkbox setting:</p>
<pre>private CheckBoxPreference mDisableCameraCheckbox; <pre>private CheckBoxPreference mDisableCameraCheckbox;
@ -708,8 +697,8 @@ mDPM.setCameraDisabled(mDeviceAdminSample, mDisableCameraCheckbox.isChecked());<
</pre> </pre>
<h4 id=storage">Storage encryption</h4> <h4 id="storage">Storage encryption</h4>
<p>Beginning with Android 3.0, you can use the <p>Beginning with Android 3.0, you can use the
{@link android.app.admin.DevicePolicyManager#setStorageEncryption(android.content.ComponentName,boolean) setStorageEncryption()} {@link android.app.admin.DevicePolicyManager#setStorageEncryption(android.content.ComponentName,boolean) setStorageEncryption()}
method to set a policy requiring encryption of the storage area, where supported.</p> method to set a policy requiring encryption of the storage area, where supported.</p>
@ -722,5 +711,5 @@ ComponentName mDeviceAdminSample;
mDPM.setStorageEncryption(mDeviceAdminSample, true); mDPM.setStorageEncryption(mDeviceAdminSample, true);
</pre> </pre>
<p> <p>
See the <a href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/app/DeviceAdminSample.html"> Device Administration API sample</a> for a complete See the Device Administration API sample for a complete example of how to enable storage encryption.
example of how to enable storage encryption.</p> </p>