class DBService implements RolesProvider {

    void updateRoleMembersSystemDisabledState(ResourceContext ctx, ObjectStoreConnection con, final String domainName,
                                              final String roleName, Role originalRole, Role updatedRole,
                                              final String auditRef, final String caller) {

        // if it's a delegated role then we have nothing to do

        if (originalRole.getTrust() != null && !originalRole.getTrust().isEmpty()) {
            return;
        }

        // if no role members, then there is nothing to do

        final List<RoleMember> roleMembers = originalRole.getRoleMembers();
        if (roleMembers == null || roleMembers.isEmpty()) {
            return;
        }

        // check if the authority filter has changed otherwise we have
        // nothing to do

        if (!isUserAuthorityFilterChanged(originalRole.getUserAuthorityFilter(), updatedRole.getUserAuthorityFilter())) {
            return;
        }

        final String principal = getPrincipalName(ctx);

        // process our role members and if there were any changes processed then update
        // our role and domain time-stamps, and invalidate local cache entry

        List<RoleMember> roleMembersWithUpdatedDisabledState = getRoleMembersWithUpdatedDisabledState(roleMembers,
                updatedRole.getUserAuthorityFilter(), getDomainUserAuthorityFilter(con, domainName));
        if (updateRoleMemberDisabledState(ctx, con, roleMembersWithUpdatedDisabledState, domainName,
                roleName, principal, auditRef, caller)) {

            // update our role and domain time-stamps, and invalidate local cache entry

            con.updateRoleModTimestamp(domainName, roleName);
            con.updateDomainModTimestamp(domainName);
            cacheStore.invalidate(domainName);
        }
    }

    public  DBService(ObjectStore store, AuditLogger auditLogger, ZMSConfig zmsConfig, AuditReferenceValidator auditReferenceValidator);

}