pub struct RemoteTrackingRef(/* private fields */);Expand description
A remote-tracking ref spelling such as origin/main.
Implementations§
Source§impl RemoteTrackingRef
impl RemoteTrackingRef
Sourcepub fn new(
value: impl AsRef<str>,
) -> Result<RemoteTrackingRef, GitRemoteNameError>
pub fn new( value: impl AsRef<str>, ) -> Result<RemoteTrackingRef, GitRemoteNameError>
Creates a remote-tracking ref.
§Errors
Returns GitRemoteNameError when the ref is invalid or missing parts.
Trait Implementations§
Source§impl Clone for RemoteTrackingRef
impl Clone for RemoteTrackingRef
Source§fn clone(&self) -> RemoteTrackingRef
fn clone(&self) -> RemoteTrackingRef
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 moreSource§impl Debug for RemoteTrackingRef
impl Debug for RemoteTrackingRef
Source§impl Display for RemoteTrackingRef
impl Display for RemoteTrackingRef
Source§impl FromStr for RemoteTrackingRef
impl FromStr for RemoteTrackingRef
Source§type Err = GitRemoteNameError
type Err = GitRemoteNameError
The associated error which can be returned from parsing.
Source§fn from_str(
value: &str,
) -> Result<RemoteTrackingRef, <RemoteTrackingRef as FromStr>::Err>
fn from_str( value: &str, ) -> Result<RemoteTrackingRef, <RemoteTrackingRef as FromStr>::Err>
Parses a string
s to return a value of this type. Read moreSource§impl Hash for RemoteTrackingRef
impl Hash for RemoteTrackingRef
Source§impl Ord for RemoteTrackingRef
impl Ord for RemoteTrackingRef
Source§fn cmp(&self, other: &RemoteTrackingRef) -> Ordering
fn cmp(&self, other: &RemoteTrackingRef) -> Ordering
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
Source§impl PartialEq for RemoteTrackingRef
impl PartialEq for RemoteTrackingRef
Source§fn eq(&self, other: &RemoteTrackingRef) -> bool
fn eq(&self, other: &RemoteTrackingRef) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PartialOrd for RemoteTrackingRef
impl PartialOrd for RemoteTrackingRef
impl Eq for RemoteTrackingRef
impl StructuralPartialEq for RemoteTrackingRef
Auto Trait Implementations§
impl Freeze for RemoteTrackingRef
impl RefUnwindSafe for RemoteTrackingRef
impl Send for RemoteTrackingRef
impl Sync for RemoteTrackingRef
impl Unpin for RemoteTrackingRef
impl UnsafeUnpin for RemoteTrackingRef
impl UnwindSafe for RemoteTrackingRef
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