コード例 #1
0
 public TBXScript[] getExecuteScriptDescriptorSync(File servicePath, String operationName)
     throws IOException, SAXException {
   TBXScript[] scripts = new TBXScript[2];
   scripts[0] = new TBXScript();
   scripts[0].setScriptDoc(
       domUtil.inputStreamToDocument(
           new FileInputStream(
               new File(
                   servicePath,
                   EXECUTE_TOOLBOX_SCRIPT_FOLDER_PATH + EXECUTE_SHELL_ENGINE_SCRIPT_FILE_NAME))));
   scripts[0].setPath(PATH_OPERATION + "/" + operationName + "/" + FIRST_SCRIPT_FILE_NAME);
   scripts[0].setType(Script.SCRIPT_TYPE_FIRST_SCRIPT);
   scripts[1] = new TBXScript();
   scripts[1].setScriptDoc(
       domUtil.inputStreamToDocument(
           new FileInputStream(
               new File(
                   servicePath,
                   EXECUTE_TOOLBOX_SCRIPT_FOLDER_PATH + EXECUTE_SHELL_ERROR_SCRIPT_FILE_NAME))));
   scripts[1].setPath(PATH_OPERATION + "/" + operationName + "/" + GLOBAL_ERROR_SCRIPT_FILE_NAME);
   scripts[1].setType(Script.SCRIPT_TYPE_GLOBAL_ERROR);
   return scripts;
 }
コード例 #2
0
 public TBXScript[] getExecuteScriptDescriptorAsync(File servicePath, String operationName)
     throws IOException, SAXException {
   TBXScript[] scripts = new TBXScript[6];
   scripts[0] = new TBXScript();
   scripts[0].setScriptDoc(
       domUtil.inputStreamToDocument(
           new FileInputStream(
               new File(
                   servicePath,
                   EXECUTE_ASYNC_SHELL_ENGINE_SCRIPT_FOLDER_PATH + FIRST_SCRIPT_FILE_NAME))));
   scripts[0].setPath(PATH_OPERATION + "/" + operationName + "/" + FIRST_SCRIPT_FILE_NAME);
   scripts[0].setType(Script.SCRIPT_TYPE_FIRST_SCRIPT);
   scripts[1] = new TBXScript();
   scripts[1].setScriptDoc(
       domUtil.inputStreamToDocument(
           new FileInputStream(
               new File(
                   servicePath,
                   EXECUTE_ASYNC_SHELL_ENGINE_SCRIPT_FOLDER_PATH + SECOND_SCRIPT_FILE_NAME))));
   scripts[1].setPath(PATH_OPERATION + "/" + operationName + "/" + SECOND_SCRIPT_FILE_NAME);
   scripts[1].setType(Script.SCRIPT_TYPE_SECOND_SCRIPT);
   scripts[2] = new TBXScript();
   scripts[2].setScriptDoc(
       domUtil.inputStreamToDocument(
           new FileInputStream(
               new File(
                   servicePath,
                   EXECUTE_ASYNC_SHELL_ENGINE_SCRIPT_FOLDER_PATH + THIRD_SCRIPT_FILE_NAME))));
   scripts[2].setPath(PATH_OPERATION + "/" + operationName + "/" + THIRD_SCRIPT_FILE_NAME);
   scripts[2].setType(Script.SCRIPT_TYPE_THIRD_SCRIPT);
   scripts[3] = new TBXScript();
   scripts[3].setScriptDoc(
       domUtil.inputStreamToDocument(
           new FileInputStream(
               new File(
                   servicePath,
                   EXECUTE_ASYNC_SHELL_ENGINE_SCRIPT_FOLDER_PATH
                       + RESPONSE_BUILDER_SCRIPT_FILE_NAME))));
   scripts[3].setPath(
       PATH_OPERATION + "/" + operationName + "/" + RESPONSE_BUILDER_SCRIPT_FILE_NAME);
   scripts[3].setType(Script.SCRIPT_TYPE_RESPONSE_BUILDER);
   scripts[4] = new TBXScript();
   scripts[4].setScriptDoc(
       domUtil.inputStreamToDocument(
           new FileInputStream(
               new File(
                   servicePath,
                   EXECUTE_ASYNC_SHELL_ENGINE_SCRIPT_FOLDER_PATH
                       + RESPONSE_BUILDER_ERROR_SCRIPT_FILE_NAME))));
   scripts[4].setPath(
       PATH_OPERATION + "/" + operationName + "/" + RESPONSE_BUILDER_ERROR_SCRIPT_FILE_NAME);
   scripts[4].setType(Script.SCRIPT_TYPE_ERROR_ON_RESP_BUILDER);
   scripts[5] = new TBXScript();
   scripts[5].setScriptDoc(
       domUtil.inputStreamToDocument(
           new FileInputStream(
               new File(
                   servicePath,
                   EXECUTE_ASYNC_SHELL_ENGINE_SCRIPT_FOLDER_PATH
                       + GLOBAL_ERROR_SCRIPT_FILE_NAME))));
   scripts[5].setPath(PATH_OPERATION + "/" + operationName + "/" + GLOBAL_ERROR_SCRIPT_FILE_NAME);
   scripts[5].setType(Script.SCRIPT_TYPE_GLOBAL_ERROR);
   return scripts;
 }