diff options
| author | Bond-009 <bond.009@outlook.com> | 2020-01-08 17:52:50 +0100 |
|---|---|---|
| committer | Bond_009 <bond.009@outlook.com> | 2020-01-22 22:20:35 +0100 |
| commit | c8409d2ea1b4843bb89377b130733e61e6dc2e41 (patch) | |
| tree | 701a0d6f181c23053d9e26ab7f313d739d743e38 /MediaBrowser.MediaEncoding/BdInfo/BdInfoFileInfo.cs | |
| parent | 6eac7f0fa7e753731e3d65c0b6c0323eb730ccd8 (diff) | |
Remove FileSystem.GetStream
Diffstat (limited to 'MediaBrowser.MediaEncoding/BdInfo/BdInfoFileInfo.cs')
| -rw-r--r-- | MediaBrowser.MediaEncoding/BdInfo/BdInfoFileInfo.cs | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/MediaBrowser.MediaEncoding/BdInfo/BdInfoFileInfo.cs b/MediaBrowser.MediaEncoding/BdInfo/BdInfoFileInfo.cs index de9d7cb78..a6ff4f767 100644 --- a/MediaBrowser.MediaEncoding/BdInfo/BdInfoFileInfo.cs +++ b/MediaBrowser.MediaEncoding/BdInfo/BdInfoFileInfo.cs @@ -1,11 +1,10 @@ +using System.IO; using MediaBrowser.Model.IO; namespace MediaBrowser.MediaEncoding.BdInfo { class BdInfoFileInfo : BDInfo.IO.IFileInfo { - IFileSystem _fileSystem = null; - FileSystemMetadata _impl = null; public string Name => _impl.Name; @@ -18,18 +17,17 @@ namespace MediaBrowser.MediaEncoding.BdInfo public bool IsDir => _impl.IsDirectory; - public BdInfoFileInfo(IFileSystem fileSystem, FileSystemMetadata impl) + public BdInfoFileInfo(FileSystemMetadata impl) { - _fileSystem = fileSystem; _impl = impl; } public System.IO.Stream OpenRead() { - return _fileSystem.GetFileStream(FullName, - FileOpenMode.Open, - FileAccessMode.Read, - FileShareMode.Read); + return new FileStream(FullName, + FileMode.Open, + FileAccess.Read, + FileShare.Read); } public System.IO.StreamReader OpenText() |
