/packages/apps/Email/tests/src/com/android/email/ |
H A D | MockVendorPolicy.java | 29 public static Bundle getPolicy(String policy, Bundle args) { argument 30 passedPolicy = policy;
|
H A D | SecurityPolicyTests.java | 112 Policy policy = new Policy(); 113 policy.mPasswordMinLength = minPasswordLength; 114 policy.mPasswordMode = passwordMode; 115 policy.mPasswordMaxFails = maxPasswordFails; 116 policy.mMaxScreenLockTime = maxScreenLockTime; 117 policy.mRequireRemoteWipe = requireRemoteWipe; 118 policy.mPasswordExpirationDays = passwordExpirationDays; 119 policy.mPasswordHistory = passwordHistory; 120 policy.mPasswordComplexChars = passwordComplexChars; 121 policy 479 policySetEqualsPolicy(PolicySet ps, Policy policy) argument [all...] |
/packages/inputmethods/LatinIME/native/jni/src/suggest/policyimpl/utils/ |
H A D | edit_distance.h | 30 AK_FORCE_INLINE static float getEditDistance(const EditDistancePolicy *const policy) { argument 31 const int beforeLength = policy->getString0Length(); 32 const int afterLength = policy->getString1Length(); 35 dp[(afterLength + 1) * i] = i * policy->getInsertionCost(i - 1, -1); 38 dp[i] = i * policy->getDeletionCost(-1, i - 1); 44 dp[(afterLength + 1) * i + (j + 1)] + policy->getInsertionCost(i, j), 46 dp[(afterLength + 1) * (i + 1) + j] + policy->getDeletionCost(i, j), 47 dp[(afterLength + 1) * i + j] + policy->getSubstitutionCost(i, j))); 48 if (policy->allowTransposition(i, j)) { 52 + policy [all...] |
/packages/experimental/SELinux/CTS/src/ |
H A D | gen_SELinux_CTS.py | 2 # genCheckAccessCTS.py - takes an input SELinux policy.conf file and generates 5 # components which a checkAccess() check, that a policy manager would have to 8 # This test does not work with all valid SELinux policy.conf files. It is meant 9 # to simply use a given AOSP generated policy.conf file to create sets 10 # representing the policy's types, attributes, classes and permissions, which 33 policy = SELinuxPolicy() variable 34 policy.from_file_name(input_file) #load data from file 39 for a in policy.allow_rules: 40 expanded_xml = SELinux_CTS.expand_avc_rule_to_xml(policy, a, str(count), 'allow') 45 for n in policy [all...] |
/packages/apps/Email/emailcommon/src/com/android/emailcommon/service/ |
H A D | PolicyServiceProxy.java | 61 // This is not a great situation, but it's better to act like the policy isn't enforced 71 public void setAccountPolicy(final long accountId, final Policy policy, argument 73 setAccountPolicy2(accountId, policy, securityKey, true /* notify */); 77 public void setAccountPolicy2(final long accountId, final Policy policy, argument 82 mService.setAccountPolicy2(accountId, policy, securityKey, notify); 97 // This is not a great situation, but it's better to act like the policy isn't enforced 151 public static void setAccountPolicy(Context context, long accountId, Policy policy, argument 153 setAccountPolicy2(context, accountId, policy, securityKey, true /* notify */); 156 public static void setAccountPolicy2(Context context, long accountId, Policy policy, argument 159 new PolicyServiceProxy(context).setAccountPolicy2(accountId, policy, securityKe [all...] |
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/widget/ |
H A D | ViewsStateBundle.java | 60 public ViewsStateBundle(int policy, int limit) { argument 61 savePolicy = policy; 122 * Save views regardless what's the current policy is. 135 * The visible view is saved when policy is not {@link #SAVE_NO_CHILD}. 156 * Save list of visible views without checking policy. The method is to be implemented by 162 * Save views according to policy.
|
/packages/apps/Email/provider_src/com/android/email/ |
H A D | SecurityPolicy.java | 76 * Get the security policy instance 103 * Compute the aggregate policy for all accounts that require it, and record it. 116 * @return a policy representing the strongest aggregate. If no policy sets are defined, 117 * a lightweight "nothing required" policy will be returned. Never null. 140 Policy policy = new Policy(); 143 policy.restore(c); 145 LogUtils.d(TAG, "Aggregate from: " + policy); 148 Math.max(policy.mPasswordMinLength, aggregate.mPasswordMinLength); 149 aggregate.mPasswordMode = Math.max(policy 249 isActive(Policy policy) argument 319 getInactiveReasons(Policy policy) argument 536 setAccountPolicy(Context context, Account account, Policy policy, String securitySyncKey) argument 597 setAccountPolicy(long accountId, Policy policy, String securityKey, boolean notify) argument [all...] |
/packages/apps/Exchange/src/com/android/exchange/adapter/ |
H A D | ProvisionParser.java | 95 * policy documents, as all versions of the OS support the policies in xml documents). 97 private void setPolicy(Policy policy) { argument 98 policy.normalize(); 100 if (policy.mDontAllowAttachments) { 103 if (policy.mRequireManualSyncWhenRoaming) { 106 policy.mProtocolPoliciesEnforced = sb.toString(); 107 mPolicy = policy; 118 Policy policy = new Policy(); 129 if (policy.mPasswordMode == Policy.PASSWORD_MODE_NONE) { 130 policy 451 parseCharacteristic(XmlPullParser parser, Policy policy) argument 493 parseRegistry(XmlPullParser parser, Policy policy) argument 508 parseWapProvisioningDoc(XmlPullParser parser, Policy policy) argument [all...] |
/packages/apps/Email/emailcommon/src/com/android/emailcommon/ |
H A D | VendorPolicyLoader.java | 30 * A bridge class to the email vendor policy apk. 32 * <p>Email vendor policy is a system apk named "com.android.email.helper". When exists, it must 33 * contain a class called "com.android.email.policy.EmailPolicy" with a static public method 36 * <p>A vendor policy apk is optional. The email application will operate properly when none is 40 private static final String POLICY_PACKAGE = "com.android.email.policy"; 79 LogUtils.d(Logging.LOG_TAG, String.format("Using policy: package=%s name=%s", 118 // Package not found -- it's okay - there's no policy .apk found, which is OK 140 * Calls the getPolicy method in the policy apk, if one exists. This method never returns null; 141 * It returns an empty {@link Bundle} when there is no policy apk (or even if the inner 145 public Bundle getPolicy(String policy, Bundl argument [all...] |
/packages/apps/Email/src/com/android/email/activity/setup/ |
H A D | SetupDataFragment.java | 40 private static final String SAVESTATE_POLICY = "SetupDataFragment.policy"; 162 public synchronized void setPolicy(Policy policy) { argument 163 mPolicy = policy; 278 sb.append(":policy=");
|
H A D | AccountSettingsFragment.java | 103 @SuppressWarnings("unused") // temporarily unused pending policy UI 105 @SuppressWarnings("unused") // temporarily unused pending policy UI 591 @SuppressWarnings("unused") // temporarily unused pending policy UI 592 private ArrayList<String> getSystemPoliciesList(Policy policy) { argument 595 if (policy.mPasswordMode != Policy.PASSWORD_MODE_NONE) { 598 if (policy.mPasswordHistory > 0) { 601 if (policy.mPasswordExpirationDays > 0) { 604 if (policy.mMaxScreenLockTime > 0) { 607 if (policy.mDontAllowCamera) { 610 if (policy [all...] |
/packages/apps/Settings/src/com/android/settings/widget/ |
H A D | ChartDataUsageView.java | 165 public void bindNetworkPolicy(NetworkPolicy policy) { argument 166 if (policy == null) { 174 if (policy.limitBytes != NetworkPolicy.LIMIT_DISABLED) { 177 mSweepLimit.setValue(policy.limitBytes); 184 if (policy.warningBytes != NetworkPolicy.WARNING_DISABLED) { 186 mSweepWarning.setValue(policy.warningBytes); 218 // always show known data and policy lines
|
/packages/apps/Email/emailcommon/src/com/android/emailcommon/provider/ |
H A D | Policy.java | 47 CONTENT_URI = Uri.parse(EmailContent.CONTENT_URI + "/policy"); 52 /* Small offset (2 minutes) added to policy expiration to make user testing easier. */ 176 // We override this method to insure that we never write invalid policy data to the provider 188 * @param policy the new policy for this account 191 Policy policy) { 200 int policyMax = policy.mDontAllowAttachments ? 0 : (policy.mMaxAttachmentSize > 0) ? 201 policy.mMaxAttachmentSize : Integer.MAX_VALUE; 190 setAttachmentFlagsForNewPolicy(Context context, Account account, Policy policy) argument
|
/packages/apps/Settings/src/com/android/settings/ |
H A D | DataUsageSummary.java | 983 //TODO: deprecate and remove this once enabled flag is on policy 1009 private boolean isNetworkPolicyModifiable(NetworkPolicy policy) { argument 1010 return policy != null && isBandwidthControlEnabled() && mDataEnabled.isChecked() 1055 // TODO: move enabled state directly into policy 1062 final NetworkPolicy policy = mPolicyEditor.getPolicy(mTemplate); 1064 if (isNetworkPolicyModifiable(policy) && isMobileDataAvailable(getSubId(mCurrentTab))) { 1065 mDisableAtLimit.setChecked(policy != null && policy.limitBytes != LIMIT_DISABLED); 1067 mChart.bindNetworkPolicy(policy); 1080 // generate cycle list based on policy an 1090 updateCycleList(NetworkPolicy policy) argument [all...] |