use of org.flyve.policies.manager.AndroidPolicies in project android-mdm-agent by flyve-mdm.
the class StorageEncryptionPolicy method process.
@Override
protected boolean process() {
try {
boolean enable = Boolean.parseBoolean(this.policyValue.toString());
AndroidPolicies androidPolicies = new AndroidPolicies(context, FlyveAdminReceiver.class);
androidPolicies.disableStatusBar(enable);
return true;
} catch (Exception ex) {
FlyveLog.e(this.getClass().getName() + ", process", ex.getMessage());
return false;
}
}
use of org.flyve.policies.manager.AndroidPolicies in project android-mdm-agent by flyve-mdm.
the class PasswordMinLengthPolicy method process.
@Override
protected boolean process() {
try {
int length = Integer.parseInt(this.policyValue.toString());
AndroidPolicies androidPolicies = new AndroidPolicies(context, FlyveAdminReceiver.class);
androidPolicies.setPasswordLength(length);
return true;
} catch (Exception ex) {
FlyveLog.e(this.getClass().getName() + ", process", ex.getMessage());
return false;
}
}
use of org.flyve.policies.manager.AndroidPolicies in project android-mdm-agent by flyve-mdm.
the class PasswordMinLowerCasePolicy method process.
@Override
protected boolean process() {
try {
int minimum = Integer.parseInt(this.policyValue.toString());
AndroidPolicies androidPolicies = new AndroidPolicies(context, FlyveAdminReceiver.class);
androidPolicies.setPasswordMinimumLowerCase(minimum);
return true;
} catch (Exception ex) {
FlyveLog.e(this.getClass().getName() + ", process", ex.getMessage());
return false;
}
}
use of org.flyve.policies.manager.AndroidPolicies in project android-mdm-agent by flyve-mdm.
the class MaximumFailedPasswordForWipePolicy method process.
@Override
protected boolean process() {
try {
int maximum = Integer.parseInt(this.policyValue.toString());
AndroidPolicies androidPolicies = new AndroidPolicies(context, FlyveAdminReceiver.class);
androidPolicies.setMaximumFailedPasswordsForWipe(maximum);
return true;
} catch (Exception ex) {
FlyveLog.e(this.getClass().getName() + ", process", ex.getMessage());
return false;
}
}
use of org.flyve.policies.manager.AndroidPolicies in project android-mdm-agent by flyve-mdm.
the class PasswordEnablePolicy method process.
@Override
protected boolean process() {
try {
String type = this.policyValue.toString();
AndroidPolicies androidPolicies = new AndroidPolicies(context, FlyveAdminReceiver.class);
androidPolicies.enablePassword(true, type, MainActivity.class);
return true;
} catch (Exception ex) {
FlyveLog.e(this.getClass().getName() + ", process", ex.getMessage());
return false;
}
}
Aggregations