/** * Returns <code>true</code> if any of the configured realms' * {@link Realm#isPermitted(org.apache.shiro.subject.PrincipalCollection , String)} returns <code>true</code>, * <code>false</code> otherwise. */ public boolean isPermitted(PrincipalCollection principals, String permission) { assertRealmsConfigured(); for (Realm realm : getRealms()) { if (realm.isPermitted(principals, permission)) { return true; } } return false; }
/** * Returns <code>true</code> if any of the configured realms' * {@link Realm#isPermitted(org.apache.shiro.subject.PrincipalCollection , Permission)} call returns <code>true</code>, * <code>false</code> otherwise. */ public boolean isPermitted(PrincipalCollection principals, Permission permission) { assertRealmsConfigured(); for (Realm realm : getRealms()) { if (realm.isPermitted(principals, permission)) { return true; } } return false; }