All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.datahub.authorization.ConjunctivePrivilegeGroup Maven / Gradle / Ivy

Go to download

DataHub Auth API for developers to write custom Authentication & Authorization plugins for DataHub

There is a newer version: 0.14.1-12rc1
Show newest version
package com.datahub.authorization;

import java.util.Collection;

/**
 * Represents a group of privileges that must ALL be required to authorize a request.
 *
 * 

That is, an AND of privileges. */ public class ConjunctivePrivilegeGroup { private final Collection _requiredPrivileges; public ConjunctivePrivilegeGroup(Collection requiredPrivileges) { _requiredPrivileges = requiredPrivileges; } public Collection getRequiredPrivileges() { return _requiredPrivileges; } @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; ConjunctivePrivilegeGroup that = (ConjunctivePrivilegeGroup) o; return _requiredPrivileges.equals(that._requiredPrivileges); } @Override public int hashCode() { return _requiredPrivileges.hashCode(); } @Override public String toString() { return "ConjunctivePrivilegeGroup{" + "_requiredPrivileges=" + _requiredPrivileges + '}'; } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy