C# 클래스 withSIX.Core.Tools.FileTools

상속: IEnableLogging
파일 보기 프로젝트 열기: SIXNetworks/withSIX.Desktop

공개 프로퍼티들

프로퍼티 타입 설명
IsRunningOnMono bool

공개 메소드들

메소드 설명
CheckFile ( string path, bool checkExists = false, bool mayBeUnc = true ) : bool
ComparePathsEqualCase ( string source, string destination ) : bool
ComparePathsOsCaseSensitive ( IAbsolutePath path1, IAbsolutePath path2 ) : bool
ComparePathsOsCaseSensitive ( string path1, string path2 ) : bool
CreateBatFile ( IAbsoluteDirectoryPath path, string name, string content ) : Task
FilterPath ( FileSystemInfo info ) : string
FilterPath ( IPath info ) : string
FilterPath ( string pathName ) : string
FindParentWithName ( IAbsoluteDirectoryPath path, string key ) : IAbsoluteDirectoryPath
FindPathInParents ( string path, string key ) : string
GetDirectorySize ( IAbsoluteDirectoryPath p, string filter = null, string selector = "*.*", bool recurse = true ) : long
GetFileSize ( double size, Units unit = Units.B, string postFix = null ) : string
GetFileVersion ( string file ) : FileVersionInfo
GetFiles ( IAbsoluteDirectoryPath directory, string fileMask = "*.*", IEnumerable dirRootExclusions = null, IEnumerable fileRootExclusions = null ) : IEnumerable
GetVersion ( IAbsoluteFilePath exePath ) : System.Version
HandleDowncase ( string entry, IReadOnlyCollection excludes = null ) : void
HandleDowncaseFolder ( IAbsoluteDirectoryPath entry, IReadOnlyCollection excludes = null ) : void
IsDirectoryEmpty ( IAbsoluteDirectoryPath path ) : bool
IsPathRootedDirectlyIn ( IAbsoluteDirectoryPath path, IAbsoluteDirectoryPath root, bool mayBeEqual = false ) : bool
IsPathRootedIn ( IAbsoluteDirectoryPath path, IAbsoluteDirectoryPath root, bool mayBeEqual = false ) : bool
IsValidRootedPath ( string path, bool checkExists = false, bool mayBeUnc = false ) : bool
Lock ( string path, Func action ) : Task
MakeValidFileName ( string fileName, string ext ) : string
OpenCommandPrompt ( IAbsoluteDirectoryPath path ) : void
OpenFolderInExplorer ( IAbsoluteDirectoryPath path ) : void
OpenFolderInExplorer ( string path ) : void
OrderBySize ( IEnumerable ar, bool reverse = false ) : string[]
RemoveExtension ( string filePath, string toRemove = null ) : string
SelectInExplorer ( string path ) : void
SizePrediction ( string filePath ) : long

비공개 메소드들

메소드 설명
CleanPath ( string path ) : string
GetFullCleanPath ( string path ) : string
GetIsRunningOnMono ( ) : bool
IsSameRoot ( IAbsoluteDirectoryPath sourcePath, IAbsoluteDirectoryPath destinationPath ) : bool
MakeValidBatFileName ( string fileName ) : string

메소드 상세

CheckFile() 공개 메소드

public CheckFile ( string path, bool checkExists = false, bool mayBeUnc = true ) : bool
path string
checkExists bool
mayBeUnc bool
리턴 bool

ComparePathsEqualCase() 공개 메소드

public ComparePathsEqualCase ( string source, string destination ) : bool
source string
destination string
리턴 bool

ComparePathsOsCaseSensitive() 공개 메소드

public ComparePathsOsCaseSensitive ( IAbsolutePath path1, IAbsolutePath path2 ) : bool
path1 IAbsolutePath
path2 IAbsolutePath
리턴 bool

ComparePathsOsCaseSensitive() 공개 메소드

public ComparePathsOsCaseSensitive ( string path1, string path2 ) : bool
path1 string
path2 string
리턴 bool

CreateBatFile() 공개 메소드

public CreateBatFile ( IAbsoluteDirectoryPath path, string name, string content ) : Task
path IAbsoluteDirectoryPath
name string
content string
리턴 Task

FilterPath() 공개 메소드

public FilterPath ( FileSystemInfo info ) : string
info System.IO.FileSystemInfo
리턴 string

FilterPath() 공개 메소드

public FilterPath ( IPath info ) : string
info IPath
리턴 string

FilterPath() 공개 메소드

public FilterPath ( string pathName ) : string
pathName string
리턴 string

