public class AuthorizationDecision extends Ind2uceEntity
| Modifier and Type | Field and Description |
|---|---|
static AuthorizationDecision |
DECISION_ALLOW
The default decision for a plain allow.
|
static AuthorizationDecision |
DECISION_INHIBIT
The default decision for a plain inhibit.
|
GSON_DEFAULT, GSON_PLAIN, GSON_PRETTY, version| Constructor and Description |
|---|
AuthorizationDecision()
Instantiates a new authorization decision.
|
AuthorizationDecision(AuthorizationDecision prototype)
Constructor that takes the id and eventAllowed from Prototype.
|
AuthorizationDecision(DecisionId id,
boolean eventAllowed,
long delay,
List<String> authorizationActionNames,
Modifier... modifiers)
Instantiates a new authorization decision.
|
AuthorizationDecision(DecisionId id,
boolean eventAllowed,
long delay,
List<String> authorizationActionNames,
ModifierList modifiers)
Instantiates a new authorization decision.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addModifier(Modifier param)
Adds the modifier.
|
void |
clearParameters()
Clear modifiers.
|
boolean |
equals(Object o) |
List<String> |
getAuthorizationActionNames()
Gets the name(s) of the corresponding AutorizationAction(s) that led to the
decision.
|
static AuthorizationDecision |
getDecisionAllow()
Get a clone of DECISION_ALLOW.
|
static AuthorizationDecision |
getDecisionInhibit()
Get a clone of DECISION_INHIBIT.
|
long |
getDelay()
Returns how much the event should be delayed.
|
DecisionId |
getId()
Gets the id.
|
Modifier |
getModifierForName(String name)
Gets the modifier for name.
|
ModifierList |
getModifiers()
Gets the modifiers.
|
int |
hashCode() |
boolean |
isEventAllowed()
Indicates whether an event should be allowed or blocked.
|
void |
removeParameter(String name)
Removes the modifier.
|
void |
setAuthorizationActionNames(List<String> authorizationActionNames)
Sets the authorization action names.
|
void |
setDelay(long delay)
Sets how much the event should be delayed.
|
void |
setEventAllowed(boolean eventAllowed)
Sets whether an event should be allowed or blocked.
|
void |
setId(DecisionId id)
Sets the id.
|
void |
setModifiers(ModifierList modifiers)
Sets modifiers for the event.
|
fromJson, getGson, getVersion, toJson, toStringpublic static final AuthorizationDecision DECISION_ALLOW
public static final AuthorizationDecision DECISION_INHIBIT
public AuthorizationDecision()
public AuthorizationDecision(AuthorizationDecision prototype)
prototype - Prototype to create a new instance.public AuthorizationDecision(DecisionId id, boolean eventAllowed, long delay, List<String> authorizationActionNames, Modifier... modifiers)
id - the ideventAllowed - the event alloweddelay - the delay unitauthorizationActionNames - the authorization action namesmodifiers - the modifierspublic AuthorizationDecision(DecisionId id, boolean eventAllowed, long delay, List<String> authorizationActionNames, ModifierList modifiers)
id - the ideventAllowed - the event alloweddelay - the delay unitauthorizationActionNames - the authorization action namesmodifiers - the modifierspublic static final AuthorizationDecision getDecisionAllow()
public static final AuthorizationDecision getDecisionInhibit()
public void addModifier(Modifier param)
param - the parampublic void clearParameters()
public List<String> getAuthorizationActionNames()
public long getDelay()
public DecisionId getId()
public Modifier getModifierForName(String name)
name - the namepublic ModifierList getModifiers()
Modifier
.public boolean isEventAllowed()
public void removeParameter(String name)
name - the namepublic void setAuthorizationActionNames(List<String> authorizationActionNames)
authorizationActionNames - the names of the authorizationActions that
led to the decision.public void setDelay(long delay)
delay - the delay in microsecondspublic void setEventAllowed(boolean eventAllowed)
eventAllowed - true, if the event should be allowed, false otherwisepublic void setId(DecisionId id)
id - the new idpublic void setModifiers(ModifierList modifiers)
modifiers - the new modifiersCopyright © 2018. All rights reserved.