|
|||||||||
| 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 java.util.Map |
methodMap
Map from RegisteredMethod to ConfigAttributeDefinition |
| Constructor Summary | |
|---|---|
MapBasedMethodDefinitionSource()
|
|
MapBasedMethodDefinitionSource(java.util.Map methodMap)
Creates the MapBasedMethodDefinitionSource from a |
|
| Method Summary | |
|---|---|
void |
addSecureMethod(java.lang.Class javaType,
java.lang.reflect.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(java.lang.Class javaType,
java.lang.String mappedName,
ConfigAttributeDefinition attr)
Add configuration attributes for a secure method. |
void |
addSecureMethod(java.lang.String name,
ConfigAttributeDefinition attr)
Add configuration attributes for a secure method. |
protected ConfigAttributeDefinition |
findAttributes(java.lang.Class clazz)
Implementation does not support class-level attributes. |
protected ConfigAttributeDefinition |
findAttributes(java.lang.reflect.Method method,
java.lang.Class targetClass)
Will walk the method inheritance tree to find the most specific declaration applicable. |
java.util.Collection |
getConfigAttributeDefinitions()
Obtains the configuration attributes explicitly defined against this bean. |
int |
getMethodMapSize()
|
void |
setBeanClassLoader(java.lang.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 java.util.Map methodMap
| Constructor Detail |
|---|
public MapBasedMethodDefinitionSource()
public MapBasedMethodDefinitionSource(java.util.Map methodMap)
methodMap - map of method names to ConfigAttributeDefinitions.| Method Detail |
|---|
protected ConfigAttributeDefinition findAttributes(java.lang.Class clazz)
findAttributes in class AbstractFallbackMethodDefinitionSourceclazz - the target class for the invocation (never null)
protected ConfigAttributeDefinition findAttributes(java.lang.reflect.Method method,
java.lang.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(java.lang.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(java.lang.Class javaType,
java.lang.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(java.lang.Class javaType,
java.lang.reflect.Method method,
ConfigAttributeDefinition attr)
public java.util.Collection getConfigAttributeDefinitions()
getConfigAttributeDefinitions in interface ObjectDefinitionSourcepublic void setBeanClassLoader(java.lang.ClassLoader beanClassLoader)
setBeanClassLoader in interface org.springframework.beans.factory.BeanClassLoaderAwarepublic int getMethodMapSize()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||