#[non_exhaustive]pub enum LimitExceeded {
RenderPixels {
width: u32,
height: u32,
allowed: u64,
},
Time {
budget: Duration,
during: Operation,
page: Option<PageIndex>,
},
Stopped {
during: Operation,
page: Option<PageIndex>,
},
}Expand description
A caller-set ceiling was hit. The error a render or an open answers when
a Limits field that defaults to off was set and exceeded.
Distinct from the parser’s own caps, which are damage tolerance and answer with a diagnostic or a truncated value: these are the host’s, and the host asked to be told. The message names the cap and what would satisfy it.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
RenderPixels
A render target of width × height pixels has more than
Limits::max_render_pixels allows.
Fields
Time
Limits::deadline passed while during was under way.
Fields
Stopped
Limits::deadline was raised by Deadline::stop while during
was under way.
Implementations§
Source§impl LimitExceeded
impl LimitExceeded
Sourcepub fn on_page(self, page: PageIndex) -> LimitExceeded
pub fn on_page(self, page: PageIndex) -> LimitExceeded
The same error naming page, for the caller who knows which page the
engine below it was working on. Only LimitExceeded::Time has a
page; the pixel cap already names its size.
Trait Implementations§
Source§impl Clone for LimitExceeded
impl Clone for LimitExceeded
Source§fn clone(&self) -> LimitExceeded
fn clone(&self) -> LimitExceeded
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for LimitExceeded
Source§impl Debug for LimitExceeded
impl Debug for LimitExceeded
Source§impl Display for LimitExceeded
impl Display for LimitExceeded
impl Eq for LimitExceeded
Source§impl Error for LimitExceeded
impl Error for LimitExceeded
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()