#[non_exhaustive]pub struct LineRef<'a> {
pub previous_oid: &'a BStr,
pub new_oid: &'a BStr,
pub signature: SignatureRef<'a>,
pub message: &'a BStr,
}
Expand description
A parsed ref log line.
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.previous_oid: &'a BStr
The previous object id in hexadecimal. Use LineRef::previous_oid()
to get a more usable form.
new_oid: &'a BStr
The new object id in hexadecimal. Use LineRef::new_oid()
to get a more usable form.
signature: SignatureRef<'a>
The signature of the currently configured committer.
message: &'a BStr
The message providing details about the operation performed in this log line.
Implementations§
source§impl<'a> LineRef<'a>
impl<'a> LineRef<'a>
sourcepub fn from_bytes(input: &'a [u8]) -> Result<LineRef<'a>, Error>
pub fn from_bytes(input: &'a [u8]) -> Result<LineRef<'a>, Error>
Decode a line from the given bytes which are expected to start at a hex sha.
Trait Implementations§
source§impl<'de: 'a, 'a> Deserialize<'de> for LineRef<'a>
impl<'de: 'a, 'a> Deserialize<'de> for LineRef<'a>
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl<'a> Ord for LineRef<'a>
impl<'a> Ord for LineRef<'a>
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl<'a> PartialEq for LineRef<'a>
impl<'a> PartialEq for LineRef<'a>
source§impl<'a> PartialOrd for LineRef<'a>
impl<'a> PartialOrd for LineRef<'a>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl<'a> Eq for LineRef<'a>
impl<'a> StructuralEq for LineRef<'a>
impl<'a> StructuralPartialEq for LineRef<'a>
Auto Trait Implementations§
impl<'a> RefUnwindSafe for LineRef<'a>
impl<'a> Send for LineRef<'a>
impl<'a> Sync for LineRef<'a>
impl<'a> Unpin for LineRef<'a>
impl<'a> UnwindSafe for LineRef<'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