Skip to main content

RxState

Struct RxState 

Source
pub struct RxState;
Expand description

The state of ReactiveUI that its objects share (RxState): the handler of the errors that no thrown_exceptions subscriber handles.

Deviation (DEVIATIONS.md, ReactiveUI): the state is per thread, as the objects that use it are (docs/porting/reactive.md, section 5.1).

Implementations§

Source§

impl RxState

Source

pub fn default_exception_handler() -> Rc<dyn IObserver<ObservableError>>

The observer that receives the errors of the objects implementing IHandleObservableErrors when nothing subscribes to their thrown_exceptions (DefaultExceptionHandler).

Unless initialize_exception_handler set another one first, it schedules on RxSchedulers::main_thread_scheduler a panic with an UnhandledErrorException that names the error, where upstream throws that exception.

Source

pub fn initialize_exception_handler( exception_handler: Rc<dyn IObserver<ObservableError>>, )

Sets the handler of default_exception_handler unless one was set or read before (InitializeExceptionHandler); the builder of the application calls it.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.