Exemplo n.º 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);
        }
Exemplo n.º 2
0
 public static bool SetFileAttributes(string filename, UInt32 attribs)
 {
     return(PathInternal.DllImport.SetFileAttributesW(PathInternal.ConvertToUnicodePath(filename), attribs));
 }
Exemplo n.º 3
0
 public static bool Move(string source, string dest)
 {
     return(PathInternal.DllImport.MoveFileW(PathInternal.ConvertToUnicodePath(source), PathInternal.ConvertToUnicodePath(dest)));
 }
Exemplo n.º 4
0
 public static UInt32 GetFileAttributes(string filename)
 {
     return(PathInternal.DllImport.GetFileAttributesW(PathInternal.ConvertToUnicodePath(filename)));
 }