StorageProvider StorageProvider StorageProvider StorageProvider Class

Definition

Contains info about the service that stores files and folders. Files and folders may be stored either by the local file system or by a remote service like Microsoft OneDrive.

public : sealed class StorageProvider : IStorageProvider
public sealed class StorageProvider : IStorageProvider
Public NotInheritable Class StorageProvider Implements IStorageProvider
// This class does not provide a public constructor.
Attributes
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)

Remarks

For example, if a file or folder is stored on Microsoft OneDrive, StorageProvider will contain a display name, id, and thumbnail for Microsoft OneDrive.

Typically, you access StorageProvider objects as the result of calls to asynchronous methods and functions.

Properties

DisplayName DisplayName DisplayName DisplayName

Gets a user-friendly name for the current provider of files and folders.

public : Platform::String DisplayName { get; }
public string DisplayName { get; }
Public ReadOnly Property DisplayName As string
var string = storageProvider.displayName;
Value
Platform::String string string string

The user-friendly name for the provider. This name is localized to the current system locale.

Id Id Id Id

Gets an identifier for the current provider of files and folders.

public : Platform::String Id { get; }
public string Id { get; }
Public ReadOnly Property Id As string
var string = storageProvider.id;
Value
Platform::String string string string

The identifier for the provider.

Remarks

The ID can be Local, Network, or OneDrive depending on your provider.

Methods

IsPropertySupportedForPartialFileAsync(String) IsPropertySupportedForPartialFileAsync(String) IsPropertySupportedForPartialFileAsync(String) IsPropertySupportedForPartialFileAsync(String)

Determines if a property is supported by a cloud storage provider.

public : IAsyncOperation<Platform::Boolean> IsPropertySupportedForPartialFileAsync(Platform::String propertyCanonicalName)
public IAsyncOperation<bool> IsPropertySupportedForPartialFileAsync(String propertyCanonicalName)
Public Function IsPropertySupportedForPartialFileAsync(propertyCanonicalName As String) As IAsyncOperation( Of bool )
var iAsyncOperation = storageProvider.isPropertySupportedForPartialFileAsync(propertyCanonicalName);
Parameters
propertyCanonicalName
Platform::String String String String

The name of the property. E.g., "System.Photo.DateTaken" or "System.Music.Artist"

Returns

True if the property is supported by the cloud storage provider; False otherwise

Additional features and requirements
Device family
Windows 10 Fall Creators Update (introduced v10.0.16299.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v5)
See Also