Edit

Share via


ApplicationDataStorageHelper.ReadFileAsync<T>(String, T) Method

Definition

Retrieves an object from a file.

public System.Threading.Tasks.Task<T?> ReadFileAsync<T> (string filePath, T? default = default);
abstract member ReadFileAsync : string * 'T -> System.Threading.Tasks.Task<'T>
override this.ReadFileAsync : string * 'T -> System.Threading.Tasks.Task<'T>
Public Function ReadFileAsync(Of T) (filePath As String, Optional default As T = Nothing) As Task(Of T)

Type Parameters

T

Type of object retrieved.

Parameters

filePath
String

Path to the file that contains the object.

default
T

Default value of the object.

Returns

Task<T>

Waiting task until completion with the object in the file.

Implements

Applies to