GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
Crontab(3) User Contributed Perl Documentation Crontab(3)

Set::Crontab - Expand crontab(5)-style integer lists

$s = Set::Crontab->new("1-9/3,>15,>30,!23", [0..30]);

if ($s->contains(3)) { ... }

Set::Crontab parses crontab-style lists of integers and defines some utility functions to make it easier to deal with them.

Numbers, ranges, *, and step values all work exactly as described in crontab(5). A few extensions to the standard syntax are described below.
< and >
<N selects the elements smaller than N from the entire range, and adds them to the set. >N does likewise for elements larger than N.
!
!N excludes N from the set. It applies to the other specified range; otherwise it applies to the specified ranges (i.e. "!3" with a range of "1-10" corresponds to "1-2,4-10", but ">3,!7" in the same range means "4-6,8-10").

new($spec, [@range])
Creates a new Set::Crontab object and returns a reference to it.
contains($num)
Returns true if $num exists in the set.
list()
Returns the expanded list corresponding to the set. Elements are in ascending order.

The functions described above croak if they are called with incorrect arguments.

crontab(5)

Abhijit Menon-Sen <ams@toroid.org>

Copyright 2001 Abhijit Menon-Sen <ams@toroid.org>

This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

2010-05-08 perl v5.32.1

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.