Enum oxygengine_core::ecs::pipeline::Or
source · pub enum Or<L, R> {
Left(L),
Right(R),
Both(L, R),
}
Expand description
Holds an L
, or an R
, or both
Variants§
Implementations§
source§impl<L, R> Or<L, R>
impl<L, R> Or<L, R>
sourcepub fn new(l: Option<L>, r: Option<R>) -> Option<Or<L, R>>
pub fn new(l: Option<L>, r: Option<R>) -> Option<Or<L, R>>
Construct an Or<L, R>
if at least one argument is Some
sourcepub fn split(self) -> (Option<L>, Option<R>)
pub fn split(self) -> (Option<L>, Option<R>)
Destructure into two Option
s, where either or both are Some
Trait Implementations§
source§impl<L, R> Ord for Or<L, R>where
L: Ord,
R: Ord,
impl<L, R> Ord for Or<L, R>where L: Ord, R: Ord,
source§impl<L, R> PartialEq<Or<L, R>> for Or<L, R>where
L: PartialEq<L>,
R: PartialEq<R>,
impl<L, R> PartialEq<Or<L, R>> for Or<L, R>where L: PartialEq<L>, R: PartialEq<R>,
source§impl<L, R> PartialOrd<Or<L, R>> for Or<L, R>where
L: PartialOrd<L>,
R: PartialOrd<R>,
impl<L, R> PartialOrd<Or<L, R>> for Or<L, R>where L: PartialOrd<L>, R: PartialOrd<R>,
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<L, R> Copy for Or<L, R>where L: Copy, R: Copy,
impl<L, R> Eq for Or<L, R>where L: Eq, R: Eq,
impl<L, R> StructuralEq for Or<L, R>
impl<L, R> StructuralPartialEq for Or<L, R>
Auto Trait Implementations§
impl<L, R> RefUnwindSafe for Or<L, R>where L: RefUnwindSafe, R: RefUnwindSafe,
impl<L, R> Send for Or<L, R>where L: Send, R: Send,
impl<L, R> Sync for Or<L, R>where L: Sync, R: Sync,
impl<L, R> Unpin for Or<L, R>where L: Unpin, R: Unpin,
impl<L, R> UnwindSafe for Or<L, R>where L: UnwindSafe, R: UnwindSafe,
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 Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more