public void SetLastWriteTimeUtc(string path, DateTime lastWriteTimeUtc) { Guard.NotNull(path, nameof(path)); AbsolutePath absolutePath = owner.ToAbsolutePath(path); var handler = new FileSetTimeHandler(root); var arguments = new FileSetTimeArguments(absolutePath, FileTimeKind.LastWriteTime, true, lastWriteTimeUtc); handler.Handle(arguments); }
public void SetCreationTime(string path, DateTime creationTime) { Guard.NotNull(path, nameof(path)); AbsolutePath absolutePath = owner.ToAbsolutePath(path); var handler = new FileSetTimeHandler(root); var arguments = new FileSetTimeArguments(absolutePath, FileTimeKind.CreationTime, false, creationTime); handler.Handle(arguments); }