This case study demonstrates the following techniques:
Using classes and class action scripts
For more information, see Writing Class Action Scripts.
Using the crontab command within a class action script