NetworkStatusTrigger
struct · ferroui-xaml-interactions-custom · v0.5.0
struct NetworkStatusTrigger
A trigger that fires when the network status changes.
The availability of the network (a boolean) is the parameter of the actions.
Deviation (DEVIATIONS.md, Behaviors): the reference listens to the availability change event of
the network interfaces of .NET (NetworkChange.NetworkAvailabilityChanged) while the control
is in the visual tree. The framework has no network availability service, so the port does not
observe the system: an application that observes it reports a change with
on_network_availability_changed, which the trigger
handles while the control is in the visual tree, as the reference handles the event.
Members
TYPE
const TYPE: &'static $crate::TypeInfo
The runtime type of this class.
to_ref
fn to_ref(self: &Self) -> $crate::Ref<NetworkStatusTrigger>
Returns a strong reference to this object.
status_property
fn status_property() -> &'static StyledProperty<NetworkStatus>
Identifies the Status property.
construct
fn construct() -> Self
Creates the class data; see ferroui_base::FerroObject::construct.
new
fn new() -> Ref<Self>
Creates a trigger.
status
fn status(self: &Self) -> NetworkStatus
Gets or sets the network status to listen for.
set_status
fn set_status(self: &Self, value: NetworkStatus)
on_network_availability_changed
fn on_network_availability_changed(self: &Self, is_available: bool)
Reports a change of the availability of the network (the handler of
NetworkChange.NetworkAvailabilityChanged in the reference): unless the control is out of
the visual tree, the actions run in a job of the dispatcher when the change matches
status.
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeBorrow<T>BorrowMut<T>Into<U>From<T>TryInto<U>TryFrom<U>ReceiverAnyFerroObjectImplExtStyledElementImplExtClassDefaultsErasedDestructorIntoEitherStyledElementBehaviorImplExtDerefUpcast<T>Upcast<NetworkStatusTrigger>StaticTypeObjectTypeSubclassable<T>DefaultConstructibleFerroObjectImplStyledElementImplStyledElementBehaviorImpl
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.