|
Joutsen v0.5.0+12-g5dd5f7e
|
A class offering convenience methods to interact with the filesystem. More...
Public Member Functions | |
| File | CopyFile (string sourcePath, string destinationPath, bool overwrite=false) |
Copies a file from sourcePath to destinationPath. More... | |
| File | CopyFile (FilesystemPath sourcePath, FilesystemPath destinationPath, bool overwrite=false) |
Copies a file from sourcePath to destinationPath. More... | |
| Folder | CopyFolder (string sourcePath, string destinationPath, bool recursive, bool overwrite=false) |
Copies a folder from sourcePath to destinationPath. More... | |
| Folder | CopyFolder (FilesystemPath sourcePath, FilesystemPath destinationPath, bool recursive, bool overwrite=false) |
Copies a folder from sourcePath to destinationPath. More... | |
| File | CreateFile (string path, Stream content=null) |
Creates a new file with content. More... | |
| File | CreateFile (FilesystemPath path, Stream content=null) |
Creates a new file with content. More... | |
| Folder | CreateFolder (string path) |
| Creates a new folder. More... | |
| Folder | CreateFolder (FilesystemPath path) |
| Creates a new folder. More... | |
| void | CreatePath (string path) |
| Creates an entire path by creating all the folders belonging to it. More... | |
| void | CreatePath (FilesystemPath path) |
| Creates an entire path by creating all the folders belonging to it. More... | |
| void | DeleteFile (string path) |
| Deletes the file on from the filesystem. More... | |
| void | DeleteFile (FilesystemPath path) |
| Deletes the file on from the filesystem. More... | |
| void | DeleteFolder (string path, bool recursive=false) |
| Deletes a folder from the filesystem. More... | |
| void | DeleteFolder (FilesystemPath path, bool recursive=false) |
| Deletes a folder from the filesystem. More... | |
| bool | FileExists (string path) |
| Checks if a file exists in the filesystem. More... | |
| bool | FolderExists (string path) |
| Checks if a folder exists in the filesystem. More... | |
| File | GetFile (string path) |
| Fetches a file from the filesystem. More... | |
| File | GetFile (FilesystemPath path) |
| Fetches a file from the filesystem. More... | |
| Folder | GetFolder (string path) |
| Fetches a folder from the filesystem. More... | |
| Folder | GetFolder (FilesystemPath path) |
| Fetches a folder from the filesystem. More... | |
| Set< FilesystemPath > | ListFolder (string path, string searchPattern="*") |
| Lists the content a the folder. More... | |
| Set< FilesystemPath > | ListFolder (FilesystemPath path, string searchPattern="*") |
| Lists the content a the folder. More... | |
| File | MoveFile (string sourcePath, string destinationPath) |
| Moves a file to a different location. More... | |
| File | MoveFile (FilesystemPath sourcePath, FilesystemPath destinationPath) |
| Moves a file to a different location. More... | |
| Folder | MoveFolder (string sourcePath, string destinationPath, bool keepFolder=false) |
| Moves a folder to a different location. More... | |
| Folder | MoveFolder (FilesystemPath sourcePath, FilesystemPath destinationPath, bool keepFolder=false) |
| Moves a folder to a different location. More... | |
| bool | PathExists (string path) |
| Checks if the path exists on the filesystem. More... | |
| File | ReplaceFile (string sourcePath, string destinationPath, string backupPath) |
Replaces the file at destinationPath with the file at sourcePath creating a backup in backupPath. More... | |
| File | ReplaceFile (FilesystemPath sourcePath, FilesystemPath destinationPath, FilesystemPath backupPath) |
Replaces the file at destinationPath with the file at sourcePath creating a backup in backupPath. More... | |
| SCG.IEnumerable< FilesystemPath > | WalkFolder (string path, string searchPattern="*") |
| Walks the filesystem returning one file or folder contained in this folder at a time. More... | |
| SCG.IEnumerable< FilesystemPath > | WalkFolder (FilesystemPath path, string searchPattern="*") |
| Walks the filesystem returning one file or folder contained in this folder at a time. More... | |
Public Member Functions inherited from Joutsen.IO.Filesystem | |
| File | GetFile (string path) |
| Fetches a file from the filesystem. More... | |
| File | GetFile (FilesystemPath path) |
| Fetches a file from the filesystem. More... | |
| File | CreateFile (string path, global::System.IO.Stream content=null) |
Creates a new file with content. More... | |
| File | CreateFile (FilesystemPath path, global::System.IO.Stream content=null) |
Creates a new file with content. More... | |
| File | CopyFile (string sourcePath, string destinationPath, bool overwrite=false) |
Copies a file from sourcePath to destinationPath. More... | |
| File | CopyFile (FilesystemPath sourcePath, FilesystemPath destinationPath, bool overwrite=false) |
Copies a file from sourcePath to destinationPath. More... | |
| File | MoveFile (string sourcePath, string destinationPath) |
| Moves a file to a different location. More... | |
| File | MoveFile (FilesystemPath sourcePath, FilesystemPath destinationPath) |
| Moves a file to a different location. More... | |
| void | DeleteFile (string path) |
| Deletes the file on from the filesystem. More... | |
| void | DeleteFile (FilesystemPath path) |
| Deletes the file on from the filesystem. More... | |
| File | ReplaceFile (string sourcePath, string destinationPath, string backupPath) |
Replaces the file at destinationPath with the file at sourcePath creating a backup in backupPath. More... | |
| File | ReplaceFile (FilesystemPath sourcePath, FilesystemPath destinationPath, FilesystemPath backupPath) |
Replaces the file at destinationPath with the file at sourcePath creating a backup in backupPath. More... | |
| bool | FileExists (string path) |
| Checks if a file exists in the filesystem. More... | |
| Folder | GetFolder (string path) |
| Fetches a folder from the filesystem. More... | |
| Folder | GetFolder (FilesystemPath path) |
| Fetches a folder from the filesystem. More... | |
| Folder | CreateFolder (string path) |
| Creates a new folder. More... | |
| Folder | CreateFolder (FilesystemPath path) |
| Creates a new folder. More... | |
| Folder | CopyFolder (string sourcePath, string destinationPath, bool recursive, bool overwrite=false) |
Copies a folder from sourcePath to destinationPath. More... | |
| Folder | CopyFolder (FilesystemPath sourcePath, FilesystemPath destinationPath, bool recursive, bool overwrite=false) |
Copies a folder from sourcePath to destinationPath. More... | |
| Folder | MoveFolder (string sourcePath, string destinationPath, bool keepFolder=false) |
| Moves a folder to a different location. More... | |
| Folder | MoveFolder (FilesystemPath sourcePath, FilesystemPath destinationPath, bool keepFolder=false) |
| Moves a folder to a different location. More... | |
| void | DeleteFolder (string path, bool recursive=false) |
| Deletes a folder from the filesystem. More... | |
| void | DeleteFolder (FilesystemPath path, bool recursive=false) |
| Deletes a folder from the filesystem. More... | |
| Set< FilesystemPath > | ListFolder (string path, string searchPattern="*") |
| Lists the content a the folder. More... | |
| Set< FilesystemPath > | ListFolder (FilesystemPath path, string searchPattern="*") |
| Lists the content a the folder. More... | |
| SCG.IEnumerable< FilesystemPath > | WalkFolder (string path, string searchPattern="*") |
| Walks the filesystem returning one file or folder contained in this folder at a time. More... | |
| SCG.IEnumerable< FilesystemPath > | WalkFolder (FilesystemPath path, string searchPattern="*") |
| Walks the filesystem returning one file or folder contained in this folder at a time. More... | |
| bool | FolderExists (string path) |
| Checks if a folder exists in the filesystem. More... | |
| void | CreatePath (string path) |
| Creates an entire path by creating all the folders belonging to it. More... | |
| void | CreatePath (FilesystemPath path) |
| Creates an entire path by creating all the folders belonging to it. More... | |
| bool | PathExists (string path) |
| Checks if the path exists on the filesystem. More... | |
A class offering convenience methods to interact with the filesystem.
| File Joutsen.IO.LocalFilesystem.CopyFile | ( | FilesystemPath | sourcePath, |
| FilesystemPath | destinationPath, | ||
| bool | overwrite = false |
||
| ) |
Copies a file from sourcePath to destinationPath.
| sourcePath | the path to copy the file from |
| destinationPath | the path to copy the file to |
| overwrite | determines if an existing file at destinationPath should be overwritten |
Implements Joutsen.IO.Filesystem.
| File Joutsen.IO.LocalFilesystem.CopyFile | ( | string | sourcePath, |
| string | destinationPath, | ||
| bool | overwrite = false |
||
| ) |
Copies a file from sourcePath to destinationPath.
| sourcePath | the path to copy the file from |
| destinationPath | the path to copy the file to |
| overwrite | determines if an existing file at destinationPath should be overwritten |
Implements Joutsen.IO.Filesystem.
| Folder Joutsen.IO.LocalFilesystem.CopyFolder | ( | FilesystemPath | sourcePath, |
| FilesystemPath | destinationPath, | ||
| bool | recursive, | ||
| bool | overwrite = false |
||
| ) |
Copies a folder from sourcePath to destinationPath.
| sourcePath | the path to copy the folder from |
| destinationPath | the path to copy the folder to |
| recursive | determines if subfolders should be copied as well |
| overwrite | determines if an existing folder at destinationPath should be replaced |
Implements Joutsen.IO.Filesystem.
| Folder Joutsen.IO.LocalFilesystem.CopyFolder | ( | string | sourcePath, |
| string | destinationPath, | ||
| bool | recursive, | ||
| bool | overwrite = false |
||
| ) |
Copies a folder from sourcePath to destinationPath.
| sourcePath | the path to copy the folder from |
| destinationPath | the path to copy the folder to |
| recursive | determines if subfolders should be copied as well |
| overwrite | determines if an existing folder at destinationPath should be replaced |
Implements Joutsen.IO.Filesystem.
| File Joutsen.IO.LocalFilesystem.CreateFile | ( | FilesystemPath | path, |
| Stream | content = null |
||
| ) |
Creates a new file with content.
| path | the path to the new file |
| content | optional, the content that should be written to the new file. If content is null, an empty file is created. |
| File Joutsen.IO.LocalFilesystem.CreateFile | ( | string | path, |
| Stream | content = null |
||
| ) |
Creates a new file with content.
| path | the path to the new file |
| content | optional, the content that should be written to the new file. If content is null, an empty file is created. |
| Folder Joutsen.IO.LocalFilesystem.CreateFolder | ( | FilesystemPath | path | ) |
| Folder Joutsen.IO.LocalFilesystem.CreateFolder | ( | string | path | ) |
| void Joutsen.IO.LocalFilesystem.CreatePath | ( | FilesystemPath | path | ) |
Creates an entire path by creating all the folders belonging to it.
| the | path to create |
Implements Joutsen.IO.Filesystem.
| void Joutsen.IO.LocalFilesystem.CreatePath | ( | string | path | ) |
Creates an entire path by creating all the folders belonging to it.
| the | path to create |
Implements Joutsen.IO.Filesystem.
| void Joutsen.IO.LocalFilesystem.DeleteFile | ( | FilesystemPath | path | ) |
Deletes the file on from the filesystem.
| path | the path to the file to delete |
Implements Joutsen.IO.Filesystem.
| void Joutsen.IO.LocalFilesystem.DeleteFile | ( | string | path | ) |
Deletes the file on from the filesystem.
| path | the path to the file to delete |
Implements Joutsen.IO.Filesystem.
| void Joutsen.IO.LocalFilesystem.DeleteFolder | ( | FilesystemPath | path, |
| bool | recursive = false |
||
| ) |
Deletes a folder from the filesystem.
| path | the path to the folder to delete |
| recursive | determines if the folder should only be deleted if it is empty or if files and subfolders should be deleted as well |
Implements Joutsen.IO.Filesystem.
| void Joutsen.IO.LocalFilesystem.DeleteFolder | ( | string | path, |
| bool | recursive = false |
||
| ) |
Deletes a folder from the filesystem.
| path | the path to the folder to delete |
| recursive | determines if the folder should only be deleted if it is empty or if files and subfolders should be deleted as well |
Implements Joutsen.IO.Filesystem.
| bool Joutsen.IO.LocalFilesystem.FileExists | ( | string | path | ) |
Checks if a file exists in the filesystem.
| the | path to the file |
Implements Joutsen.IO.Filesystem.
| bool Joutsen.IO.LocalFilesystem.FolderExists | ( | string | path | ) |
Checks if a folder exists in the filesystem.
| the | path to the folder |
Implements Joutsen.IO.Filesystem.
| File Joutsen.IO.LocalFilesystem.GetFile | ( | FilesystemPath | path | ) |
Fetches a file from the filesystem.
| the | path to the file |
path on the filesystem. Implements Joutsen.IO.Filesystem.
| File Joutsen.IO.LocalFilesystem.GetFile | ( | string | path | ) |
Fetches a file from the filesystem.
| the | path to the file |
path on the filesystem. Implements Joutsen.IO.Filesystem.
| Folder Joutsen.IO.LocalFilesystem.GetFolder | ( | FilesystemPath | path | ) |
Fetches a folder from the filesystem.
| the | path to the folder |
path on the filesystem. Implements Joutsen.IO.Filesystem.
| Folder Joutsen.IO.LocalFilesystem.GetFolder | ( | string | path | ) |
Fetches a folder from the filesystem.
| the | path to the folder |
path on the filesystem. Implements Joutsen.IO.Filesystem.
| Set< FilesystemPath > Joutsen.IO.LocalFilesystem.ListFolder | ( | FilesystemPath | path, |
| string | searchPattern = "*" |
||
| ) |
Lists the content a the folder.
| the | path to the folder |
| searchPattern | can be used to restrict the result to files and folders matching this pattern |
Implements Joutsen.IO.Filesystem.
| Set< FilesystemPath > Joutsen.IO.LocalFilesystem.ListFolder | ( | string | path, |
| string | searchPattern = "*" |
||
| ) |
Lists the content a the folder.
| the | path to the folder |
| searchPattern | can be used to restrict the result to files and folders matching this pattern |
Implements Joutsen.IO.Filesystem.
| File Joutsen.IO.LocalFilesystem.MoveFile | ( | FilesystemPath | sourcePath, |
| FilesystemPath | destinationPath | ||
| ) |
Moves a file to a different location.
| sourcePath | the path to move te file from |
| destinationPath | the path to move the file to |
Implements Joutsen.IO.Filesystem.
| File Joutsen.IO.LocalFilesystem.MoveFile | ( | string | sourcePath, |
| string | destinationPath | ||
| ) |
Moves a file to a different location.
| sourcePath | the path to move te file from |
| destinationPath | the path to move the file to |
Implements Joutsen.IO.Filesystem.
| Folder Joutsen.IO.LocalFilesystem.MoveFolder | ( | FilesystemPath | sourcePath, |
| FilesystemPath | destinationPath, | ||
| bool | keepFolder = false |
||
| ) |
Moves a folder to a different location.
| sourcePath | the path to move te folder from |
| destinationPath | the path to move the folder to |
| keepFolder | if keepFolder is false the content of the folder will be moved to the new location. If it is false the folder is moved into the folder defined by dstPath |
Implements Joutsen.IO.Filesystem.
| Folder Joutsen.IO.LocalFilesystem.MoveFolder | ( | string | sourcePath, |
| string | destinationPath, | ||
| bool | keepFolder = false |
||
| ) |
Moves a folder to a different location.
| sourcePath | the path to move te folder from |
| destinationPath | the path to move the folder to |
| keepFolder | if keepFolder is false the content of the folder will be moved to the new location. If it is false the folder is moved into the folder defined by dstPath |
Implements Joutsen.IO.Filesystem.
| bool Joutsen.IO.LocalFilesystem.PathExists | ( | string | path | ) |
Checks if the path exists on the filesystem.
| path | the path to check |
Implements Joutsen.IO.Filesystem.
| File Joutsen.IO.LocalFilesystem.ReplaceFile | ( | FilesystemPath | sourcePath, |
| FilesystemPath | destinationPath, | ||
| FilesystemPath | backupPath | ||
| ) |
Replaces the file at destinationPath with the file at sourcePath creating a backup in backupPath.
| sourcePath | the path to the source file |
| destinationPath | the path to the file that should be replaced |
| backupPath | the path to the location where the backup of the file at dstPath should be stored |
Implements Joutsen.IO.Filesystem.
| File Joutsen.IO.LocalFilesystem.ReplaceFile | ( | string | sourcePath, |
| string | destinationPath, | ||
| string | backupPath | ||
| ) |
Replaces the file at destinationPath with the file at sourcePath creating a backup in backupPath.
| sourcePath | the path to the source file |
| destinationPath | the path to the file that should be replaced |
| backupPath | the path to the location where the backup of the file at dstPath should be stored |
Implements Joutsen.IO.Filesystem.
| SCG.IEnumerable< FilesystemPath > Joutsen.IO.LocalFilesystem.WalkFolder | ( | FilesystemPath | path, |
| string | searchPattern = "*" |
||
| ) |
Walks the filesystem returning one file or folder contained in this folder at a time.
| path | the path to the folder |
| searchPattern | can be used to restrict the result to files and folders matching this pattern |
Implements Joutsen.IO.Filesystem.
| SCG.IEnumerable< FilesystemPath > Joutsen.IO.LocalFilesystem.WalkFolder | ( | string | path, |
| string | searchPattern = "*" |
||
| ) |
Walks the filesystem returning one file or folder contained in this folder at a time.
| path | the path to the folder |
| searchPattern | can be used to restrict the result to files and folders matching this pattern |
Implements Joutsen.IO.Filesystem.