Class CmdScriptExecutor


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

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void execute​(java.lang.String scriptURI)
      Executes script by its URI.
      void execute​(java.lang.String scriptURI, java.lang.String paramsAsKeyValue)
      Executes script by its URI.
      void setService​(ScriptingLanguagesService service)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • CmdScriptExecutor

        public CmdScriptExecutor()
    • Method Detail

      • execute

        public void execute​(java.lang.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​(java.lang.String scriptURI,
                            java.lang.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