object

crontab(Representation)

  • Representation - Text representation. Valid values are atom, chars, and codes.

Parser and generator for user and system crontab files.

Availability:
logtalk_load(crontab(loader))
Author: Paulo Moura
Version: 1:1:2
Date: 2026-10-07
Compilation flags:
static, context_switching_calls
Imports:
public options
Uses:
Remarks:
(none)

Public predicates

parse/2

Parses a user crontab from the given source using the default options.

Compilation flags:
static
Template:
parse(Source,Entries)
Mode and number of proofs:
parse(++compound,--list) - one_or_error
Exceptions:
Source is a variable:
instantiation_error
Source is neither a variable nor a valid JSON source term:
domain_error(json_source,Source)
Source is a valid JSON source term but does not contain parsable JSON:
domain_error(json,Source)

parse/3

Parses a crontab from the given source. The supported option is format(user) (default) or format(system).

Compilation flags:
static
Template:
parse(Source,Entries,Options)
Mode and number of proofs:
parse(++compound,--list,+list(compound)) - one_or_error
Exceptions:
Source is a variable:
instantiation_error
Source is neither a variable nor a valid JSON source term:
domain_error(json_source,Source)
Source is a valid JSON source term but does not contain parsable JSON:
domain_error(json,Source)
Options is a variable:
instantiation_error
Options is neither a variable nor a list:
type_error(list,Options)
An element Option of the list Options is a variable:
instantiation_error
An element Option of the list Options is neither a variable nor a compound term:
type_error(compound,Option)
An element Option of the list Options is a compound term but not a valid option:
domain_error(option,Option)

generate/2

Generates a user crontab to the given sink using the default options.

Compilation flags:
static
Template:
generate(Sink,Entries)
Mode and number of proofs:
generate(+compound,+list) - one_or_error
Exceptions:
Sink is a variable:
instantiation_error
Sink is neither a variable nor a valid JSON sink term:
domain_error(json_sink,Sink)
A JSON version of Term cannot be generated by the implementation:
domain_error(json_term,Term)

generate/3

Generates a crontab to the given sink. The supported option is format(user) (default) or format(system).

Compilation flags:
static
Template:
generate(Sink,Entries,Options)
Mode and number of proofs:
generate(+compound,+list,+list(compound)) - one_or_error
Exceptions:
Sink is a variable:
instantiation_error
Sink is neither a variable nor a valid JSON sink term:
domain_error(json_sink,Sink)
A JSON version of Term cannot be generated by the implementation:
domain_error(json_term,Term)
Options is a variable:
instantiation_error
Options is neither a variable nor a list:
type_error(list,Options)
An element Option of the list Options is a variable:
instantiation_error
An element Option of the list Options is neither a variable nor a compound term:
type_error(compound,Option)
An element Option of the list Options is a compound term but not a valid option:
domain_error(option,Option)

entry/1

True if the argument is a valid crontab entry using the current text representation.

Compilation flags:
static
Template:
entry(Entry)
Mode and number of proofs:
entry(@nonvar) - zero_or_one

Protected predicates

(no local declarations; see entity ancestors if any)

Private predicates

(no local declarations; see entity ancestors if any)

Operators

(none)