RobocopyCommand.Builder
public class RobocopyCommand.Builder :
CliWrapCommandBase<CommandResult>.BuilderBase<RobocopyCommand, RobocopyCommand.Builder>
1. Constructors
1.1. Builder()
public Builder()
2. Properties
2.1. LongArgumentPrefix
protected override string LongArgumentPrefix { get; }
2.2. SingleCharacterArgumentPrefix
protected override string SingleCharacterArgumentPrefix { get; }
3. Methods
3.1. Build()
public override RobocopyCommand Build()
Returns: RobocopyCommand
3.2. BuildInternal(CliWrap.Command)
protected override RobocopyCommand BuildInternal(CliWrap.Command cliCommand)
| Name | Type | Description |
|---|---|---|
cliCommand |
CliWrap.Command |
Returns: RobocopyCommand
3.3. CopyDataAttrTimestamps()
/COPY:DAT - copy data, attributes, timestamps.
public RobocopyCommand.Builder CopyDataAttrTimestamps()
Returns: RobocopyCommand.Builder
3.4. CopyDirAttrTimestamps()
/DCOPY:DAT - copy directory data, attributes, timestamps.
public RobocopyCommand.Builder CopyDirAttrTimestamps()
Returns: RobocopyCommand.Builder
3.5. Destination(string)
public RobocopyCommand.Builder Destination(string destination)
| Name | Type | Description |
|---|---|---|
destination |
string |
Returns: RobocopyCommand.Builder
3.6. ExcludeDirs(string[])
/XD - exclude directories matching patterns.
public RobocopyCommand.Builder ExcludeDirs(params string[] patterns)
| Name | Type | Description |
|---|---|---|
patterns |
string[] |
Returns: RobocopyCommand.Builder
3.7. ExcludeFiles(string[])
/XF - exclude files matching patterns.
public RobocopyCommand.Builder ExcludeFiles(params string[] patterns)
| Name | Type | Description |
|---|---|---|
patterns |
string[] |
Returns: RobocopyCommand.Builder
3.8. ExcludeJunctions()
/XJ - exclude junction points (avoid infinite loops).
public RobocopyCommand.Builder ExcludeJunctions()
Returns: RobocopyCommand.Builder
3.9. Mirror()
/MIR - mirror tree (purge + recursive).
public RobocopyCommand.Builder Mirror()
Returns: RobocopyCommand.Builder
3.10. MultiThreaded(int)
/MT:n - multithreaded copies. Default 8.
public RobocopyCommand.Builder MultiThreaded(int threads = 8)
| Name | Type | Description |
|---|---|---|
threads |
int |
Returns: RobocopyCommand.Builder
3.11. Quiet()
/NFL /NDL /NP - quiet (no file/dir/progress logs).
public RobocopyCommand.Builder Quiet()
Returns: RobocopyCommand.Builder
3.12. Recursive()
/E - copy subdirs, including empty.
public RobocopyCommand.Builder Recursive()
Returns: RobocopyCommand.Builder
3.13. Retries(int)
/R:n - retry count on failed copies.
public RobocopyCommand.Builder Retries(int count)
| Name | Type | Description |
|---|---|---|
count |
int |
Returns: RobocopyCommand.Builder
3.14. Source(string)
public RobocopyCommand.Builder Source(string source)
| Name | Type | Description |
|---|---|---|
source |
string |
Returns: RobocopyCommand.Builder
3.15. Unbuffered()
/J - unbuffered I/O. Faster for large files.
public RobocopyCommand.Builder Unbuffered()
Returns: RobocopyCommand.Builder
3.16. WaitSeconds(int)
/W:n - wait time between retries (seconds).
public RobocopyCommand.Builder WaitSeconds(int seconds)
| Name | Type | Description |
|---|---|---|
seconds |
int |
Returns: RobocopyCommand.Builder