@InterfaceAudience.Public public class NamespacePermission extends Permission
Permission.Action, Permission.Builder, Permission.Scope| Modifier and Type | Field and Description |
|---|---|
private String |
namespace |
ACTION_BY_CODE, actions, scope, SCOPE_BY_CODE, VERSION| Constructor and Description |
|---|
NamespacePermission(String namespace,
Permission.Action... assigned)
Construct a namespace permission.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
boolean |
equalsExceptActions(Object obj)
Check if two permission equals regardless of actions.
|
String |
getNamespace() |
int |
hashCode() |
boolean |
implies(String namespace,
Permission.Action action)
check if given action is granted in given namespace.
|
protected String |
rawExpression() |
void |
readFields(DataInput in) |
String |
toString() |
void |
write(DataOutput out) |
getAccessScope, getActions, getVersion, implies, newBuilder, newBuilder, newBuilder, setActionsNamespacePermission(String namespace, Permission.Action... assigned)
namespace - namespace's nameassigned - assigned actionspublic String getNamespace()
public boolean implies(String namespace, Permission.Action action)
namespace - namespace's nameaction - action to be checkedpublic boolean equalsExceptActions(Object obj)
PermissionequalsExceptActions in class Permissionobj - instancepublic int hashCode()
hashCode in class Permissionpublic boolean equals(Object obj)
equals in class Permissionpublic String toString()
toString in class Permissionprotected String rawExpression()
rawExpression in class Permissionpublic void readFields(DataInput in) throws IOException
readFields in interface org.apache.hadoop.io.WritablereadFields in class PermissionIOExceptionpublic void write(DataOutput out) throws IOException
write in interface org.apache.hadoop.io.Writablewrite in class PermissionIOExceptionCopyright © 2007–2020 The Apache Software Foundation. All rights reserved.