#[non_exhaustive]pub struct CallOptions {
pub deadline: Option<Duration>,
pub max_retries: Option<u32>,
pub offline: bool,
}Expand description
How patient a caller is. The default is a batch caller’s: providers’
own policies, retries and all. Set on an engine view with
Engine::with_options; views share the
cache, pacing and requests in flight.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.deadline: Option<Duration>Caps each provider’s overall deadline, retries included.
max_retries: Option<u32>Caps each provider’s retries.
offline: boolAnswers from the cache only, however old; what it lacks fails as
Error::Offline.
Implementations§
Source§impl CallOptions
impl CallOptions
Sourcepub fn interactive() -> Self
pub fn interactive() -> Self
Someone is waiting: give up on a provider within a few seconds and fall back (to the next provider, or a stale cached answer).
Trait Implementations§
Source§impl Clone for CallOptions
impl Clone for CallOptions
impl Copy for CallOptions
Source§impl Debug for CallOptions
impl Debug for CallOptions
Source§impl Default for CallOptions
impl Default for CallOptions
impl Eq for CallOptions
Source§impl PartialEq for CallOptions
impl PartialEq for CallOptions
impl StructuralPartialEq for CallOptions
Auto Trait Implementations§
impl Forget for CallOptions
impl Freeze for CallOptions
impl Move for CallOptions
impl RefUnwindSafe for CallOptions
impl Send for CallOptions
impl Sync for CallOptions
impl Unpin for CallOptions
impl UnsafeUnpin for CallOptions
impl UnwindSafe for CallOptions
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more