C# Класс NuSelfUpdate.Tests.Helpers.MockFileSystem

Наследование: IExtendedFileSystem
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
AddFile ( string path ) : void
AddFile ( string path, Func getStream ) : void
AddFile ( string path, Stream stream ) : void
AddFile ( string path, string content ) : void
CreateDirectory ( string path ) : void
DeleteDirectory ( string path, bool recursive = false ) : void
DeleteFile ( string path ) : void
DirectoryExists ( string path ) : bool
FileExists ( string path ) : bool
GetCreated ( string path ) : DateTimeOffset
GetDirectories ( string path ) : IEnumerable
GetFiles ( string path ) : IEnumerable
GetFiles ( string path, string filter ) : IEnumerable
GetFullPath ( string path ) : string
GetLastModified ( string path ) : DateTimeOffset
MockFileSystem ( string appDirectory ) : System
MoveFile ( string sourcePath, string destinationPath ) : void
OpenFile ( string path ) : Stream
ReadAllText ( string path ) : string

Приватные методы

Метод Описание
GetFilterRegex ( string wildcard ) : Regex
GetPattern ( string token ) : string
IndexOfAll ( string value, char ch ) : IEnumerable
InternalGetDirectories ( string path ) : IEnumerable

Описание методов

AddFile() публичный Метод

public AddFile ( string path ) : void
path string
Результат void

AddFile() публичный Метод

public AddFile ( string path, Func getStream ) : void
path string
getStream Func
Результат void

AddFile() публичный Метод

public AddFile ( string path, Stream stream ) : void
path string
stream Stream
Результат void

AddFile() публичный Метод

public AddFile ( string path, string content ) : void
path string
content string
Результат void

CreateDirectory() публичный Метод

public CreateDirectory ( string path ) : void
path string
Результат void

DeleteDirectory() публичный Метод

public DeleteDirectory ( string path, bool recursive = false ) : void
path string
recursive bool
Результат void

DeleteFile() публичный Метод

public DeleteFile ( string path ) : void
path string
Результат void

DirectoryExists() публичный Метод

public DirectoryExists ( string path ) : bool
path string
Результат bool

FileExists() публичный Метод

public FileExists ( string path ) : bool
path string
Результат bool

GetCreated() публичный Метод

public GetCreated ( string path ) : DateTimeOffset
path string
Результат DateTimeOffset

GetDirectories() публичный Метод

public GetDirectories ( string path ) : IEnumerable
path string
Результат IEnumerable

GetFiles() публичный Метод

public GetFiles ( string path ) : IEnumerable
path string
Результат IEnumerable

GetFiles() публичный Метод

public GetFiles ( string path, string filter ) : IEnumerable
path string
filter string
Результат IEnumerable

GetFullPath() публичный Метод

public GetFullPath ( string path ) : string
path string
Результат string

GetLastModified() публичный Метод

public GetLastModified ( string path ) : DateTimeOffset
path string
Результат DateTimeOffset

MockFileSystem() публичный Метод

public MockFileSystem ( string appDirectory ) : System
appDirectory string
Результат System

MoveFile() публичный Метод

public MoveFile ( string sourcePath, string destinationPath ) : void
sourcePath string
destinationPath string
Результат void

OpenFile() публичный Метод

public OpenFile ( string path ) : Stream
path string
Результат Stream

ReadAllText() публичный Метод

public ReadAllText ( string path ) : string
path string
Результат string