1use crate::settings::{Flags, GroupSettings, Settings};
6
7lazy_static! {
8 pub static ref DEFAULT_GROUP: GroupSettings = GroupSettings {
9 is_non_capture: false,
10 other: Settings {
11 is_optional: false,
12 is_one_or_more: false,
13 is_nil_or_more: false,
14 is_optional_ungreedy: false,
15 with_left_boundary: false,
16 with_left_non_boundary: false,
17 with_right_boundary: false,
18 with_right_non_boundary: false,
19 range: None,
20 exactly: None,
21 flags: None
22 },
23 };
24 pub static ref OPTIONAL_GROUP: GroupSettings = GroupSettings {
25 is_non_capture: false,
26 other: Settings {
27 is_optional: true,
28 is_one_or_more: false,
29 is_nil_or_more: false,
30 is_optional_ungreedy: false,
31 with_left_boundary: false,
32 with_left_non_boundary: false,
33 with_right_boundary: false,
34 with_right_non_boundary: false,
35 range: None,
36 exactly: None,
37 flags: None
38 },
39 };
40 pub static ref OPTIONAL_GROUP_UNGREEDY: GroupSettings = GroupSettings {
41 is_non_capture: false,
42 other: Settings {
43 is_optional: false,
44 is_optional_ungreedy: true,
45 is_one_or_more: false,
46 is_nil_or_more: false,
47 with_left_boundary: false,
48 with_left_non_boundary: false,
49 with_right_boundary: false,
50 with_right_non_boundary: false,
51 range: None,
52 exactly: None,
53 flags: None
54 },
55 };
56 pub static ref NON_CAPTURE: GroupSettings = GroupSettings {
57 is_non_capture: true,
58 other: Settings {
59 is_optional: false,
60 is_one_or_more: false,
61 is_nil_or_more: false,
62 is_optional_ungreedy: false,
63 with_left_boundary: false,
64 with_left_non_boundary: false,
65 with_right_boundary: false,
66 with_right_non_boundary: false,
67 range: None,
68 exactly: None,
69 flags: None
70 },
71 };
72 pub static ref INSENSITIVE_GROUP: GroupSettings = GroupSettings {
73 is_non_capture: false,
74 other: Settings {
75 is_optional: false,
76 is_one_or_more: false,
77 is_nil_or_more: false,
78 is_optional_ungreedy: false,
79 with_left_boundary: false,
80 with_left_non_boundary: false,
81 with_right_boundary: false,
82 with_right_non_boundary: false,
83 range: None,
84 exactly: None,
85 flags: Some(Flags::Insensitive),
86 },
87 };
88 pub static ref MULTILINE_GROUP: GroupSettings = GroupSettings {
89 is_non_capture: false,
90 other: Settings {
91 is_optional: false,
92 is_one_or_more: false,
93 is_nil_or_more: false,
94 is_optional_ungreedy: false,
95 with_left_boundary: false,
96 with_left_non_boundary: false,
97 with_right_boundary: false,
98 with_right_non_boundary: false,
99 range: None,
100 exactly: None,
101 flags: Some(Flags::Multiline),
102 },
103 };
104 pub static ref DOT_MATCH_NEWLINE_GROUP: GroupSettings = GroupSettings {
105 is_non_capture: false,
106 other: Settings {
107 is_optional: false,
108 is_one_or_more: false,
109 is_nil_or_more: false,
110 is_optional_ungreedy: false,
111 with_left_boundary: false,
112 with_left_non_boundary: false,
113 with_right_boundary: false,
114 with_right_non_boundary: false,
115 range: None,
116 exactly: None,
117 flags: Some(Flags::DotMatchNewLine),
118 },
119 };
120 pub static ref IGNORE_WHITESPACE_GROUP: GroupSettings = GroupSettings {
121 is_non_capture: false,
122 other: Settings {
123 is_optional: false,
124 is_one_or_more: false,
125 is_nil_or_more: false,
126 is_optional_ungreedy: false,
127 with_left_boundary: false,
128 with_left_non_boundary: false,
129 with_right_boundary: false,
130 with_right_non_boundary: false,
131 range: None,
132 exactly: None,
133 flags: Some(Flags::IgnoreWhitespace),
134 },
135 };
136 pub static ref INSENSITIVE_NON_CAPTURE: GroupSettings = GroupSettings {
137 is_non_capture: true,
138 other: Settings {
139 is_optional: false,
140 is_one_or_more: false,
141 is_nil_or_more: false,
142 is_optional_ungreedy: false,
143 with_left_boundary: false,
144 with_left_non_boundary: false,
145 with_right_boundary: false,
146 with_right_non_boundary: false,
147 range: None,
148 exactly: None,
149 flags: Some(Flags::Insensitive),
150 },
151 };
152 pub static ref MULTILINE_NON_CAPTURE: GroupSettings = GroupSettings {
153 is_non_capture: true,
154 other: Settings {
155 is_optional: false,
156 is_one_or_more: false,
157 is_nil_or_more: false,
158 is_optional_ungreedy: false,
159 with_left_boundary: false,
160 with_left_non_boundary: false,
161 with_right_boundary: false,
162 with_right_non_boundary: false,
163 range: None,
164 exactly: None,
165 flags: Some(Flags::Multiline),
166 },
167 };
168 pub static ref DOT_MATCH_NEWLINE_NON_CAPTURE: GroupSettings = GroupSettings {
169 is_non_capture: true,
170 other: Settings {
171 is_optional: false,
172 is_one_or_more: false,
173 is_nil_or_more: false,
174 is_optional_ungreedy: false,
175 with_left_boundary: false,
176 with_left_non_boundary: false,
177 with_right_boundary: false,
178 with_right_non_boundary: false,
179 range: None,
180 exactly: None,
181 flags: Some(Flags::DotMatchNewLine),
182 },
183 };
184 pub static ref IGNORE_WHITESPACE_NON_CAPTURE: GroupSettings = GroupSettings {
185 is_non_capture: true,
186 other: Settings {
187 is_optional: false,
188 is_optional_ungreedy: false,
189 is_one_or_more: false,
190 is_nil_or_more: false,
191 with_left_boundary: false,
192 with_left_non_boundary: false,
193 with_right_boundary: false,
194 with_right_non_boundary: false,
195 range: None,
196 exactly: None,
197 flags: Some(Flags::IgnoreWhitespace),
198 },
199 };
200 pub static ref SENSITIVE_GROUP: GroupSettings = GroupSettings {
201 is_non_capture: false,
202 other: Settings {
203 is_optional: false,
204 is_optional_ungreedy: false,
205 is_one_or_more: false,
206 is_nil_or_more: false,
207 with_left_boundary: false,
208 with_left_non_boundary: false,
209 with_right_boundary: false,
210 with_right_non_boundary: false,
211 range: None,
212 exactly: None,
213 flags: Some(Flags::Sensitive),
214 },
215 };
216 pub static ref SINGLE_LINE_GROUP: GroupSettings = GroupSettings {
217 is_non_capture: false,
218 other: Settings {
219 is_optional: false,
220 is_optional_ungreedy: false,
221 is_one_or_more: false,
222 is_nil_or_more: false,
223 with_left_boundary: false,
224 with_left_non_boundary: false,
225 with_right_boundary: false,
226 with_right_non_boundary: false,
227 range: None,
228 exactly: None,
229 flags: Some(Flags::SingleLine),
230 },
231 };
232 pub static ref DOT_DISMATCH_NEWLINE_GROUP: GroupSettings = GroupSettings {
233 is_non_capture: false,
234 other: Settings {
235 is_optional: false,
236 is_optional_ungreedy: false,
237 is_one_or_more: false,
238 is_nil_or_more: false,
239 with_left_boundary: false,
240 with_left_non_boundary: false,
241 with_right_boundary: false,
242 with_right_non_boundary: false,
243 range: None,
244 exactly: None,
245 flags: Some(Flags::DotDisMatchNewLine),
246 },
247 };
248 pub static ref INCLUDE_WHITESPACE_GROUP: GroupSettings = GroupSettings {
249 is_non_capture: false,
250 other: Settings {
251 is_optional: false,
252 is_optional_ungreedy: false,
253 is_one_or_more: false,
254 is_nil_or_more: false,
255 with_left_boundary: false,
256 with_left_non_boundary: false,
257 with_right_boundary: false,
258 with_right_non_boundary: false,
259 range: None,
260 exactly: None,
261 flags: Some(Flags::IncludeWhitespace),
262 },
263 };
264 pub static ref SENSITIVE_NON_CAPTURE: GroupSettings = GroupSettings {
265 is_non_capture: true,
266 other: Settings {
267 is_optional: false,
268 is_optional_ungreedy: false,
269 is_one_or_more: false,
270 is_nil_or_more: false,
271 with_left_boundary: false,
272 with_left_non_boundary: false,
273 with_right_boundary: false,
274 with_right_non_boundary: false,
275 range: None,
276 exactly: None,
277 flags: Some(Flags::Sensitive),
278 },
279 };
280 pub static ref SINGLE_LINE_NON_CAPTURE: GroupSettings = GroupSettings {
281 is_non_capture: true,
282 other: Settings {
283 is_optional: false,
284 is_optional_ungreedy: false,
285 is_one_or_more: false,
286 is_nil_or_more: false,
287 with_left_boundary: false,
288 with_left_non_boundary: false,
289 with_right_boundary: false,
290 with_right_non_boundary: false,
291 range: None,
292 exactly: None,
293 flags: Some(Flags::SingleLine),
294 },
295 };
296 pub static ref DOT_DISMATCH_NEWLINE_NON_CAPTURE: GroupSettings = GroupSettings {
297 is_non_capture: true,
298 other: Settings {
299 is_optional: false,
300 is_optional_ungreedy: false,
301 is_one_or_more: false,
302 is_nil_or_more: false,
303 with_left_boundary: false,
304 with_left_non_boundary: false,
305 with_right_boundary: false,
306 with_right_non_boundary: false,
307 range: None,
308 exactly: None,
309 flags: Some(Flags::DotDisMatchNewLine),
310 },
311 };
312 pub static ref INCLUDE_WHITESPACE_NON_CAPTURE: GroupSettings = GroupSettings {
313 is_non_capture: true,
314 other: Settings {
315 is_optional: false,
316 is_optional_ungreedy: false,
317 is_one_or_more: false,
318 is_nil_or_more: false,
319 with_left_boundary: false,
320 with_left_non_boundary: false,
321 with_right_boundary: false,
322 with_right_non_boundary: false,
323 range: None,
324 exactly: None,
325 flags: Some(Flags::IncludeWhitespace),
326 },
327 };
328}