pub type MediaChangeFn = Arc<dyn Fn(String, ReadyMedia) -> MediaChangeFuture + Send + Sync>;Expand description
Called when an operator sets the loaded media from the web UI, before the change is written to the config.
Returning Err(reason) refuses the change: the config is left untouched and
the page shows the reason. That matters because the consumer is the only
party that knows whether the device will accept it — a printer whose media
is described by an RFID tag, for instance, must not have that tag’s geometry
contradicted by a hand-entered size.
Given the printer’s logical name and the requested media.
Aliased Type§
pub struct MediaChangeFn { /* private fields */ }