# SetterViewModelRef

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-diagnostics/diagnostics/view_models/enum-setterviewmodelref/

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

```rust
enum SetterViewModelRef
```

The shared handle of a setter view model of any of the classes `SetterViewModel`,
`BindingSetterViewModel` and `ResourceSetterViewModel`: a reference typed with the base
class. It dereferences to the base class and dispatches the virtual member.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Diagnostics/diagnostics/view_models/setter_view_model.rs#L138)

## Members

- [`Setter`](#variant-setter)
- [`Binding`](#variant-binding)
- [`Resource`](#variant-resource)
- [`copy_value`](#function-copy_value)
- [`boxed`](#function-boxed)
- [`from_boxed`](#function-from_boxed)

<a id="variant-setter"></a>

### Setter

```rust
Setter(std::rc::Rc<SetterViewModel>)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Diagnostics/diagnostics/view_models/setter_view_model.rs#L139)

<a id="variant-binding"></a>

### Binding

```rust
Binding(std::rc::Rc<super::BindingSetterViewModel>)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Diagnostics/diagnostics/view_models/setter_view_model.rs#L140)

<a id="variant-resource"></a>

### Resource

```rust
Resource(std::rc::Rc<super::ResourceSetterViewModel>)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Diagnostics/diagnostics/view_models/setter_view_model.rs#L141)

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

### copy_value

```rust
fn copy_value(self: &Self)
```

The virtual `CopyValue`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Diagnostics/diagnostics/view_models/setter_view_model.rs#L164)

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

### boxed

```rust
fn boxed(self: &Self) -> BoxedValue
```

The setter as an untyped value of its class (what a list of the setters holds for the
data templates that choose by the class).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Diagnostics/diagnostics/view_models/setter_view_model.rs#L174)

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

### from_boxed

```rust
fn from_boxed(value: &BoxedValue) -> Option<Self>
```

The setter of an untyped value of one of the classes (`DataContext as SetterViewModel`).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Diagnostics/diagnostics/view_models/setter_view_model.rs#L183)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- `Borrow<T>`
- `BorrowMut<T>`
- `CloneToUninit`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- [`Receiver`](/docs/0.5.0/api/ferroui-system/task/oneshot/struct-receiver/)
- `Any`
- `ToOwned`
- [`PropertyValue`](/docs/0.5.0/api/ferroui-base/trait-propertyvalue/)
- [`AnyValue`](/docs/0.5.0/api/ferroui-base/trait-anyvalue/)
- [`ClassDefaults`](/docs/0.5.0/api/ferroui-base/trait-classdefaults/)
- `ErasedDestructor`
- `IntoEither`
- [`TreeModel`](/docs/0.5.0/api/ferroui-treedatagrid-core/accessor/trait-treemodel/)
- `Clone`
- `PartialEq`
- `Deref`

## Availability

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