1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * This library is free software; you can redistribute it and/or modify it under
5    * the terms of the GNU Lesser General Public License as published by the Free
6    * Software Foundation; either version 2.1 of the License, or (at your option)
7    * any later version.
8    *
9    * This library is distributed in the hope that it will be useful, but WITHOUT
10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11   * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
12   * details.
13   */
14  
15  package com.liferay.portal.job;
16  
17  import java.util.Date;
18  
19  import org.quartz.JobExecutionContext;
20  
21  /**
22   * <a href="JobExecutionContextImpl.java.html"><b><i>View Source</i></b></a>
23   *
24   * @author Brian Wing Shun Chan
25   */
26  public class JobExecutionContextImpl
27      implements com.liferay.portal.kernel.job.JobExecutionContext {
28  
29      public JobExecutionContextImpl(JobExecutionContext context) {
30          _context = context;
31      }
32  
33      public Object get(Object key) {
34          return _context.get(key);
35      }
36  
37      public long getJobRunTime() {
38          return _context.getJobRunTime();
39      }
40  
41      public Date getNextFireTime() {
42          return _context.getNextFireTime();
43      }
44  
45      public Date getPreviousFireTime() {
46          return _context.getPreviousFireTime();
47      }
48  
49      public Object getResult() {
50          return _context.getResult();
51      }
52  
53      public void put(Object key, Object value) {
54          _context.put(key, value);
55      }
56  
57      public void setJobRunTime(long jobRunTime) {
58          _context.setJobRunTime(jobRunTime);
59      }
60  
61      public void setResult(Object result) {
62          _context.setResult(result);
63      }
64  
65      private JobExecutionContext _context;
66  
67  }