Class MethodSecurityBean<R>

  • All Implemented Interfaces:
    org.springframework.beans.factory.InitializingBean

    public class MethodSecurityBean<R>
    extends java.lang.Object
    implements org.springframework.beans.factory.InitializingBean
    Support to simulate interceptor-driven permissions.
    Since:
    4.0
    Author:
    janv, Derek Hulley
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void afterPropertiesSet()  
      java.util.Collection<R> applyPermissions​(java.util.Collection<R> toCheck, net.sf.acegisecurity.Authentication authentication, int targetResultCount)  
      java.util.Collection<R> applyPermissions​(java.util.Collection<R> toCheck, net.sf.acegisecurity.Authentication authentication, int targetResultCount, long cutOffAfterTimeMs, int cutOffAfterCount)  
      void setMethodName​(java.lang.String methodName)  
      void setMethodSecurityInterceptor​(org.aopalliance.intercept.MethodInterceptor methodInterceptor)  
      void setService​(java.lang.Class<?> service)  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • MethodSecurityBean

        public MethodSecurityBean()
        Default constructor. Use setter methods for initialization.
      • MethodSecurityBean

        public MethodSecurityBean​(MethodSecurityInterceptor methodSecurityInterceptor,
                                  java.lang.Class<?> service,
                                  java.lang.String methodName)
        Helper constructor to supply necessary values
    • Method Detail

      • setMethodSecurityInterceptor

        public void setMethodSecurityInterceptor​(org.aopalliance.intercept.MethodInterceptor methodInterceptor)
        Parameters:
        methodInterceptor - an method interceptor, ideally a MethodSecurityInterceptor
      • setService

        public void setService​(java.lang.Class<?> service)
      • setMethodName

        public void setMethodName​(java.lang.String methodName)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • afterPropertiesSet

        public void afterPropertiesSet()
                                throws java.lang.Exception
        Specified by:
        afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
        Throws:
        java.lang.Exception