pub trait NetProvider:
Send
+ Sync
+ 'static {
// Required method
fn fetch(
&self,
doc_id: usize,
request: Request,
handler: Box<dyn NetHandler>,
);
// Provided method
fn is_noop(&self) -> bool { ... }
}Expand description
A type that fetches resources for a Document.
This may be over the network via http(s), via the filesystem, or some other method.
Required Methods§
Provided Methods§
Sourcefn is_noop(&self) -> bool
fn is_noop(&self) -> bool
Whether this provider is a no-op (e.g. DummyNetProvider) that will never
deliver resources. When true, callers must NOT register resources as
“pending critical” — doing so blocks painting forever, since the
completion callback never fires. Used by integrations that feed a
pre-rendered DOM and perform no sub-fetches (e.g. aginxbrowser).
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".