1/*2 * Copyright 2000-2001,2004 The Apache Software Foundation.3 * 4 * Licensed under the Apache License, Version 2.0 (the "License");5 * you may not use this file except in compliance with the License.6 * You may obtain a copy of the License at7 * 8 * http://www.apache.org/licenses/LICENSE-2.09 * 10 * Unless required by applicable law or agreed to in writing, software11 * distributed under the License is distributed on an "AS IS" BASIS,12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.13 * See the License for the specific language governing permissions and14 * limitations under the License.15 */1617packageorg.apache.jetspeed.daemon;
1819/***20@author <a href="mailto:burton@apache.org">Kevin A. Burton</a>21@version $Id: DaemonEntry.java,v 1.4 2004/02/23 02:48:57 jford Exp $22*/23publicclassDaemonEntry {
2425private String name;
26privatelong interval = 0;
27private String classname;
28privateboolean onstartup = false;
29privateboolean hasprocessed = false;
30privateint status = Daemon.STATUS_NOT_PROCESSED;
3132publicDaemonEntry( String name,
33long interval,
34 String classname,
35boolean onstartup ) {
36this.name = name;
37this.interval = interval;
38this.classname = classname;
39this.onstartup = onstartup;
4041 }
4243/***44 The "name" of this Daemon. This is the handle used within Jetspeed45 for representation.46 */47public String getName() { returnthis.name; }
4849/***50 The amount of time in seconds that this daemon should wait before51 processing again.52 */53publiclong getInterval() { returnthis.interval; }
5455/***56 The classname of this daemon57 */58public String getClassname() { returnthis.classname; }
5960/***61 Determine if this daemon should run on system startup.62 */63publicboolean onStartup() { returnthis.onstartup; }
6465/***66 Return true if this daemon has processed at least once.6768 @author <a href="mailto:burton@apache.org">Kevin A. Burton</a>69 @version $Id: DaemonEntry.java,v 1.4 2004/02/23 02:48:57 jford Exp $70 */71publicboolean hasProcessed() { returnthis.hasprocessed; }
7273publicint getStatus() {
74returnthis.status;
75 }
7677 }