Class SpringContextHelper
java.lang.Object
at.porscheinformatik.tapestry.csrfprotection.internal.SpringContextHelper
Util class for getting Spring beans.
-
Method Summary
Modifier and TypeMethodDescriptionstatic ObjectgetSpringBean(org.apache.tapestry5.commons.ObjectLocator objectLocator, String type) Looks up Spring'sApplicationContextand gets bean.
-
Method Details
-
getSpringBean
public static Object getSpringBean(org.apache.tapestry5.commons.ObjectLocator objectLocator, String type) Looks up Spring'sApplicationContextand gets bean. Is safe even if Spring, Tapestry Spring integration or the bean is not on classpath.- Parameters:
objectLocator- theObjectLocatortype- the desired bean type- Returns:
- the Spring bean or null if no Spring on classpath, or no Spring Tapestry integration or bean class not on classpath
-