##### Coverage Report - org.apache.turbine.modules.ScheduledJob

Classes in this File | Line Coverage | Branch Coverage | Complexity
ScheduledJob |
0% | 0/2
N/A | N/A
| 1.0;1

1 |  |
     package org.apache.turbine.modules;
2 |  |
3 |  |
4 |  |
     /*
5 |  |
      * Licensed to the Apache Software Foundation (ASF) under one
6 |  |
      * or more contributor license agreements.  See the NOTICE file
7 |  |
      * distributed with this work for additional information
8 |  |
      * regarding copyright ownership.  The ASF licenses this file
9 |  |
      * to you under the Apache License, Version 2.0 (the
10 |  |
      * "License"); you may not use this file except in compliance
11 |  |
      * with the License.  You may obtain a copy of the License at
12 |  |
      *
13 |  |
      *   http://www.apache.org/licenses/LICENSE-2.0
14 |  |
      *
15 |  |
      * Unless required by applicable law or agreed to in writing,
16 |  |
      * software distributed under the License is distributed on an
17 |  |
      * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
18 |  |
      * KIND, either express or implied.  See the License for the
19 |  |
      * specific language governing permissions and limitations
20 |  |
      * under the License.
21 |  |
      */
22 |  |
23 |  |
24 |  |
     // Turbine Scheduler Classes
25 |  |
26 |  |
     import org.apache.turbine.services.schedule.JobEntry;
27 |  |
28 |  |
     /**
29 |  |
      * All Scheduled jobs should extend this.  The class that extends
30 |  |
      * ScheduledJobs should contain the code that you actually want to
31 |  |
      * execute at a specific time.  The name of this class is what you
32 |  |
      * register in the JobEntry.
33 |  |
      *
34 |  |
      * @author <a href="mailto:mbryson@mindspring.com">Dave Bryson</a>
35 |  |
      * @version $Id: ScheduledJob.java 717934 2008-11-15 21:48:47Z tv $
36 |  |
      */
37 | 0 |
     public abstract class ScheduledJob extends Assembler
38 |  |
     {
39 |  |
         /** Prefix for scheduler job related classes */
40 |  |
         public static final String PREFIX = "scheduledjobs";
41 |  |
42 |  |
         /** The key for the schedulder job cache size if module caching is on. */
43 |  |
         public static final String CACHE_SIZE_KEY = "scheduledjob.cache.size";
44 |  |
45 |  |
         /** The default size of the schedulder job cache if module caching is on. */
46 |  |
         public static final int CACHE_SIZE_DEFAULT = 10;
47 |  |
48 |  |
         /** Represents Scheduled Job Objects */
49 |  |
         public static final String NAME = "scheduledjob";
50 |  |
51 |  |
         /**
52 |  |
          * @see org.apache.turbine.modules.Assembler#getPrefix()
53 |  |
          */
54 |  |
         public String getPrefix()
55 |  |
         {
56 | 0 |
             return PREFIX;
57 |  |
         }
58 |  |
59 |  |
         /**
60 |  |
          * Run the Jobentry from the scheduler queue.
61 |  |
          *
62 |  |
          * @param job The job to run.
63 |  |
          */
64 |  |
         public abstract void run(JobEntry job)
65 |  |
                 throws Exception;
66 |  |
     }