public class ConfigAttributeDefinition
extends java.lang.Object
implements java.io.Serializable
ConfigAttribute
s that are associated with a given secure object target - effectively a
CollectionOnce created, the object is immutable.
All the ConfigAttributeDefinition
s associated with a given AbstractSecurityInterceptor
are stored in an ObjectDefinitionSource
.
Modifier and Type | Field and Description |
---|---|
static ConfigAttributeDefinition |
NO_ATTRIBUTES |
Constructor and Description |
---|
ConfigAttributeDefinition(ConfigAttribute attribute)
Creates a ConfigAttributeDefinition containing a single attribute.
|
ConfigAttributeDefinition(java.util.List configAttributes)
Creates an immutable ConfigAttributeDefinition from the supplied list of ConfigAttribute objects.
|
ConfigAttributeDefinition(java.lang.String attribute)
Creates a ConfigAttributeDefinition containing a single attribute
|
ConfigAttributeDefinition(java.lang.String[] attributeTokens)
Builds a collection of ConfigAttributes from an array of String tokens, each of which will be wrapped in a
SecurityConfig instance.
|
Modifier and Type | Method and Description |
---|---|
boolean |
contains(ConfigAttribute configAttribute)
Indicates whether the specified
ConfigAttribute is contained within this
ConfigAttributeDefinition . |
static ConfigAttributeDefinition |
createFiltered(java.util.Collection unfilteredInput)
Creates a ConfigAttributeDefinition by including only those attributes which implement ConfigAttribute.
|
boolean |
equals(java.lang.Object obj) |
java.util.Collection |
getConfigAttributes()
Returns the internal collection of
ConfigAttribute s defined by this
ConfigAttributeDefinition . |
java.lang.String |
toString() |
public static final ConfigAttributeDefinition NO_ATTRIBUTES
public ConfigAttributeDefinition(java.lang.String attribute)
attribute
- the String name of the attribute (converted internally to a SecurityConfig instance).public ConfigAttributeDefinition(ConfigAttribute attribute)
public ConfigAttributeDefinition(java.lang.String[] attributeTokens)
attributeTokens
- the tokens which will be turned into attributes.public ConfigAttributeDefinition(java.util.List configAttributes)
public static ConfigAttributeDefinition createFiltered(java.util.Collection unfilteredInput)
unfilteredInput
- a collection of various elements, zero or more which implement ConfigAttribute (can also be null)public boolean contains(ConfigAttribute configAttribute)
ConfigAttribute
is contained within this
ConfigAttributeDefinition
.configAttribute
- the attribute to locatetrue
if the specified ConfigAttribute
is contained, false
otherwisepublic boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public java.util.Collection getConfigAttributes()
ConfigAttribute
s defined by this
ConfigAttributeDefinition
.
Allows AccessDecisionManager
s and other classes to loop through every configuration attribute
associated with a target secure object.
public java.lang.String toString()
toString
in class java.lang.Object