代码添加批处理类

 1 static void Job_ScheduleBatch2(Args _args)
 2 {
 3     BatchHeader batHeader;
 4     BatchInfo batInfo;
 5     RunBaseBatch rbbTask;
 6     str sParmCaption = "My RunbaseBatch Report Run";
 7     ;
 8     rbbTask = new AV_RunbaseBatchDemo();
 9     batInfo = rbbTask .batchInfo();
10     batInfo .parmCaption(sParmCaption);
11     batInfo .parmGroupId("Daily"); // The "Empty batch group".
12     batHeader = BatchHeader ::construct();
13     batHeader .addTask(rbbTask);
14     batHeader .save();
15     info(strFmt("'%1' batch has been scheduled.", sParmCaption));
16 }
17 //批处理类客户端运行
18 public boolean runsImpersonated() { return false; }//重写
原文地址:https://www.cnblogs.com/Jinnchu/p/2663924.html