public void removeRole(Accreditable accreditable, Role role) throws AccessControlException {
assert accreditable != null;
assert role != null;
Credential credential = getCredential(accreditable);
if (credential == null) {
throw new AccessControlException(
"No credential for accreditable ["
+ accreditable
+ "] ["
+ accreditableToCredential.keySet().size()
+ "]");
}
if (!credential.contains(role)) {
throw new AccessControlException(
"Credential for accreditable ["
+ accreditable
+ "] does not contain role ["
+ role
+ "]");