# IStorageFile

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-base/platform/storage/trait-istoragefile/

**trait** · [`ferroui-base`](/docs/0.5.0/api/ferroui-base/) · v0.5.0

```rust
trait IStorageFile: IStorageItem
```

Represents a file. Provides information about the file and its contents,
and ways to manipulate them.

This interface is not meant to be implemented by applications.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/platform/storage/i_storage_file.rs#L9)

## Members

- [`open_read_async`](#function-open_read_async)
- [`open_write_async`](#function-open_write_async)

<a id="function-open_read_async"></a>

### open_read_async

```rust
fn open_read_async(self: &Self) -> LocalBoxFuture<std::io::Result<Box<dyn Read>>>
```

Opens a stream for read access.

Fails (among other reasons) when access to the file is denied.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/platform/storage/i_storage_file.rs#L13)

<a id="function-open_write_async"></a>

### open_write_async

```rust
fn open_write_async(self: &Self) -> LocalBoxFuture<std::io::Result<Box<dyn Write>>>
```

Opens a stream for writing to the file.

Fails (among other reasons) when access to the file is denied.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/platform/storage/i_storage_file.rs#L18)

## Trait implementations

- [`IStorageFile`](/docs/0.5.0/api/ferroui-base/platform/storage/trait-istoragefile/)

## Availability

Extracted for `aarch64-apple-darwin`. Cargo features are listed in the [crate index](/docs/0.5.0/api/).
