Using Directory.GetFiles Filtering multiple types of files


The author of the original text does not allow reprint, send a chain here, everybody goes to see.


For backup. Here’s a brief idea Directory.GetFiles.Where Use lambda expressions to filter.

To be more specific, one is used in where. Endwith, and the other is used in where Regex.IsMatch Regular expression for.

For example, to filter out. JPG /. PNG /. TIFF /. BMP /. GIF files, the regular expression is:



Recommended Today

Webassembly and trust

Rust’s support for webassembly is the most perfect. After all, a large part of Mozilla’s original development of trust was to write servo (browser rendering engine). In addition, the two wasm runtimes, wasmer and wasmtime, which we introduced, are also written with rust. For the use of rust to write wasm module and the use […]