Class DefaultScriptExecutor

java.lang.Object
org.springframework.integration.scripting.jsr223.AbstractScriptExecutor
org.springframework.integration.scripting.jsr223.DefaultScriptExecutor
All Implemented Interfaces:
ScriptExecutor
Direct Known Subclasses:
RubyScriptExecutor

public class DefaultScriptExecutor
extends AbstractScriptExecutor
Default implementation of the AbstractScriptExecutor. Accepts a scripting language for resolving a target ScriptEngine for evaluation and does nothing with the result in the postProcess(Object, ScriptEngine, String, Bindings) implementation.
Since:
2.1
  • Field Summary

    Fields inherited from class org.springframework.integration.scripting.jsr223.AbstractScriptExecutor

    logger
  • Constructor Summary

    Constructors 
    Constructor Description
    DefaultScriptExecutor​(java.lang.String language)
    Create a DefaultScriptExecutor for the specified language name (JSR233 alias).
  • Method Summary

    Modifier and Type Method Description
    protected java.lang.Object postProcess​(java.lang.Object result, javax.script.ScriptEngine scriptEngine, java.lang.String script, javax.script.Bindings bindings)
    Subclasses may implement this to provide any special handling required

    Methods inherited from class org.springframework.integration.scripting.jsr223.AbstractScriptExecutor

    executeScript, getScriptEngine

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.springframework.integration.scripting.ScriptExecutor

    executeScript
  • Constructor Details

    • DefaultScriptExecutor

      public DefaultScriptExecutor​(java.lang.String language)
      Create a DefaultScriptExecutor for the specified language name (JSR233 alias).
      Parameters:
      language - the scripting language identificator.
  • Method Details

    • postProcess

      protected java.lang.Object postProcess​(java.lang.Object result, javax.script.ScriptEngine scriptEngine, java.lang.String script, javax.script.Bindings bindings)
      Description copied from class: AbstractScriptExecutor
      Subclasses may implement this to provide any special handling required
      Specified by:
      postProcess in class AbstractScriptExecutor
      Parameters:
      result - the result.
      scriptEngine - the engine.
      script - the script.
      bindings - the bindings.
      Returns:
      modified result