# ScheduledDisposable

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-reactive/disposables/struct-scheduleddisposable/

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

```rust
struct ScheduledDisposable
```

A disposable whose disposal runs on a scheduler (`ScheduledDisposable`).

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Reactive/disposables/scheduled_disposable.rs#L10)

## Members

- [`new`](#function-new)
- [`scheduler`](#function-scheduler)
- [`disposable`](#function-disposable)

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

### new

```rust
fn new(scheduler: Rc<dyn IScheduler>, disposable: Rc<dyn IDisposable>) -> Rc<Self>
```

Disposes `disposable` on `scheduler` when it is disposed.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Reactive/disposables/scheduled_disposable.rs#L18)

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

### scheduler

```rust
fn scheduler(self: &Self) -> &Rc<dyn IScheduler>
```

The scheduler the disposal runs on.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Reactive/disposables/scheduled_disposable.rs#L23)

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

### disposable

```rust
fn disposable(self: &Self) -> Rc<dyn IDisposable>
```

The disposable that is disposed (an empty one once it has been).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Reactive/disposables/scheduled_disposable.rs#L28)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- `Borrow<T>`
- `BorrowMut<T>`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- `Any`
- [`IDisposable`](/docs/0.5.0/api/ferroui-base/reactive/use-idisposable/)
- [`ICancelable`](/docs/0.5.0/api/ferroui-reactive/disposables/trait-icancelable/)

## Availability

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