类 SchedulerConfiguration

  • 所有已实现的接口:
    org.springframework.beans.factory.Aware, org.springframework.context.ApplicationContextAware, org.springframework.context.EmbeddedValueResolverAware

    @Profile("scheduler")
    @Configuration("schedulerConfiguration")
    public class SchedulerConfiguration
    extends java.lang.Object
    implements org.springframework.context.ApplicationContextAware, org.springframework.context.EmbeddedValueResolverAware
    • 方法概要

      所有方法 实例方法 具体方法 
      修饰符和类型 方法 说明
      void init()  
      org.quartz.spi.JobFactory jobFactory()
      For auto inject spring bean to MethodInvokingJobDetailFactoryBean.MethodInvokingJob
      org.springframework.scheduling.quartz.SchedulerFactoryBean schedulerFactoryBean()
      Create a SchedulerFactoryBean bean.
      void setApplicationContext​(org.springframework.context.ApplicationContext applicationContext)  
      void setEmbeddedValueResolver​(org.springframework.util.StringValueResolver resolver)  
      • 从类继承的方法 java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • 构造器详细资料

      • SchedulerConfiguration

        public SchedulerConfiguration()
    • 方法详细资料

      • setApplicationContext

        public void setApplicationContext​(org.springframework.context.ApplicationContext applicationContext)
                                   throws org.springframework.beans.BeansException
        指定者:
        setApplicationContext 在接口中 org.springframework.context.ApplicationContextAware
        抛出:
        org.springframework.beans.BeansException
      • setEmbeddedValueResolver

        public void setEmbeddedValueResolver​(org.springframework.util.StringValueResolver resolver)
        指定者:
        setEmbeddedValueResolver 在接口中 org.springframework.context.EmbeddedValueResolverAware
      • init

        @PostConstruct
        public void init()
                  throws java.lang.Exception
        抛出:
        java.lang.Exception
      • schedulerFactoryBean

        @Bean(name="schedulerFactoryBean")
        @DependsOn({"schedulerConfiguration","jobFactory"})
        public org.springframework.scheduling.quartz.SchedulerFactoryBean schedulerFactoryBean()
        Create a SchedulerFactoryBean bean.

        Must make sure this bean init after init() method. Otherwise no task will be scheduled.

        返回:
        the schedulerFactory bean
      • jobFactory

        @Bean(name="jobFactory")
        public org.quartz.spi.JobFactory jobFactory()
        For auto inject spring bean to MethodInvokingJobDetailFactoryBean.MethodInvokingJob
        返回:
        the jobFactory bean