# DefinitionBase

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-controls/struct-definitionbase/

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

```rust
struct DefinitionBase
```

Provides the core functionality used internally by `Grid` and the column
and row definition collections.

This class is abstract: only its subclasses [`crate::ColumnDefinition`](/docs/0.5.0/api/ferroui-controls/struct-columndefinition/)
and [`crate::RowDefinition`](/docs/0.5.0/api/ferroui-controls/struct-rowdefinition/) can be created.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/definition_base.rs#L28)

## Members

- [`TYPE`](#assoc_const-type)
- [`to_ref`](#function-to_ref)
- [`shared_size_group_property`](#function-shared_size_group_property)
- [`shared_size_group`](#function-shared_size_group)
- [`set_shared_size_group`](#function-set_shared_size_group)

<a id="assoc_const-type"></a>

### TYPE

```rust
const TYPE: &'static $crate::TypeInfo
```

The runtime type of this class.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/definition_base.rs#L59)

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

### to_ref

```rust
fn to_ref(self: &Self) -> $crate::Ref<DefinitionBase>
```

Returns a strong reference to this object.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/definition_base.rs#L59)

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

### shared_size_group_property

```rust
fn shared_size_group_property() -> &'static AttachedProperty<Option<String>>
```

Defines the `SharedSizeGroup` property, which marks a column / row
definition as belonging to a group "Foo" or "Bar".

The value must satisfy the following rules:

* the string must not be empty;
* the string must consist of letters, digits and underscore ('_')
  only;
* the string must not start with a digit.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/definition_base.rs#L101)

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

### shared_size_group

```rust
fn shared_size_group(self: &Self) -> Option<String>
```

The shared size group of the definition.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/definition_base.rs#L164)

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

### set_shared_size_group

```rust
fn set_shared_size_group(self: &Self, value: Option<&str>)
```



[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/definition_base.rs#L168)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- [`DefinitionBaseImplExt`](/docs/0.5.0/api/ferroui-controls/trait-definitionbaseimplext/)
- `Borrow<T>`
- `BorrowMut<T>`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- [`Receiver`](/docs/0.5.0/api/ferroui-system/task/oneshot/struct-receiver/)
- `Any`
- [`FerroObjectImplExt`](/docs/0.5.0/api/ferroui-base/trait-ferroobjectimplext/)
- [`ClassDefaults`](/docs/0.5.0/api/ferroui-base/trait-classdefaults/)
- `ErasedDestructor`
- `IntoEither`
- `Deref`
- [`Upcast<T>`](/docs/0.5.0/api/ferroui-base/trait-upcast/)
- [`Upcast<DefinitionBase>`](/docs/0.5.0/api/ferroui-base/trait-upcast/)
- [`StaticType`](/docs/0.5.0/api/ferroui-base/trait-statictype/)
- [`ObjectType`](/docs/0.5.0/api/ferroui-base/trait-objecttype/)
- [`Subclassable<T>`](/docs/0.5.0/api/ferroui-base/trait-subclassable/)
- [`FerroObjectImpl`](/docs/0.5.0/api/ferroui-base/trait-ferroobjectimpl/)
- [`DefinitionBaseImpl`](/docs/0.5.0/api/ferroui-controls/trait-definitionbaseimpl/)
- `Drop`

## Availability

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