View Javadoc

1   /*
2    * $Id: EventGeneratorJobConfig.java 20321 2010-11-24 15:21:24Z dfeist $
3    * --------------------------------------------------------------------------------------
4    * Copyright (c) MuleSoft, Inc.  All rights reserved.  http://www.mulesoft.com
5    *
6    * The software in this package is published under the terms of the CPAL v1.0
7    * license, a copy of which has been included with this distribution in the
8    * LICENSE.txt file.
9    */
10  package org.mule.transport.quartz.jobs;
11  
12  import org.mule.transport.NullPayload;
13  import org.mule.transport.quartz.config.AbstractJobConfig;
14  
15  import org.quartz.Job;
16  import org.quartz.StatefulJob;
17  
18  
19  /**
20   * The configuration for the {@link EventGeneratorJob} job.
21   */
22  public class EventGeneratorJobConfig extends AbstractJobConfig
23  {
24      private Object payload = NullPayload.getInstance();
25  
26      public Object getPayload()
27      {
28          return payload;
29      }
30  
31      public void setPayload(Object payload)
32      {
33          this.payload = payload;
34      }
35  
36      @Override
37      protected Class<? extends StatefulJob> getStatefulJobClass()
38      {
39          return StatefulEventGeneratorJob.class;
40      }
41  
42      @Override
43      protected Class<? extends Job> getStatelessJobClass()
44      {
45          return EventGeneratorJob.class;
46      }
47  }