Class ScriptEngineFactory

java.lang.Object
org.springframework.beans.factory.config.AbstractFactoryBean<groovy.util.GroovyScriptEngine>
org.craftercms.deployer.utils.scripting.ScriptEngineFactory
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanClassLoaderAware, org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.FactoryBean<groovy.util.GroovyScriptEngine>, org.springframework.beans.factory.InitializingBean

public class ScriptEngineFactory extends org.springframework.beans.factory.config.AbstractFactoryBean<groovy.util.GroovyScriptEngine>
Implementation of FactoryBean for GroovyScriptEngine
Since:
3.1.12
Author:
joseross
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected boolean
    Indicates if the sandbox should be enabled
    protected String[]
    List of relative paths to load scripts

    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
    ScriptEngineFactory(String[] urls, boolean sandboxEnabled)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected groovy.util.GroovyScriptEngine
     
     

    Methods inherited from class org.springframework.beans.factory.config.AbstractFactoryBean

    afterPropertiesSet, destroy, destroyInstance, getBeanFactory, getBeanTypeConverter, getEarlySingletonInterfaces, getObject, isSingleton, setBeanClassLoader, setBeanFactory, setSingleton

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • urls

      protected String[] urls
      List of relative paths to load scripts
    • sandboxEnabled

      protected boolean sandboxEnabled
      Indicates if the sandbox should be enabled
  • Constructor Details

    • ScriptEngineFactory

      @ConstructorProperties({"urls","sandboxEnabled"}) public ScriptEngineFactory(String[] urls, boolean sandboxEnabled)
  • Method Details

    • getObjectType

      public Class<?> getObjectType()
      Specified by:
      getObjectType in interface org.springframework.beans.factory.FactoryBean<groovy.util.GroovyScriptEngine>
      Specified by:
      getObjectType in class org.springframework.beans.factory.config.AbstractFactoryBean<groovy.util.GroovyScriptEngine>
    • createInstance

      protected groovy.util.GroovyScriptEngine createInstance() throws Exception
      Specified by:
      createInstance in class org.springframework.beans.factory.config.AbstractFactoryBean<groovy.util.GroovyScriptEngine>
      Throws:
      Exception