-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
21 changed files
with
183 additions
and
94 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
using Windows.Foundation; | ||
using Windows.Storage; | ||
using Windows.Storage.FileProperties; | ||
|
||
namespace Files.Filesystem.StorageItems | ||
{ | ||
class PlaceholderFile : IStorageItem | ||
{ | ||
public IAsyncAction RenameAsync(string desiredName) => throw new NotSupportedException(); | ||
public IAsyncAction RenameAsync(string desiredName, NameCollisionOption option) => throw new NotSupportedException(); | ||
public IAsyncAction DeleteAsync() => throw new NotSupportedException(); | ||
public IAsyncAction DeleteAsync(StorageDeleteOption option) => throw new NotSupportedException(); | ||
public IAsyncOperation<BasicProperties> GetBasicPropertiesAsync() => throw new NotSupportedException(); | ||
public bool IsOfType(StorageItemTypes type) => type == StorageItemTypes.File; | ||
|
||
public FileAttributes Attributes => throw new NotSupportedException(); | ||
|
||
public DateTimeOffset DateCreated => throw new NotSupportedException(); | ||
|
||
public string Name { get; } | ||
|
||
public string Path { get; } | ||
|
||
public PlaceholderFile(string path) | ||
{ | ||
Path = path; | ||
Name = System.IO.Path.GetFileName(path); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
using System; | ||
using Windows.Foundation; | ||
using Windows.Storage; | ||
using Windows.Storage.FileProperties; | ||
|
||
namespace Files.Filesystem.StorageItems | ||
{ | ||
class PlaceholderFolder : IStorageItem | ||
{ | ||
public IAsyncAction RenameAsync(string desiredName) => throw new NotSupportedException(); | ||
public IAsyncAction RenameAsync(string desiredName, NameCollisionOption option) => throw new NotSupportedException(); | ||
public IAsyncAction DeleteAsync() => throw new NotSupportedException(); | ||
public IAsyncAction DeleteAsync(StorageDeleteOption option) => throw new NotSupportedException(); | ||
public IAsyncOperation<BasicProperties> GetBasicPropertiesAsync() => throw new NotSupportedException(); | ||
public bool IsOfType(StorageItemTypes type) => type == StorageItemTypes.File; | ||
|
||
public FileAttributes Attributes => throw new NotSupportedException(); | ||
|
||
public DateTimeOffset DateCreated => throw new NotSupportedException(); | ||
|
||
public string Name { get; } | ||
|
||
public string Path { get; } | ||
|
||
public PlaceholderFolder(string path) | ||
{ | ||
Path = path; | ||
Name = System.IO.Path.GetFileName(path); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.