# CalendarDatePickerAutomationPeer

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-controls/automation/peers/struct-calendardatepickerautomationpeer/

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

```rust
struct CalendarDatePickerAutomationPeer
```

An automation peer which represents a [`CalendarDatePicker`](/docs/0.5.0/api/ferroui-controls/struct-calendardatepicker/).

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L17)

## Members

- [`TYPE`](#assoc_const-type)
- [`to_ref`](#function-to_ref)
- [`construct`](#function-construct)
- [`new`](#function-new)
- [`owner`](#function-owner)
- [`expand_collapse_state`](#function-expand_collapse_state)
- [`shows_menu`](#function-shows_menu)
- [`is_read_only`](#function-is_read_only)
- [`value`](#function-value)
- [`invoke`](#function-invoke)
- [`expand`](#function-expand)
- [`collapse`](#function-collapse)
- [`set_value`](#function-set_value)

<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/automation/peers/calendar_date_picker_automation_peer.rs#L21)

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

### to_ref

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

Returns a strong reference to this object.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L21)

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

### construct

```rust
fn construct(owner: &CalendarDatePicker) -> Self
```

Creates the class data; see `ferroui_base::FerroObject::construct`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L115)

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

### new

```rust
fn new(owner: &CalendarDatePicker) -> Ref<Self>
```

Initializes a new peer of `owner`.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L120)

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

### owner

```rust
fn owner(self: &Self) -> Ref<CalendarDatePicker>
```

Gets the owning calendar date picker.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L125)

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

### expand_collapse_state

```rust
fn expand_collapse_state(self: &Self) -> ExpandCollapseState
```

Gets the state, expanded or collapsed, of the drop-down of the date
picker (the expand/collapse provider contract).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L131)

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

### shows_menu

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

Gets a value indicating whether expanding the date picker shows a
menu (the expand/collapse provider contract).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L137)

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

### is_read_only

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

Gets a value that indicates whether the value is read-only (the
value provider contract).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L143)

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

### value

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

Gets the text of the date picker (the value provider contract).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L148)

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

### invoke

```rust
fn invoke(self: &Self) -> Result<(), ElementNotEnabledError>
```

Opens the drop-down (the invoke provider contract).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L153)

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

### expand

```rust
fn expand(self: &Self) -> Result<(), AutomationError>
```

Opens the drop-down (the expand/collapse provider contract).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L160)

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

### collapse

```rust
fn collapse(self: &Self) -> Result<(), AutomationError>
```

Closes the drop-down (the expand/collapse provider contract).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L166)

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

### set_value

```rust
fn set_value(self: &Self, value: Option<&str>) -> Result<(), ElementNotEnabledError>
```

Sets the text of the date picker (the value provider contract).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Controls/automation/peers/calendar_date_picker_automation_peer.rs#L172)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- [`AutomationPeerImplExt`](/docs/0.5.0/api/ferroui-controls/automation/peers/trait-automationpeerimplext/)
- [`ControlAutomationPeerImplExt`](/docs/0.5.0/api/ferroui-controls/automation/peers/trait-controlautomationpeerimplext/)
- `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<CalendarDatePickerAutomationPeer>`](/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/)
- [`ControlAutomationPeerImpl`](/docs/0.5.0/api/ferroui-controls/automation/peers/trait-controlautomationpeerimpl/)
- [`AutomationPeerImpl`](/docs/0.5.0/api/ferroui-controls/automation/peers/trait-automationpeerimpl/)

## Availability

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