to top
Android APIs
 

device_admin_quality.xml

← Back

The file containing the source code shown below is located in the corresponding directory in <sdk>/samples/android-<version>/...

<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2011 The Android开源工程

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
     You may obtain a copy of the License at

          http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the License is distributed on an "AS IS" BASIS,
     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     See the License for the specific language governing permissions and
     limitations under the License.
-->

<!-- A set of preferences used to exercise the DevicePolicyManager API. -->
<!-- This screen is shown for the "Password Quality" header. -->
<PreferenceScreen
    xmlns:android="http://schemas.android.com/apk/res/android" >

    <PreferenceCategory
        android:title="@string/password_controls_category" >

        <PreferenceScreen
            android:key="key_set_password"
            android:title="@string/set_password_user" />
        <EditTextPreference
            android:key="key_reset_password"
            android:title="@string/set_password_api"
            android:dialogTitle="@string/set_password_api_dialog" />
    </PreferenceCategory>

    <PreferenceCategory
        android:key="key_category_quality"
        android:title="@string/password_quality_category" >

        <ListPreference
            android:key="key_quality"
            android:title="@string/password_quality"
            android:entries="@array/password_qualities"
            android:dialogTitle="@string/password_quality" />
        <EditTextPreference
            android:key="key_minimum_length"
            android:title="@string/password_minimum_length"
            android:dialogTitle="@string/password_minimum_length"
            android:inputType="number" />
        <EditTextPreference
            android:key="key_minimum_letters"
            android:title="@string/password_minimum_letters"
            android:dialogTitle="@string/password_minimum_letters" />
        <EditTextPreference
            android:key="key_minimum_numeric"
            android:title="@string/password_minimum_numeric"
            android:dialogTitle="@string/password_minimum_numeric"
            android:inputType="number"  />
        <EditTextPreference
            android:key="key_minimum_lower_case"
            android:title="@string/password_minimum_lower_case"
            android:dialogTitle="@string/password_minimum_lower_case"
            android:inputType="number"  />
        <EditTextPreference
            android:key="key_minimum_upper_case"
            android:title="@string/password_minimum_upper_case"
            android:dialogTitle="@string/password_minimum_upper_case"
            android:inputType="number"  />
        <EditTextPreference
            android:key="key_minimum_symbols"
            android:title="@string/password_minimum_symbols"
            android:dialogTitle="@string/password_minimum_symbols"
            android:inputType="number"  />
        <EditTextPreference
            android:key="key_minimum_non_letter"
            android:title="@string/password_minimum_non_letter"
            android:dialogTitle="@string/password_minimum_non_letter"
            android:inputType="number"  />
    </PreferenceCategory>

</PreferenceScreen>