SwaponCommand.Builder
Fluent builder.
public class SwaponCommand.Builder :
LinuxCommandBase.BuilderBase<SwaponCommand, SwaponCommand.Builder>
1. Constructors
1.1. Builder()
Creates a new builder pointed at /sbin/swapon.
public Builder()
2. Methods
2.1. BuildInternal(CliWrap.Command)
protected override SwaponCommand BuildInternal(CliWrap.Command cliCommand)
| Name | Type | Description |
|---|---|---|
cliCommand |
CliWrap.Command |
Returns: SwaponCommand
2.2. EnableDiscard()
Discard freed pages back to the device (--discard).
public SwaponCommand.Builder EnableDiscard()
Returns: SwaponCommand.Builder
2.3. ForAll()
Activate all swap areas listed in /etc/fstab (-a).
public SwaponCommand.Builder ForAll()
Returns: SwaponCommand.Builder
2.4. WithDevice(string)
Block device or file to enable as swap (positional).
public SwaponCommand.Builder WithDevice(string device)
| Name | Type | Description |
|---|---|---|
device |
string |
Returns: SwaponCommand.Builder
2.5. WithPriority(int)
Set swap priority 0..32767 (-p <prio>).
public SwaponCommand.Builder WithPriority(int priority)
| Name | Type | Description |
|---|---|---|
priority |
int |
Returns: SwaponCommand.Builder