Struct cron_lingo::timetable::Timetable[][src]

pub struct Timetable { /* fields omitted */ }

A timetable that is built from an expression and can be iterated in order to compute the next date(s) that match the specification. The computation is always based on the current system time. This is the only way (at this point) to use Timetable in a meaningful way.

The expression must adhere to a specific syntax. See the module-level documentation for the full range of possibilities.

Implementations

impl Timetable[src]

pub fn iter(&self) -> TimetableIter<'_>

Notable traits for TimetableIter<'a>

impl<'a> Iterator for TimetableIter<'a> type Item = OffsetDateTime;
[src]

Trait Implementations

impl Debug for Timetable[src]

impl FromStr for Timetable[src]

type Err = InvalidExpressionError

The associated error which can be returned from parsing.

fn from_str(expression: &str) -> Result<Self, Self::Err>[src]

Attempt to create a new Timetable object from an expression.

use cron_lingo::Timetable;
use std::str::FromStr;

let expr = "at 6 and 18 o'clock on Monday and Thursday in even weeks";
assert!(Timetable::from_str(expr).is_ok());

impl PartialEq<Timetable> for Timetable[src]

impl StructuralPartialEq for Timetable[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.