コード例 #1
0
        private static bool InternalDirectoryExists(string uncPath)
        {
            int win32Error;
            var attrs = InternalQuickIO.SafeGetAttributes(uncPath, out win32Error);

            if (Equals(attrs, 0xffffffff))
            {
                return(false);
            }
            if (InternalHelpers.ContainsFileAttribute(FileAttributes.Directory, ( FileAttributes )attrs))
            {
                return(true);
            }

            throw new UnmatchedFileSystemEntryTypeException(QuickIOFileSystemEntryType.Directory, QuickIOFileSystemEntryType.File, uncPath);
        }