class GrantedAuthorityMapper {

    public Set<GrantedAuthority> getAuthorities(Collection<Role> roles) {
        Set<GrantedAuthority> auths = new HashSet<>();
        auths.addAll(getPermissionGrants(roles));
        auths.addAll(getRoleGrants(roles));
        return auths;
    }

    public  GrantedAuthorityMapper();

}