Enum joinery::JoinItem [−][src]
pub enum JoinItem<T, S> { Element(T), Separator(S), }
Enum representing the elements of a JoinIter
.
Variants
Element(T)
An element from the underlying iterator
Separator(S)
A separator between two elements
Methods
impl<T, S> JoinItem<T, S>
[src]
impl<T, S> JoinItem<T, S>
pub fn into<R>(self) -> R where
T: Into<R>,
S: Into<R>,
[src]
pub fn into<R>(self) -> R where
T: Into<R>,
S: Into<R>,
Convert a JoinItem
into a common type R
, in the case where both
T
and S
can be converted to R
. Unfortunately, due to potentially
conflicting implementations, we can't implement Into<R>
for JoinItem
.
Trait Implementations
impl<T: Debug, S: Debug> Debug for JoinItem<T, S>
[src]
impl<T: Debug, S: Debug> Debug for JoinItem<T, S>
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl<T: Clone, S: Clone> Clone for JoinItem<T, S>
[src]
impl<T: Clone, S: Clone> Clone for JoinItem<T, S>
fn clone(&self) -> JoinItem<T, S>
[src]
fn clone(&self) -> JoinItem<T, S>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl<T: Copy, S: Copy> Copy for JoinItem<T, S>
[src]
impl<T: Copy, S: Copy> Copy for JoinItem<T, S>
impl<T: PartialEq, S: PartialEq> PartialEq for JoinItem<T, S>
[src]
impl<T: PartialEq, S: PartialEq> PartialEq for JoinItem<T, S>
fn eq(&self, other: &JoinItem<T, S>) -> bool
[src]
fn eq(&self, other: &JoinItem<T, S>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &JoinItem<T, S>) -> bool
[src]
fn ne(&self, other: &JoinItem<T, S>) -> bool
This method tests for !=
.
impl<T: Eq, S: Eq> Eq for JoinItem<T, S>
[src]
impl<T: Eq, S: Eq> Eq for JoinItem<T, S>
impl<T: Hash, S: Hash> Hash for JoinItem<T, S>
[src]
impl<T: Hash, S: Hash> Hash for JoinItem<T, S>
fn hash<__HTS: Hasher>(&self, state: &mut __HTS)
[src]
fn hash<__HTS: Hasher>(&self, state: &mut __HTS)
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl<T, S, R> AsRef<R> for JoinItem<T, S> where
T: AsRef<R>,
S: AsRef<R>,
[src]
impl<T, S, R> AsRef<R> for JoinItem<T, S> where
T: AsRef<R>,
S: AsRef<R>,
Get a reference to a common type R
from a JoinItem
, in the case where
both T
and S
implement AsRef<R>
impl<T: Display, S: Display> Display for JoinItem<T, S>
[src]
impl<T: Display, S: Display> Display for JoinItem<T, S>