Path

This class is like FilePath, but adds additional operators to make things easier.

Constructors

this
this(cstring s)

Constructs from a string.

this
this()

Constructs an empty Path.

Members

Functions

absolute
Path absolute()

Returns an absolute path relative to the current working directory.

noext
Path noext()

The path without its extension. Returns a copy.

normalize
Path normalize()

Returns a normalized path, removing parts like "./" and "../".

opCat
Path opCat(cstring s)
Path opCat(Path p)

Concatenate s. Returns a copy.

opCatAssign
Path opCatAssign(cstring s)
Path opCatAssign(Path p)

Concatenate s. path ~= s

opDiv
Path opDiv(cstring s)
Path opDiv(Path p)

Append s. Returns a copy.

opDivAssign
Path opDivAssign(cstring s)
Path opDivAssign(Path p)

Append s. p /= s

opSlice
inout(char)[] opSlice()

Returns the path as a string.

Static functions

opCall
Path opCall(cstring s)
Path opCall()

Returns a new Path object.

Meta