pub struct GitSha1ObjectId(/* private fields */);Expand description
Exact lowercase 40-hex Git SHA-1 object identifier.
Implementations§
Source§impl GitSha1ObjectId
impl GitSha1ObjectId
Sourcepub fn new(value: impl Into<String>) -> Result<Self, GitSnapshotError>
pub fn new(value: impl Into<String>) -> Result<Self, GitSnapshotError>
Validate and retain one GitHub-compatible SHA-1 object identifier.
§Errors
Returns GitSnapshotError::InvalidObjectId unless the value is exactly 40 lowercase
hexadecimal characters.
Trait Implementations§
Source§impl Clone for GitSha1ObjectId
impl Clone for GitSha1ObjectId
Source§impl Debug for GitSha1ObjectId
impl Debug for GitSha1ObjectId
Source§impl<'de> Deserialize<'de> for GitSha1ObjectId
impl<'de> Deserialize<'de> for GitSha1ObjectId
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
impl Eq for GitSha1ObjectId
Source§impl Ord for GitSha1ObjectId
impl Ord for GitSha1ObjectId
1.21.0 (const: unstable) · 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
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for GitSha1ObjectId
impl PartialEq for GitSha1ObjectId
Source§impl PartialOrd for GitSha1ObjectId
impl PartialOrd for GitSha1ObjectId
Source§impl Serialize for GitSha1ObjectId
impl Serialize for GitSha1ObjectId
impl StructuralPartialEq for GitSha1ObjectId
Auto Trait Implementations§
impl Freeze for GitSha1ObjectId
impl RefUnwindSafe for GitSha1ObjectId
impl Send for GitSha1ObjectId
impl Sync for GitSha1ObjectId
impl Unpin for GitSha1ObjectId
impl UnsafeUnpin for GitSha1ObjectId
impl UnwindSafe for GitSha1ObjectId
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.