@RequestScoped public class DefaultAccessDecisionVoterStateContext extends Object implements org.apache.myfaces.extensions.cdi.core.impl.security.spi.EditableAccessDecisionVoterContext
Constructor and Description |
---|
DefaultAccessDecisionVoterStateContext() |
Modifier and Type | Method and Description |
---|---|
void |
addMetaData(String key,
Object metaData)
Allows to add custom meta-data.
|
void |
addViolation(SecurityViolation securityViolation)
Adds a new
SecurityViolation to the context |
Map<String,Object> |
getMetaData()
Exposes the found meta-data
|
<T> T |
getMetaDataFor(String key,
Class<T> targetType)
Exposes meta-data for the given key
|
AccessDecisionState |
getState()
Exposes the current state
|
List<SecurityViolation> |
getViolations()
Exposes the found violations
|
void |
setState(AccessDecisionState accessDecisionVoterState)
Updates the state of the context
|
public DefaultAccessDecisionVoterStateContext()
public AccessDecisionState getState()
getState
in interface AccessDecisionVoterContext
public List<SecurityViolation> getViolations()
getViolations
in interface AccessDecisionVoterContext
public Map<String,Object> getMetaData()
getMetaData
in interface AccessDecisionVoterContext
public <T> T getMetaDataFor(String key, Class<T> targetType)
getMetaDataFor
in interface AccessDecisionVoterContext
T
- target typekey
- meta-data keytargetType
- target typepublic void addMetaData(String key, Object metaData)
org.apache.myfaces.extensions.cdi.core.impl.security.spi.EditableAccessDecisionVoterContext
addMetaData
in interface org.apache.myfaces.extensions.cdi.core.impl.security.spi.EditableAccessDecisionVoterContext
key
- key for the meta-datametaData
- meta-data which should be addedpublic void setState(AccessDecisionState accessDecisionVoterState)
setState
in interface org.apache.myfaces.extensions.cdi.core.impl.security.spi.EditableAccessDecisionVoterContext
accessDecisionVoterState
- current statepublic void addViolation(SecurityViolation securityViolation)
SecurityViolation
to the contextaddViolation
in interface org.apache.myfaces.extensions.cdi.core.impl.security.spi.EditableAccessDecisionVoterContext
securityViolation
- security-violation which should be addedCopyright © 2010-2014 The Apache Software Foundation. All Rights Reserved.