# DocumentContract

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-hot-reload/struct-documentcontract/

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

```rust
struct DocumentContract
```

Conservative structural contract. Expanded XML names avoid prefix-only false changes.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.HotReload/contract.rs#L122)

## Members

- [`class`](#struct_field-class)
- [`names`](#struct_field-names)
- [`data_types`](#struct_field-data_types)
- [`events`](#struct_field-events)
- [`parse`](#function-parse)

<a id="struct_field-class"></a>

### class

```rust
class: Option<String>
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.HotReload/contract.rs#L123)

<a id="struct_field-names"></a>

### names

```rust
names: Vec<(String, String, String)>
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.HotReload/contract.rs#L124)

<a id="struct_field-data_types"></a>

### data_types

```rust
data_types: Vec<String>
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.HotReload/contract.rs#L125)

<a id="struct_field-events"></a>

### events

```rust
events: Vec<(String, String)>
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.HotReload/contract.rs#L126)

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

### parse

```rust
fn parse(source: &str) -> Result<Self, ReloadError>
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.HotReload/contract.rs#L129)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- `Borrow<T>`
- `BorrowMut<T>`
- `CloneToUninit`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- `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`
- `Debug`
- `Clone`
- `StructuralPartialEq`
- `PartialEq`
- `Eq`

## Availability

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