|
Spring Security Framework | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.springframework.security.intercept.method.AbstractFallbackMethodDefinitionSource
org.springframework.security.intercept.method.MapBasedMethodDefinitionSource
public class MapBasedMethodDefinitionSource
Stores a ConfigAttributeDefinition for a method or class signature.
This class is the preferred implementation of MethodDefinitionSource for XML-based
definition of method security metadata. To assist in XML-based definition, wildcard support
is provided.
| Field Summary | |
|---|---|
protected Map |
methodMap
Map from RegisteredMethod to ConfigAttributeDefinition |
| Constructor Summary | |
|---|---|
MapBasedMethodDefinitionSource()
|
|
MapBasedMethodDefinitionSource(Map methodMap)
Creates the MapBasedMethodDefinitionSource from a |
|
| Method Summary | |
|---|---|
void |
addSecureMethod(Class javaType,
Method method,
ConfigAttributeDefinition attr)
Adds configuration attributes for a specific method, for example where the method has been matched using a pointcut expression. |
void |
addSecureMethod(Class javaType,
String mappedName,
ConfigAttributeDefinition attr)
Add configuration attributes for a secure method. |
void |
addSecureMethod(String name,
ConfigAttributeDefinition attr)
Add configuration attributes for a secure method. |
protected ConfigAttributeDefinition |
findAttributes(Class clazz)
Implementation does not support class-level attributes. |
protected ConfigAttributeDefinition |
findAttributes(Method method,
Class targetClass)
Will walk the method inheritance tree to find the most specific declaration applicable. |
Collection |
getConfigAttributeDefinitions()
Obtains the configuration attributes explicitly defined against this bean. |
int |
getMethodMapSize()
|
void |
setBeanClassLoader(ClassLoader beanClassLoader)
|
| Methods inherited from class org.springframework.security.intercept.method.AbstractFallbackMethodDefinitionSource |
|---|
getAttributes, getAttributes, supports |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected Map methodMap
| Constructor Detail |
|---|
public MapBasedMethodDefinitionSource()
public MapBasedMethodDefinitionSource(Map methodMap)
methodMap - map of method names to ConfigAttributeDefinitions.| Method Detail |
|---|
protected ConfigAttributeDefinition findAttributes(Class clazz)
findAttributes in class AbstractFallbackMethodDefinitionSourceclazz - the target class for the invocation (never null)
protected ConfigAttributeDefinition findAttributes(Method method,
Class targetClass)
findAttributes in class AbstractFallbackMethodDefinitionSourcemethod - the method for the current invocation (never null)targetClass - the target class for the invocation (may be null)
public void addSecureMethod(String name,
ConfigAttributeDefinition attr)
*
for matching multiple methods.
name - type and method name, separated by a dotattr - required authorities associated with the method
public void addSecureMethod(Class javaType,
String mappedName,
ConfigAttributeDefinition attr)
*
for matching multiple methods.
javaType - target interface or class the security configuration attribute applies tomappedName - mapped method name, which the javaType has declared or inheritedattr - required authorities associated with the method
public void addSecureMethod(Class javaType,
Method method,
ConfigAttributeDefinition attr)
public Collection getConfigAttributeDefinitions()
getConfigAttributeDefinitions in interface ObjectDefinitionSourcepublic void setBeanClassLoader(ClassLoader beanClassLoader)
setBeanClassLoader in interface BeanClassLoaderAwarepublic int getMethodMapSize()
|
Spring Security Framework | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||