pub struct AnchorRefusal<'a> {
pub operation: Option<&'a str>,
pub target: &'a str,
pub anchor: &'a str,
pub path: Option<&'a str>,
}Expand description
The refused request’s own facts: which operation asked, which target it named, the anchor it sent, and where the source lives for read continuations. None of this is document text.
Fields§
§operation: Option<&'a str>Operation pointer or ID (/operations/3, an op id, …).
target: &'a strThe requested target (p15, header1.p3, …), kept verbatim: the
refusal never retargets.
anchor: &'a strThe exact literal anchor that missed or repeated.
path: Option<&'a str>Source path for read continuations. The digest always binds the bytes; without a path the argv omits the file and says so.
Implementations§
Source§impl<'a> AnchorRefusal<'a>
impl<'a> AnchorRefusal<'a>
Sourcepub fn new(target: &'a str, anchor: &'a str) -> AnchorRefusal<'a>
pub fn new(target: &'a str, anchor: &'a str) -> AnchorRefusal<'a>
The refusal facts for one operation.
Sourcepub fn with_operation(self, operation: &'a str) -> AnchorRefusal<'a>
pub fn with_operation(self, operation: &'a str) -> AnchorRefusal<'a>
Set the operation pointer.
Sourcepub fn with_path(self, path: &'a str) -> AnchorRefusal<'a>
pub fn with_path(self, path: &'a str) -> AnchorRefusal<'a>
Set the source path for read continuations.
Trait Implementations§
Source§impl<'a> Clone for AnchorRefusal<'a>
impl<'a> Clone for AnchorRefusal<'a>
Source§fn clone(&self) -> AnchorRefusal<'a>
fn clone(&self) -> AnchorRefusal<'a>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl<'a> Copy for AnchorRefusal<'a>
Auto Trait Implementations§
impl<'a> Forget for AnchorRefusal<'a>
impl<'a> Freeze for AnchorRefusal<'a>
impl<'a> Move for AnchorRefusal<'a>
impl<'a> RefUnwindSafe for AnchorRefusal<'a>
impl<'a> Send for AnchorRefusal<'a>
impl<'a> Sync for AnchorRefusal<'a>
impl<'a> Unpin for AnchorRefusal<'a>
impl<'a> UnsafeUnpin for AnchorRefusal<'a>
impl<'a> UnwindSafe for AnchorRefusal<'a>
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