Class CmdScriptExecutor

java.lang.Object
de.hybris.platform.scripting.engine.impl.CmdScriptExecutor

public class CmdScriptExecutor extends Object
This class is intended to be an executor of scripts from command line and is used by ant target "executeScript".
  • Constructor Details

    • CmdScriptExecutor

      public CmdScriptExecutor()
  • Method Details

    • execute

      public void execute(String scriptURI)
      Executes script by its URI. The scriptURI may be used with protocol:
       http://server.com/script.groovy
       ftp://server.com/script.groovy
       file:///Users/zeus/script.groovy
       model://myScript
       

      or without protocol, and then it is considered as a local file system file:

       script.groovy
       ./script.groovy
       /Users/zeus/script.groovy
       C:/Users/zeus/script.groovy
       
      Parameters:
      scriptURI - proper URI for Script
    • execute

      public void execute(String scriptURI, String paramsAsKeyValue)
      Executes script by its URI. Additionally params may be passed to the script as comma separated key=value pairs in a form "key1=value1,key2=value2". The scriptURI may be used with protocol:
       http://server.com/script.groovy
       ftp://server.com/script.groovy
       file:///Users/zeus/script.groovy
       model://myScript
       

      or without protocol, and then it is considered as a local file system file:

       script.groovy
       ./script.groovy
       /Users/zeus/script.groovy
       C:/Users/zeus/script.groovy
       
      Parameters:
      scriptURI - proper URI for Script
      paramsAsKeyValue - comma separated key=value pairs
    • setService

      public void setService(ScriptingLanguagesService service)