Trait NixPath

trait NixPath

Common trait used to represent file system paths by many Nix functions.

Required Methods

fn is_empty(self: &Self) -> bool

Is the path empty?

fn len(self: &Self) -> usize

Length of the path in bytes

fn with_nix_path<T, F>(self: &Self, f: F) -> Result<T>
where
    F: FnOnce(&CStr) -> T

Execute a function with this path as a CStr.

Mostly used internally by Nix.

Implementors