FileSystem.move

bool move(string src, string dest)

Move / rename a file or a directory. If the destination exists:

  • if it is a non-empty directory, an error is returned
  • otherwise, if it has the same type as the source, it is replaced
  • otherwise, behavior is unspecified (implementation-dependent).

Parameters

srcThe path of the source file.
destThe path of the destination.

Returns

true on success, false if there was an error.

Throws

[ErrorWrap]