pub struct Driver { /* private fields */ }
Expand description

Main connection to vertigo facilities - dependencies and rendering client (the browser).

This is in fact only a box for inner generic driver. This way a web developer don’t need to worry about the specific driver used, though usually it is the BrowserDriver which is used to create a Driver.

Additionally driver struct wraps Dependencies object.

Implementations

Spawn a future - thus allowing to fire async functions in, for example, event handler. Handy when fetching resources from internet.

Create new FetchBuilder.

Gets a cookie by name

Sets a cookie under provided name

Retrieves the hash part of location URL from client (browser)

Sets the hash part of location URL from client (browser)

Set event handler upon hash location change

Make func fire every time seconds.

Gets current value of monotonic clock.

Create new RequestBuilder (more complex version of fetch)

Initiate a websocket connection. Provided callback should handle a single WebsocketMessage.

Create new reactive value in dependency graph.

Create new computed from provided value

Fire provided function in a way that all changes in dependency graph made by this function will trigger only one run of updates, just like the changes were done all at once.

Create a value that is connected to a generator, where value parameter is a starting value, and create function takes care of updating it.

See game of life example.

Create new computed value calculated using provided function.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.