1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
//! Native RFC 5228 Sieve interpreter.
//!
//! The internal engine `mailrs-sieve` (the wrapper) will route to
//! once it reaches differential parity with `sieve-rs` (v8 ckpt 6
//! swap). This crate is Apache-2.0 OR MIT — no AGPL, no
//! `deny.toml` exception.
//!
//! ## Quick start
//!
//! ```
//! use mailrs_sieve_core::{Action, eval_script};
//!
//! let script = r#"
//! require ["fileinto"];
//! if header :is "Subject" "spam" {
//! fileinto "Junk";
//! } else {
//! keep;
//! }
//! "#;
//! let message = b"Subject: spam\r\n\r\nbody\r\n";
//! let actions = eval_script(script, message).unwrap();
//! assert_eq!(
//! actions,
//! vec![Action::FileInto { mailbox: "Junk".into(), flags: vec![] }],
//! );
//! ```
//!
//! ## Status
//!
//! 0.1 — RFC 5228 base + RFC 5230 vacation + RFC 5232 imap4flags.
//! See `CHANGELOG.md`.
pub use ;
pub use validate;
pub use ;
pub use ;
pub use ;
pub use ;