3 # Copyright 2007 Liblime Ltd
5 # This file is part of Koha.
7 # Koha is free software; you can redistribute it and/or modify it under the
8 # terms of the GNU General Public License as published by the Free Software
9 # Foundation; either version 2 of the License, or (at your option) any later
12 # Koha is distributed in the hope that it will be useful, but WITHOUT ANY
13 # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
14 # A PARTICULAR PURPOSE. See the GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License along with
17 # Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
18 # Suite 330, Boston, MA 02111-1307 USA
23 use vars qw($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);
27 # set the version for version checking
32 qw(get_jobs get_job add_job remove_job);
36 C4::Scheduler - Module for running jobs with the unix at command
53 This will return all scheduled jobs
58 my %jobs = Schedule::At::getJobs();
64 This will return the job with the given id
70 my %jobs = chedule::At::getJobs(JOBID => $id);
73 =item add_job ($time,$command)
75 Given a timestamp and a command this will schedule the job to run at that time
80 my ($time,$command) = @_;
81 Schedule::At::add(TIME => $time, COMMAND => $command, TAG => $command);
86 Schedule::At::remove(JOBID => $jobid);
91 Chris Cormack <crc@liblime.com>