# ExpanderCell

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-controls-treedatagrid/models/struct-expandercell/

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

```rust
struct ExpanderCell<M: TreeModel>
```

`ExpanderCell<TModel>`.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/TreeDataGrid/FerroUI.Controls.TreeDataGrid/models/expander_cell.rs#L14)

## Members

- [`new`](#function-new)
- [`content`](#function-content)
- [`row`](#function-row)
- [`show_expander`](#function-show_expander)
- [`is_expanded`](#function-is_expanded)
- [`set_is_expanded`](#function-set_is_expanded)

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

### new

```rust
fn new(inner: CellRef, row: Rc<dyn IExpanderRow<M>>, show_expander: Rc<ShowExpanderObservable<M>>, is_expanded: Option<Rc<dyn ICellBinding<bool>>>) -> Rc<Self>
```

The expander cell of `row` around the inner column's cell `inner`; `show_expander`
publishes whether the expander is shown, `is_expanded` the model's expansion state.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/TreeDataGrid/FerroUI.Controls.TreeDataGrid/models/expander_cell.rs#L26)

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

### content

```rust
fn content(self: &Self) -> &CellRef
```

The cell of the inner column.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/TreeDataGrid/FerroUI.Controls.TreeDataGrid/models/expander_cell.rs#L71)

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

### row

```rust
fn row(self: &Self) -> &Rc<dyn IExpanderRow<M>>
```

The row of the cell.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/TreeDataGrid/FerroUI.Controls.TreeDataGrid/models/expander_cell.rs#L76)

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

### show_expander

```rust
fn show_expander(self: &Self) -> bool
```

Whether the expander is shown.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/TreeDataGrid/FerroUI.Controls.TreeDataGrid/models/expander_cell.rs#L81)

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

### is_expanded

```rust
fn is_expanded(self: &Self) -> bool
```

Whether the row is expanded.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/TreeDataGrid/FerroUI.Controls.TreeDataGrid/models/expander_cell.rs#L86)

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

### set_is_expanded

```rust
fn set_is_expanded(self: &Self, value: bool)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/TreeDataGrid/FerroUI.Controls.TreeDataGrid/models/expander_cell.rs#L90)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- `Borrow<T>`
- `BorrowMut<T>`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- `Any`
- [`ClassDefaults`](/docs/0.5.0/api/ferroui-base/trait-classdefaults/)
- `ErasedDestructor`
- `IntoEither`
- [`INotifyPropertyChanged`](/docs/0.5.0/api/ferroui-base/data/model/use-inotifypropertychanged/)
- [`ICell`](/docs/0.5.0/api/ferroui-controls-treedatagrid/models/trait-icell/)
- [`IExpander`](/docs/0.5.0/api/ferroui-treedatagrid-core/models/trait-iexpander/)
- [`IExpanderCellPresentation`](/docs/0.5.0/api/ferroui-controls-treedatagrid/models/trait-iexpandercellpresentation/)

## Availability

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