FindParentWithName() 공개 메소드

public FindParentWithName ( IAbsoluteDirectoryPath path, string key ) : IAbsoluteDirectoryPath
path IAbsoluteDirectoryPath
key string
리턴 IAbsoluteDirectoryPath

FindPathInParents() 공개 메소드

public FindPathInParents ( string path, string key ) : string
path string
key string
리턴 string

GetDirectorySize() 공개 메소드

public GetDirectorySize ( IAbsoluteDirectoryPath p, string filter = null, string selector = "*.*", bool recurse = true ) : long
p IAbsoluteDirectoryPath
filter string
selector string
recurse bool
리턴 long

GetFileSize() 공개 메소드

public GetFileSize ( double size, Units unit = Units.B, string postFix = null ) : string
size double
unit Units
postFix string
리턴 string

GetFileVersion() 공개 메소드

public GetFileVersion ( string file ) : FileVersionInfo
file string
리턴 System.Diagnostics.FileVersionInfo

GetFiles() 공개 메소드

public GetFiles ( IAbsoluteDirectoryPath directory, string fileMask = "*.*", IEnumerable dirRootExclusions = null, IEnumerable fileRootExclusions = null ) : IEnumerable
directory IAbsoluteDirectoryPath
fileMask string
dirRootExclusions IEnumerable
fileRootExclusions IEnumerable
리턴 IEnumerable

GetVersion() 공개 메소드

public GetVersion ( IAbsoluteFilePath exePath ) : System.Version
exePath IAbsoluteFilePath
리턴 System.Version

HandleDowncase() 공개 메소드

public HandleDowncase ( string entry, IReadOnlyCollection excludes = null ) : void
entry string
excludes IReadOnlyCollection
리턴 void

HandleDowncaseFolder() 공개 메소드

public HandleDowncaseFolder ( IAbsoluteDirectoryPath entry, IReadOnlyCollection excludes = null ) : void
entry IAbsoluteDirectoryPath
excludes IReadOnlyCollection
리턴 void

IsDirectoryEmpty() 공개 메소드

public IsDirectoryEmpty ( IAbsoluteDirectoryPath path ) : bool
path IAbsoluteDirectoryPath
리턴 bool

IsPathRootedDirectlyIn() 공개 메소드

public IsPathRootedDirectlyIn ( IAbsoluteDirectoryPath path, IAbsoluteDirectoryPath root, bool mayBeEqual = false ) : bool
path IAbsoluteDirectoryPath
root IAbsoluteDirectoryPath
mayBeEqual bool
리턴 bool

IsPathRootedIn() 공개 메소드

public IsPathRootedIn ( IAbsoluteDirectoryPath path, IAbsoluteDirectoryPath root, bool mayBeEqual = false ) : bool
path IAbsoluteDirectoryPath
root IAbsoluteDirectoryPath
mayBeEqual bool
리턴 bool

IsValidRootedPath() 공개 메소드

public IsValidRootedPath ( string path, bool checkExists = false, bool mayBeUnc = false ) : bool
path string
checkExists bool
mayBeUnc bool
리턴 bool

Lock() 공개 메소드

public Lock ( string path, Func action ) : Task
path string
action Func
리턴 Task

MakeValidFileName() 공개 메소드

public MakeValidFileName ( string fileName, string ext ) : string
fileName string
ext string
리턴 string

OpenCommandPrompt() 공개 메소드

public OpenCommandPrompt ( IAbsoluteDirectoryPath path ) : void
path IAbsoluteDirectoryPath
리턴 void

OpenFolderInExplorer() 공개 메소드

public OpenFolderInExplorer ( IAbsoluteDirectoryPath path ) : void
path IAbsoluteDirectoryPath
리턴 void

OpenFolderInExplorer() 공개 메소드

public OpenFolderInExplorer ( string path ) : void
path string
리턴 void

OrderBySize() 공개 메소드

public OrderBySize ( IEnumerable ar, bool reverse = false ) : string[]
ar IEnumerable
reverse bool
리턴 string[]

RemoveExtension() 공개 메소드

public RemoveExtension ( string filePath, string toRemove = null ) : string
filePath string
toRemove string
리턴 string

SelectInExplorer() 공개 메소드

public SelectInExplorer ( string path ) : void
path string
리턴 void

SizePrediction() 공개 메소드

public SizePrediction ( string filePath ) : long
filePath string
리턴 long

프로퍼티 상세

IsRunningOnMono 공개적으로 정적으로 프로퍼티

public static bool IsRunningOnMono
리턴 bool