method File.isDir
Whether path is a directory (following links); false for a missing path.
Example:
use std.io { File, fs }
fn main() io {
let dir = fs.tempDir()!
print("{File.isDir(dir)}")
fs.removeAll(dir)!
}Output
true
pub(api) static fn isDir(path: str) -> bool ioSince. 1.0.0-beta
Parameters
| Name | Type |
|---|---|
path | str |
Returns
bool
Effects
io
Defined in: std/io/io.oxl:545