class PrivilegeStatement extends Statement
    permits GrantPrivilege, RevokePrivilege, DenyPrivilege {

    protected final List<String> userNames;
    protected final List<String> permissions;
    private final List<QualifiedName> tableOrSchemaNames;
    private final String securable;
    protected final boolean all;

    protected PrivilegeStatement(List<String> userNames, String securable, List<QualifiedName> tableOrSchemaNames) {
        this.userNames = userNames;
        permissions = Collections.emptyList();
        all = true;
        this.securable = securable;
        this.tableOrSchemaNames = tableOrSchemaNames;
    }

    protected PrivilegeStatement(List<String> userNames, List<String> permissions, String securable, List<QualifiedName> tableOrSchemaNames) {
        this.userNames = userNames;
        this.permissions = permissions;
        this.all = false;
        this.securable = securable;
        this.tableOrSchemaNames = tableOrSchemaNames;
    }

    public List<String> privileges() {
        return permissions;
    }

    public List<String> userNames() {
        return userNames;
    }

    public boolean all() {
        return all;
    }

    public List<QualifiedName> privilegeIdents() {
        return tableOrSchemaNames;
    }

    public String securable() {
        return securable;
    }

    @Override
    public boolean equals(Object o) {<FILL_FUNCTION_BODY>}

    @Override
    public int hashCode() {
        return Objects.hash(userNames, permissions, all);
    }

}

        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        PrivilegeStatement that = (PrivilegeStatement) o;
        return all == that.all &&
               Objects.equals(userNames, that.userNames) &&
               Objects.equals(permissions, that.permissions);
    
<methods>public non-sealed void <init>() ,public R accept(AstVisitor<R,C>, C) <variables>