dsplaisted / PCLStorage

PCL Storage - Portable Storage APIs
Microsoft Public License
305 stars 95 forks source link

Feature Request: Add IFileSystem.RemoveableStorage #36

Open jasells opened 8 years ago

jasells commented 8 years ago

1) It looks like this project is a little dormant at the moment. I saw reference to System.IO.File being made portable... until then I need a portable solution, and this looks pretty good, except for accessing removable storage (SD cards, etc).

I don't see anything for that in the current API, so if it exists, please point me in the right direction.

Assuming it would be a new feature, I need access to Removable storage, and I know there isn't a real use case for iOS, but most other platforms do support it, and it would be extremely useful my more than one of my apps.

It seems like it would be a rather easy thing to add, and simply throw a NotSupportedException for iOS, even though I wouldn't expect anyone to try.

I may add it myself and send a pull request, if there are no plans or alternatives found.

dominik-weber commented 8 years ago

+1 ;) it would be quite useful if we had references to removable media on android devices (for sharing files with other apps) I'm using this function in my own FileSystemService class in the mean time:

public IFolder ShareFolder
{
    get
    {
        if (shareFolder == null)
        {
            var dir = MainActivity.Instance.GetExternalFilesDir(null);
            shareFolder = new FileSystemFolder(dir.AbsolutePath);
        }

        return shareFolder;
    }
}