コード例 #1
0
  public void work() {

    /*
     *  Tell the worker how to perform the functions
     */
    worker.addFunction(JenkinsWorker.ECHO_FUNCTION_NAME, new EchoWorker());
    worker.addFunction(JenkinsWorker.REVERSE_FUNCTION_NAME, new StringReverseWorker());
    worker.addFunction(JenkinsWorker.JENKINS_INVOKE_JOB_FUNCTION_NAME, new JenkinsInvokeJob());
    worker.addFunction(JenkinsWorker.JENKINS_JOB_STATUS_FUNCTION_NAME, new JenkinsJobStatus());

    /*
     *  Tell the worker that it may communicate with the this job server
     */
    worker.addServer(server);
  }
コード例 #2
0
  public void stop() {

    worker.shutdown();
  }