Skip to content

Applies to

net10.0-android36.0

Overloads

  1. protected ReactiveViewHost()

  2. protected ReactiveViewHost(Context ctx, int layoutId, ViewGroup parent)

  3. protected ReactiveViewHost(Context ctx, int layoutId, ViewGroup parent, bool attachToRoot)

  4. protected ReactiveViewHost(Context ctx, int layoutId, ViewGroup parent, bool attachToRoot, Action<ReactiveViewHost<TViewModel>, View> bind)

1. Overload

protected ReactiveViewHost()

View source

Summary: Initializes a new instance of the ReactiveViewHost class.

Remarks

This constructor performs no inflation or wiring and is AOT-safe. Derived types may assign View manually.

2. Overload

protected ReactiveViewHost(Context ctx, int layoutId, ViewGroup parent)

View source

Summary: Initializes a new instance of the ReactiveViewHost class by inflating a layout resource.

Parameters

NameTypeDescription
ctxContextThe Android context.
layoutIdintThe layout resource identifier.
parentViewGroupThe parent view group.

Remarks

        This constructor is fully AOT- and trimming-safe and performs no reflection-based auto-wireup.
        The inflated view is not attached to the parent.

3. Overload

protected ReactiveViewHost(Context ctx, int layoutId, ViewGroup parent, bool attachToRoot)

View source

Summary: Initializes a new instance of the ReactiveViewHost class by inflating a layout resource.

Parameters

NameTypeDescription
ctxContextThe Android context.
layoutIdintThe layout resource identifier.
parentViewGroupThe parent view group.
attachToRootboolWhether to attach the inflated view to the parent.

Remarks

        This constructor is fully AOT- and trimming-safe and performs no reflection-based auto-wireup.

4. Overload

protected ReactiveViewHost(Context ctx, int layoutId, ViewGroup parent, bool attachToRoot, Action<ReactiveViewHost<TViewModel>, View> bind)

View source

Summary: Initializes a new instance of the ReactiveViewHost class by inflating a layout resource and invoking an explicit, AOT-safe binder callback.

Parameters

NameTypeDescription
ctxContextThe Android context.
layoutIdintThe layout resource identifier.
parentViewGroupThe parent view group.
attachToRootboolWhether to attach the inflated view to the parent.
bindAction, View>A callback responsible for explicitly wiring child views to the host.

Remarks

        This constructor is fully AOT-safe and avoids reflection entirely.

Exceptions

TypeCondition
System.ArgumentNullExceptionThrown when bind is null.