Module net.shibboleth.ext.spring
Class EvaluableScriptFactoryBean
- java.lang.Object
-
- org.springframework.beans.factory.config.AbstractFactoryBean<T>
-
- net.shibboleth.ext.spring.factory.AbstractComponentAwareFactoryBean<EvaluableScript>
-
- net.shibboleth.ext.spring.factory.EvaluableScriptFactoryBean
-
- All Implemented Interfaces:
Aware,BeanClassLoaderAware,BeanFactoryAware,DisposableBean,FactoryBean<EvaluableScript>,InitializingBean
public class EvaluableScriptFactoryBean extends AbstractComponentAwareFactoryBean<EvaluableScript>
A factory bean to summon up anEvaluableScriptfrom either inline data or from a resource.
-
-
Field Summary
Fields Modifier and Type Field Description private StringengineNameThe JSR223 engine name.private org.slf4j.Loggerloglog.private ResourceresourceThe resource which locates the script.private StringscriptThe script.private StringsourceIdThe source Id.-
Fields inherited from class org.springframework.beans.factory.config.AbstractFactoryBean
logger
-
Fields inherited from interface org.springframework.beans.factory.FactoryBean
OBJECT_TYPE_ATTRIBUTE
-
-
Constructor Summary
Constructors Constructor Description EvaluableScriptFactoryBean()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected EvaluableScriptdoCreateInstance()Call the parent class to create the instance.StringgetEngineName()Get the engine Name.Class<?>getObjectType()ResourcegetResource()Get the resource which locates the script.StringgetScript()Get the script.StringgetSourceId()Get the source ID.voidsetEngineName(String what)Set the engine name.voidsetResource(Resource what)Set the resource which locates the script.voidsetScript(String what)Set the script.voidsetSourceId(String what)Set the source Id.-
Methods inherited from class net.shibboleth.ext.spring.factory.AbstractComponentAwareFactoryBean
createInstance, destroyInstance
-
Methods inherited from class org.springframework.beans.factory.config.AbstractFactoryBean
afterPropertiesSet, destroy, getBeanFactory, getBeanTypeConverter, getEarlySingletonInterfaces, getObject, isSingleton, setBeanClassLoader, setBeanFactory, setSingleton
-
-
-
-
Method Detail
-
getResource
public Resource getResource()
Get the resource which locates the script.- Returns:
- Returns the resource.
-
setResource
public void setResource(Resource what)
Set the resource which locates the script.- Parameters:
what- the resource to set.
-
getScript
public String getScript()
Get the script.- Returns:
- Returns the script as text.
-
setScript
public void setScript(String what)
Set the script.- Parameters:
what- the script to set.
-
getSourceId
public String getSourceId()
Get the source ID.- Returns:
- Returns the sourceID.
-
setSourceId
public void setSourceId(String what)
Set the source Id.- Parameters:
what- the Id to set.
-
getEngineName
public String getEngineName()
Get the engine Name.- Returns:
- Returns the engine name.
-
setEngineName
public void setEngineName(String what)
Set the engine name.- Parameters:
what- the engine name to set.
-
getObjectType
public Class<?> getObjectType()
- Specified by:
getObjectTypein interfaceFactoryBean<EvaluableScript>- Specified by:
getObjectTypein classAbstractFactoryBean<EvaluableScript>
-
doCreateInstance
protected EvaluableScript doCreateInstance() throws Exception
Call the parent class to create the instance.- Specified by:
doCreateInstancein classAbstractComponentAwareFactoryBean<EvaluableScript>- Returns:
- the bean.
- Throws:
Exception- if needed.
-
-