pub enum Name<'repo> {
Symbol(Cow<'repo, str>),
Url(Cow<'repo, BStr>),
}
Expand description
The name of a remote, either interpreted as symbol like origin
or as url as returned by Remote::name()
.
Variants§
Symbol(Cow<'repo, str>)
A symbolic name, like origin
.
Note that it has not necessarily been validated yet.
Url(Cow<'repo, BStr>)
A url pointing to the remote host directly.
Implementations§
Trait Implementations§
source§impl<'repo> Ord for Name<'repo>
impl<'repo> Ord for Name<'repo>
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<'repo> PartialEq for Name<'repo>
impl<'repo> PartialEq for Name<'repo>
source§impl<'repo> PartialOrd for Name<'repo>
impl<'repo> PartialOrd for Name<'repo>
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<'repo> Eq for Name<'repo>
impl<'repo> StructuralEq for Name<'repo>
impl<'repo> StructuralPartialEq for Name<'repo>
Auto Trait Implementations§
impl<'repo> RefUnwindSafe for Name<'repo>
impl<'repo> Send for Name<'repo>
impl<'repo> Sync for Name<'repo>
impl<'repo> Unpin for Name<'repo>
impl<'repo> UnwindSafe for Name<'repo>
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
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more