relm4

Trait WidgetTemplate

source
pub trait WidgetTemplate:
    Sized
    + Debug
    + AsRef<Self::Root>
    + Deref<Target = Self::Root> {
    type Root;
    type Init;

    // Required method
    fn init(init: Self::Init) -> Self;
}
Expand description

A trait that describes a widget template.

Widget templates can be created manually by implementing this trait or by using the widget_template macro.

Required Associated Types§

source

type Root

The root of the template.

source

type Init

The parameter used to initialize the template.

Required Methods§

source

fn init(init: Self::Init) -> Self

Initializes the template.

Object Safety§

This trait is not object safe.

Implementors§