我想知道如何在Quartz中外部传递一个实例变量?下面是我想写的伪代码。如何将externalInstance传递给此Job?publicclassSimpleJobimplementsJob{@Overridepublicvoidexecute(JobExecutionContextcontext)throwsJobExecutionException{floatavg=externalInstance.calculateAvg();}} 最佳答案 您可以将您的实例放在schedulerContext中。当您要安排作业时,您可以在
我想知道如何在Quartz中外部传递一个实例变量?下面是我想写的伪代码。如何将externalInstance传递给此Job?publicclassSimpleJobimplementsJob{@Overridepublicvoidexecute(JobExecutionContextcontext)throwsJobExecutionException{floatavg=externalInstance.calculateAvg();}} 最佳答案 您可以将您的实例放在schedulerContext中。当您要安排作业时,您可以在