Skip to main content

PipelineManifold

Trait PipelineManifold 

Source
pub trait PipelineManifold {
    // Required method
    fn request_visual_update(&self, app: &mut App);
}
Expand description

Manages a tree of PipelineOwners.

All PipelineOwners within a tree are attached to the same PipelineManifold, which gives them access to shared functionality such as requesting a visual update (by calling request_visual_update). As such, the PipelineManifold gives the PipelineOwners access to functionality usually provided by the bindings without tying the PipelineOwners to a particular binding implementation.

The root of the PipelineOwner tree is attached to a PipelineManifold by passing the manifold to PipelineOwner::attach. Children are attached to the same PipelineManifold as their parent when they are adopted via PipelineOwner::adopt_child.

Dart’s semanticsEnabled and the listeners that report its changes wait with semantics.

Required Methods§

Source

fn request_visual_update(&self, app: &mut App)

Called by a PipelineOwner connected to this PipelineManifold when a RenderObject associated with that pipeline owner wishes to update its visual appearance.

Typical implementations of this function will schedule a task to flush the various stages of the pipeline. This function might be called multiple times in quick succession. Implementations should take care to discard duplicate calls quickly.

A PipelineOwner connected to this PipelineManifold will call its on_need_visual_update callback instead of this method if it has been configured with one (PipelineOwner::new).

See also:

  • SchedulerBinding::ensure_visual_update, which PipelineManifold implementations typically call to implement this method.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§