public static class QuickIO
Provides static methods for files and directories.
CreateDirectory(String fullName, Boolean recursive)
Creates a new directory. If recursive is false, the parent directory must exist.
public static void CreateDirectory(String fullName, Boolean recursive)
Parameters
fullName
StringThe path to the directory.
recursive
BooleanIf recursive is false, the parent directory must exist.
Exceptions
PathAlreadyExistsException
Path already exists.
DirectoryNotEmptyException
The directory is not empty.
CreateDirectoryAsync(String fullName, Boolean recursive)
Creates a new directory. If recursive is false, the parent directory must exist.
public static Task CreateDirectoryAsync(String fullName, Boolean recursive)
Parameters
fullName
StringThe path to the directory.
recursive
BooleanIf recursive is false, the parent directory must exist.
Exceptions
PathAlreadyExistsException
Path already exists.
DirectoryNotEmptyException
The directory is not empty.
CreateFile(String fullName, FileAccess fileAccess, FileShare fileShare, FileMode fileMode, FileAttributes fileAttributes)
Creates a new file.
public static void CreateFile(String fullName, FileAccess fileAccess, FileShare fileShare, FileMode fileMode, FileAttributes fileAttributes)
Parameters
fullName
StringThe path to the file.
fileAccess
FileAccessFileAccess - default Write
fileShare
FileSharefileMode
FileModeFileMode - default Create
fileAttributes
FileAttributesFileAttributes - default 0 (none)
Exceptions
PathAlreadyExistsException
The specified path already exists.
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
CreateFileAsync(String fullName, FileAccess fileAccess, FileShare fileShare, FileMode fileMode, FileAttributes fileAttributes)
Creates a new file.
public static Task CreateFileAsync(String fullName, FileAccess fileAccess, FileShare fileShare, FileMode fileMode, FileAttributes fileAttributes)
Parameters
fullName
StringThe path to the file.
fileAccess
FileAccessFileAccess - default Write
fileShare
FileSharefileMode
FileModeFileMode - default Create
fileAttributes
FileAttributesFileAttributes - default 0 (none)
Exceptions
PathAlreadyExistsException
The specified path already exists.
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
DeleteDirectory(QuickIODirectoryInfo directoryInfo)
Removes a directory.
public static void DeleteDirectory(QuickIODirectoryInfo directoryInfo)
Parameters
directoryInfo
QuickIODirectoryInfoThe directory.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
DirectoryNotEmptyException
The directory is not empty.
DeleteDirectory(QuickIOPathInfo pathInfo)
Removes a directory.
public static void DeleteDirectory(QuickIOPathInfo pathInfo)
Parameters
pathInfo
QuickIOPathInfoThe path of the directory.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
DirectoryNotEmptyException
The directory is not empty.
DeleteDirectory(String fullName)
Removes a directory.
public static void DeleteDirectory(String fullName)
Parameters
fullName
StringThe path to the directory.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
DirectoryNotEmptyException
The directory is not empty.
DeleteDirectoryAsync(QuickIODirectoryInfo directoryInfo)
Removes a directory.
public static Task DeleteDirectoryAsync(QuickIODirectoryInfo directoryInfo)
Parameters
directoryInfo
QuickIODirectoryInfoThe directory.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
DirectoryNotEmptyException
The directory is not empty.
DeleteDirectoryAsync(QuickIOPathInfo pathInfo)
Removes a directory.
public static Task DeleteDirectoryAsync(QuickIOPathInfo pathInfo)
Parameters
pathInfo
QuickIOPathInfoThe path of the directory.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
DirectoryNotEmptyException
The directory is not empty.
DeleteDirectoryAsync(String fullName)
Removes a directory.
public static Task DeleteDirectoryAsync(String fullName)
Parameters
fullName
StringThe path to the directory.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
DirectoryNotEmptyException
The directory is not empty.
DeleteFile(QuickIOFileInfo file)
Removes a file.
public static void DeleteFile(QuickIOFileInfo file)
Parameters
file
QuickIOFileInfoThe file.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
FileNotFoundException
File does not exist.
DeleteFile(QuickIOPathInfo pathInfo)
Removes a file.
public static void DeleteFile(QuickIOPathInfo pathInfo)
Parameters
pathInfo
QuickIOPathInfoThe file.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
FileNotFoundException
File does not exist.
DeleteFile(String fullName)
Removes a file.
public static void DeleteFile(String fullName)
Parameters
fullName
StringThe path to the file.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
FileNotFoundException
File does not exist.
DeleteFileAsync(QuickIOFileInfo file)
Removes a file.
public static Task DeleteFileAsync(QuickIOFileInfo file)
Parameters
file
QuickIOFileInfoThe file.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
FileNotFoundException
File does not exist.
DeleteFileAsync(QuickIOPathInfo pathInfo)
Removes a file.
public static Task DeleteFileAsync(QuickIOPathInfo pathInfo)
Parameters
pathInfo
QuickIOPathInfoThe file.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
FileNotFoundException
File does not exist.
DeleteFileAsync(String fullName)
Removes a file.
public static Task DeleteFileAsync(String fullName)
Parameters
fullName
StringThe path to the file.
Exceptions
PathNotFoundException
One or more intermediate directories do not exist; this function will only create the final directory in the path.
FileNotFoundException
File does not exist.
DirectoryExists(QuickIOPathInfo pathInfo)
Checks whether a directory exists
public static Boolean DirectoryExists(QuickIOPathInfo pathInfo)
Parameters
pathInfo
QuickIOPathInfoDirectory path to verify
Exceptions
UnmatchedFileSystemEntryTypeException
Searched for directory but found file.
InvalidPathException
Path is invalid.
DirectoryExists(String path)
Checks whether a directory exists
public static Boolean DirectoryExists(String path)
Parameters
path
StringDirectory path to verify
Exceptions
UnmatchedFileSystemEntryTypeException
Searched for directory but found file.
InvalidPathException
Path is invalid.
DirectoryExistsAsync(QuickIOPathInfo pathInfo)
Checks whether a directory exists
public static Task<Boolean> DirectoryExistsAsync(QuickIOPathInfo pathInfo)
Parameters
pathInfo
QuickIOPathInfoDirectory path to verify
Exceptions
UnmatchedFileSystemEntryTypeException
Searched for directory but found file.
InvalidPathException
Path is invalid.
DirectoryExistsAsync(String path)
Checks whether a directory exists
public static Task<Boolean> DirectoryExistsAsync(String path)
Parameters
path
StringDirectory path to verify
Exceptions
UnmatchedFileSystemEntryTypeException
Searched for directory but found file.
InvalidPathException
Path is invalid.
EnumerateDirectories(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Returns a directory list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<QuickIODirectoryInfo> EnumerateDirectories(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Parameters
directoryInfo
QuickIODirectoryInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory list from the current directory
EnumerateDirectories(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Returns a directory list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<QuickIODirectoryInfo> EnumerateDirectories(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Parameters
pathInfo
QuickIOPathInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory list from the current directory
EnumerateDirectories(String path, String pattern, SearchOption searchOption)
Returns a directory list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<QuickIODirectoryInfo> EnumerateDirectories(String path, String pattern, SearchOption searchOption)
Parameters
path
StringRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory list from the current directory
EnumerateDirectoriesAsync(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Returns a directory list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateDirectoriesAsync(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Parameters
directoryInfo
QuickIODirectoryInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory list from the current directory
EnumerateDirectoriesAsync(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Returns a directory list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateDirectoriesAsync(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Parameters
pathInfo
QuickIOPathInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory list from the current directory
EnumerateDirectoriesAsync(String path, String pattern, SearchOption searchOption)
Returns a directory list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateDirectoriesAsync(String path, String pattern, SearchOption searchOption)
Parameters
path
StringRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory list from the current directory
EnumerateDirectoryPaths(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Returns a directory path list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<String> EnumerateDirectoryPaths(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Parameters
directoryInfo
QuickIODirectoryInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory path list from the current directory
EnumerateDirectoryPaths(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Returns a directory path list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<String> EnumerateDirectoryPaths(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Parameters
pathInfo
QuickIOPathInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory path list from the current directory
EnumerateDirectoryPaths(String path, String pattern, SearchOption searchOption)
Returns a directory path list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<String> EnumerateDirectoryPaths(String path, String pattern, SearchOption searchOption)
Parameters
path
StringRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory path list from the current directory
EnumerateDirectoryPathsAsync(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Returns a directory path list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateDirectoryPathsAsync(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Parameters
directoryInfo
QuickIODirectoryInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory path list from the current directory
EnumerateDirectoryPathsAsync(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Returns a directory path list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateDirectoryPathsAsync(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Parameters
pathInfo
QuickIOPathInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory path list from the current directory
EnumerateDirectoryPathsAsync(String path, String pattern, SearchOption searchOption)
Returns a directory path list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateDirectoryPathsAsync(String path, String pattern, SearchOption searchOption)
Parameters
path
StringRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a directory path list from the current directory
EnumerateFilePaths(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Returns a file path list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<String> EnumerateFilePaths(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Parameters
directoryInfo
QuickIODirectoryInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file path list from the current directory
EnumerateFilePaths(QuickIOPathInfo path, String pattern, SearchOption searchOption)
Returns a file path list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<String> EnumerateFilePaths(QuickIOPathInfo path, String pattern, SearchOption searchOption)
Parameters
path
QuickIOPathInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file path list from the current directory
EnumerateFilePaths(String path, String pattern, SearchOption searchOption)
Returns a file path list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<String> EnumerateFilePaths(String path, String pattern, SearchOption searchOption)
Parameters
path
StringRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file path list from the current directory
EnumerateFilePathsAsync(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Returns a file path list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateFilePathsAsync(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Parameters
directoryInfo
QuickIODirectoryInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file path list from the current directory
EnumerateFilePathsAsync(QuickIOPathInfo path, String pattern, SearchOption searchOption)
Returns a file path list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateFilePathsAsync(QuickIOPathInfo path, String pattern, SearchOption searchOption)
Parameters
path
QuickIOPathInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file path list from the current directory
EnumerateFilePathsAsync(String path, String pattern, SearchOption searchOption)
Returns a file path list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateFilePathsAsync(String path, String pattern, SearchOption searchOption)
Parameters
path
StringRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file path list from the current directory
EnumerateFiles(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Returns a file list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<QuickIOFileInfo> EnumerateFiles(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Parameters
directoryInfo
QuickIODirectoryInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file list from the current directory
EnumerateFiles(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Returns a file list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<QuickIOFileInfo> EnumerateFiles(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Parameters
pathInfo
QuickIOPathInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file list from the current directory
EnumerateFiles(String path, String pattern, SearchOption searchOption)
Returns a file list from the current directory using a value to determine whether to search subdirectories.
public static IEnumerable<QuickIOFileInfo> EnumerateFiles(String path, String pattern, SearchOption searchOption)
Parameters
path
StringRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file list from the current directory
EnumerateFilesAsync(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Returns a file list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateFilesAsync(QuickIODirectoryInfo directoryInfo, String pattern, SearchOption searchOption)
Parameters
directoryInfo
QuickIODirectoryInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file list from the current directory
EnumerateFilesAsync(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Returns a file list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateFilesAsync(QuickIOPathInfo pathInfo, String pattern, SearchOption searchOption)
Parameters
pathInfo
QuickIOPathInfoRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file list from the current directory
EnumerateFilesAsync(String path, String pattern, SearchOption searchOption)
Returns a file list from the current directory using a value to determine whether to search subdirectories.
public static Task<IEnumerable<QuickIOFileInfo>> EnumerateFilesAsync(String path, String pattern, SearchOption searchOption)
Parameters
path
StringRootpath
pattern
StringSearch pattern. Uses Win32 native filtering.
searchOption
SearchOptionOne of the enumeration values that specifies whether the search operation should include only the current directory or all subdirectories.
Returns
Returns a file list from the current directory
FileExists(QuickIOPathInfo pathInfo)
Checks whether a file exists
public static Boolean FileExists(QuickIOPathInfo pathInfo)
Parameters
pathInfo
QuickIOPathInfoFile path to check
Exceptions
UnmatchedFileSystemEntryTypeException
Searched for file but found folder.
InvalidPathException
Path is invalid.
FileExists(String path)
Checks whether a file exists
public static Boolean FileExists(String path)
Parameters
path
StringFile path to check
Exceptions
UnmatchedFileSystemEntryTypeException
Searched for file but found folder.
InvalidPathException
Path is invalid.
FileExistsAsync(QuickIOPathInfo pathInfo)
Checks whether a file exists
public static Task<Boolean> FileExistsAsync(QuickIOPathInfo pathInfo)
Parameters
pathInfo
QuickIOPathInfoFile path to check
Exceptions
UnmatchedFileSystemEntryTypeException
Searched for file but found folder.
InvalidPathException
Path is invalid.
FileExistsAsync(String path)
Checks whether a file exists
public static Task<Boolean> FileExistsAsync(String path)
Parameters
path
StringFile path to check
Exceptions
UnmatchedFileSystemEntryTypeException
Searched for file but found folder.
InvalidPathException
Path is invalid.
GetDiskInformation(String path)
Receives QuickIODiskInformation of specifies path
public static QuickIODiskInformation GetDiskInformation(String path)
Returns
QuickIODiskInformation
Remarks
See http://support.microsoft.com/kb/231497
GetDiskInformationAsync(String path)
Receives QuickIODiskInformation of specifies path
public static Task<QuickIODiskInformation> GetDiskInformationAsync(String path)
Returns
QuickIODiskInformation
Remarks
See http://support.microsoft.com/kb/231497