[][src]Enum watchman_client::Expr

pub enum Expr {
    True,
    False,
    Not(Box<Expr>),
    All(Vec<Expr>),
    Any(Vec<Expr>),
    DirName(DirNameTerm),
    Empty,
    Exists,
    Match(MatchTerm),
    Name(NameTerm),
    Pcre(PcreTerm),
    Since(SinceTerm),
    Size(RelOp),
    Suffix(Vec<String>),
    FileType(FileType),
}

An expression term used to filter candidate files from query results.

Variants

True

Always evaluates to true

False

Always evaluates to false

Not(Box<Expr>)

Inverts the match state of the child term

All(Vec<Expr>)

Evaluates to true IFF all child terms evaluate true

Any(Vec<Expr>)

Evaluates to true if any child terms evaluate true

DirName(DirNameTerm)

Match on the parent directory structure https://facebook.github.io/watchman/docs/expr/dirname.html

Empty

Evaluates as true if the file exists, has size 0 and is a regular file or directory. https://facebook.github.io/watchman/docs/expr/empty.html

Exists

Evaluates as true if the file exists; this is useful for filtering out notifications for files that have been deleted. Note that this term doesn't add value for path and glob generators which implicitly add this constraint. https://facebook.github.io/watchman/docs/expr/exists.html

Match(MatchTerm)

Performs a glob-style match against the file name https://facebook.github.io/watchman/docs/expr/match.html

Name(NameTerm)

Performs an exact match against the file name. https://facebook.github.io/watchman/docs/expr/name.html

Pcre(PcreTerm)

Use PCRE to match the filename. Note that this is an optional server feature and using this term on a server that doesn't support this feature will generate an error in response to the query. https://facebook.github.io/watchman/docs/expr/pcre.html

Since(SinceTerm)

Evaluates as true if the specified time property of the file is greater than the since value. https://facebook.github.io/watchman/docs/expr/since.html

Size(RelOp)

Evaluate as true if the size of a file matches the specified constraint. Files that do not presently exist will evaluate as false. https://facebook.github.io/watchman/docs/expr/size.html

Suffix(Vec<String>)

Evaluate as true if the filename suffix (also known as extension) matches the provided set of suffixes. Suffix matches are always case insensitive. php matches foo.php and foo.PHP but not foophp. https://facebook.github.io/watchman/docs/expr/suffix.html

FileType(FileType)

Evaluate as true if the file type exactly matches the specified type.

Trait Implementations

impl Into<Value> for Expr[src]

impl Clone for Expr[src]

impl Debug for Expr[src]

impl Serialize for Expr[src]

Auto Trait Implementations

impl Send for Expr

impl Sync for Expr

impl Unpin for Expr

impl UnwindSafe for Expr

impl RefUnwindSafe for Expr

Blanket Implementations

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

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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.

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

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

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