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
//! Contains structs required for the configuration of the searcher module

///Configurations options for Searcher

#[derive(Clone)]
pub struct Options {
    pub exclude: bool,
    pub include_before: bool,
    pub include_after: bool,
    pub case_insensitive: bool,
    pub regex: bool,
}
impl Default for Options {

    fn default() -> Options {
        Options {
            exclude: false,
            include_before: false,
            include_after: false,
            case_insensitive: false,
            regex: false,
        }
    }
}
impl Options {
    pub fn new(exclude: bool, include_before: bool, include_after: bool,
         case_insensitive: bool, regex: bool) -> Options {
        Options {
            exclude,
            include_before,
            include_after,
            case_insensitive,
            regex,
        }
    }
}