class WhitelistContract {

    void verify(Set<Permission> operations, IResource suppliedResource)
    {
        if (!suppliedResource.applicablePermissions().containsAll(operations))
        {
            throw new InvalidRequestException(String.format("Operation(s) %s are not applicable on %s", operations, suppliedResource));
        }
    }

}