Example #1
0
        protected override Result DoOpenDirectory(out IDirectory directory, U8Span path, OpenDirectoryMode mode)
        {
            directory = default;

            Result rc = BaseFileSystem.OpenDirectory(out IDirectory baseDir, path, mode);

            if (rc.IsFailure())
            {
                return(rc);
            }

            directory = new AesXtsDirectory(BaseFileSystem, baseDir, path.ToU8String(), mode);
            return(Result.Success);
        }
Example #2
0
        protected override Result OpenDirectoryImpl(out IDirectory directory, string path, OpenDirectoryMode mode)
        {
            directory = default;
            path      = PathTools.Normalize(path);

            Result rc = BaseFileSystem.OpenDirectory(out IDirectory baseDir, path, mode);

            if (rc.IsFailure())
            {
                return(rc);
            }

            directory = new AesXtsDirectory(BaseFileSystem, baseDir, path, mode);
            return(Result.Success);
        }