swapMemory

fnSwapMemory swapMemory() @safe

Gets swap memory statistics.

Returns

SwapMemory structure with swap statistics.

Example:

auto swap = swapMemory();
writeln("Total swap: ", swap.total / 1024 / 1024, " MB");
writeln("Used swap: ", swap.used / 1024 / 1024, " MB");
writeln("Swap usage: ", swap.percent, "%");