Delen via


IStorageItem Interface

Definition

Manipulates storage items (files and folders) and their contents, and provides information about them.

Important

If you simply want to work with files and folders in your app, see the StorageFile and StorageFolder classes.

public interface class IStorageItem
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.Guid(1107798422, 51759, 17143, 189, 232, 139, 16, 69, 122, 127, 48)]
struct IStorageItem
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.Guid(1107798422, 51759, 17143, 189, 232, 139, 16, 69, 122, 127, 48)]
public interface IStorageItem
Public Interface IStorageItem
Derived
Attributes

Windows requirements

Device family
Windows 10 (introduced in 10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced in v1.0)

Properties

Attributes

Gets the attributes of a storage item.

DateCreated

Gets the date and time when the current item was created.

Name

Gets the name of the item including the file name extension if there is one.

Path

Gets the full file-system path of the item, if the item has a path.

Methods

DeleteAsync()

Deletes the current item.

DeleteAsync(StorageDeleteOption)

Deletes the current item, optionally deleting it permanently.

GetBasicPropertiesAsync()

Gets the basic properties of the current item (like a file or folder).

IsOfType(StorageItemTypes)

Determines whether the current IStorageItem matches the specified StorageItemTypes value.

RenameAsync(String, NameCollisionOption)

Renames the current item. This method also specifies what to do if an existing item in the current item's location has the same name.

RenameAsync(String)

Renames the current item.

Applies to