VFSRange

A bidirectional range of VFS items (files or directories).

Destructor

A destructor is present on this object, but not explicitly documented in the source.

Alias This

range_

Members

Aliases

Items
alias Items = RedBlackTree!(T, compare, false)

Type used to store the items.

Functions

popBack
void popBack()

Pop the back element from the range.

popFront
void popFront()

Pop the front element from the range.

Properties

length
size_t length [@property getter]

Get number of items in the range.

Static functions

compare
bool compare(T a, T b)

Function used to compare items alphabetically.

Examples

1 //VFSDirs is a VFSRange of directories - VFSFiles of files.
2 VFSDirs dirs;
3 
4 //Get the first directory.
5 auto f = dirs.front;
6 
7 //Get the last directory.
8 auto b = dirs.back;
9 
10 //Remove the first directory from the range (this will not remove the directory itself).
11 dirs.popFront();
12 
13 //Remove the last directory from the range (this will not remove the directory itself).
14 dirs.popBack();
15 
16 //Are there no files/directories ?
17 bool empty = r.empty;

Meta