1// Copyright (c) 2018 The predicates-rs Project Developers.
2//
3// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
4// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
5// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
6// option. This file may not be copied, modified, or distributed
7// except according to those terms.
89//! Module that contains the essentials for working with predicates.
1011pub use crate::boolean::PredicateBooleanExt;
12pub use crate::boxed::PredicateBoxExt;
13pub use crate::name::PredicateNameExt;
14pub use crate::path::PredicateFileContentExt;
15pub use crate::str::PredicateStrExt;
16pub use crate::Predicate;
1718/// Predicate factories
19pub mod predicate {
20// primitive `Predicate` types
21pub use crate::constant::{always, never};
22pub use crate::function::function;
23pub use crate::iter::{in_hash, in_iter};
24pub use crate::ord::{eq, ge, gt, le, lt, ne};
2526/// `str` Predicate factories
27 ///
28 /// This module contains predicates specific to string handling.
29pub mod str {
30pub use crate::str::is_empty;
31pub use crate::str::{contains, ends_with, starts_with};
3233#[cfg(feature = "difference")]
34pub use crate::str::{diff, similar};
3536#[cfg(feature = "regex")]
37pub use crate::str::is_match;
38 }
3940/// `Path` Predicate factories
41 ///
42 /// This module contains predicates specific to path handling.
43pub mod path {
44pub use crate::path::eq_file;
45pub use crate::path::{exists, missing};
46pub use crate::path::{is_dir, is_file, is_symlink};
47 }
4849/// `f64` Predicate factories
50 ///
51 /// This module contains predicates specific to float handling.
52pub mod float {
53#[cfg(feature = "float-cmp")]
54pub use crate::float::is_close;
55 }
56}