Example #1
0
        public static bool Exists(string filename)
        {
            UInt32 attribs = PathInternal.GetFileAttributes(filename);

            return(attribs != PathInternal.DllImport.INVALID_FILE_ATTRIBUTES && (attribs & PathInternal.DllImport.FILE_ATTRIBUTE_DIRECTORY) > 0);
        }
Example #2
0
 public static bool SetFileAttributes(string filename, UInt32 attribs)
 {
     return(PathInternal.DllImport.SetFileAttributesW(PathInternal.ConvertToUnicodePath(filename), attribs));
 }
Example #3
0
 public static bool Move(string source, string dest)
 {
     return(PathInternal.DllImport.MoveFileW(PathInternal.ConvertToUnicodePath(source), PathInternal.ConvertToUnicodePath(dest)));
 }
Example #4
0
 public static UInt32 GetFileAttributes(string filename)
 {
     return(PathInternal.DllImport.GetFileAttributesW(PathInternal.ConvertToUnicodePath(filename)));
 }