public class MemberPermission extends Object
| Modifier and Type | Field and Description | 
|---|---|
| protected MemberAction | action | 
| protected boolean | allow | 
| protected PermissionDeniedReason | reason | 
| Constructor and Description | 
|---|
| MemberPermission(MemberAction action,
                boolean allow)Whether the user is allowed to take the action on the associated member. | 
| MemberPermission(MemberAction action,
                boolean allow,
                PermissionDeniedReason reason)Whether the user is allowed to take the action on the associated member. | 
| Modifier and Type | Method and Description | 
|---|---|
| boolean | equals(Object obj) | 
| MemberAction | getAction()The action that the user may wish to take on the member. | 
| boolean | getAllow()True if the user is allowed to take the action. | 
| PermissionDeniedReason | getReason()The reason why the user is denied the permission. | 
| int | hashCode() | 
| String | toString() | 
| String | toStringMultiline()Returns a String representation of this object formatted for easier
 readability. | 
protected final MemberAction action
protected final boolean allow
protected final PermissionDeniedReason reason
public MemberPermission(MemberAction action, boolean allow, PermissionDeniedReason reason)
action - The action that the user may wish to take on the member.
     Must not be null.allow - True if the user is allowed to take the action.reason - The reason why the user is denied the permission. Not
     present if the action is allowed.IllegalArgumentException - If any argument does not meet its
     preconditions.public MemberPermission(MemberAction action, boolean allow)
The default values for unset fields will be used.
action - The action that the user may wish to take on the member.
     Must not be null.allow - True if the user is allowed to take the action.IllegalArgumentException - If any argument does not meet its
     preconditions.public MemberAction getAction()
null.public boolean getAllow()
public PermissionDeniedReason getReason()
null if not present.public String toStringMultiline()
The returned String may contain newlines.