# ReactiveRecord

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-reactiveui/reactive_object/struct-reactiverecord/

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

```rust
struct ReactiveRecord
```

The part of a reactive record (`ReactiveRecord`): a [`ReactiveObject`](/docs/0.5.0/api/ferroui-reactiveui/reactive_object/struct-reactiveobject/) for a type with value
equality. The notification state is not data: two parts are always equal, hash to nothing and
print nothing, so a record that derives `PartialEq`, `Eq`, `Hash` and `Debug` compares, hashes
and prints its own members only, as upstream's record does.

Deviation (DEVIATIONS.md, ReactiveUI): a clone of the part is a new part without handlers or
state, the counterpart of the copy of a record (`with`), which gets its own state upstream.

```
use ferroui_reactiveui::{reactive_object, ReactiveRecord};

#[derive(Clone, Debug, Default, PartialEq, Eq, Hash)]
struct Point {
    reactive: ReactiveRecord,
    x: i32,
}
reactive_object!(Point);

let first = Point { x: 1, ..Point::default() };
let _ = first.reactive.suppress_change_notifications();
assert_eq!(first, Point { x: 1, ..Point::default() });
assert_eq!(format!("{first:?}"), "Point { reactive: ReactiveRecord, x: 1 }");
```

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.ReactiveUI/reactive_object/reactive_record.rs#L32)

## Members

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

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

### new

```rust
fn new() -> Self
```

The part of a reactive record without handlers or state.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.ReactiveUI/reactive_object/reactive_record.rs#L38)

## 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`
- `Default`
- `Deref`
- `AsRef<ReactiveObject>`
- `Clone`
- `PartialEq`
- `Eq`
- `Hash`
- `Debug`

## Availability

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