pub struct Quad<S = Subject, P = IriBuf, O = Object, G = GraphLabel>(pub S, pub P, pub O, pub Option<G>);
Expand description
RDF quad.
Tuple Fields
0: S
1: P
2: O
3: Option<G>
Implementations
sourceimpl<S, P, O, G> Quad<S, P, O, G>
impl<S, P, O, G> Quad<S, P, O, G>
sourcepub fn subject(&self) -> &S
pub fn subject(&self) -> &S
Returns a reference to the subject of the quad, the first component.
sourcepub fn into_subject(self) -> S
pub fn into_subject(self) -> S
Turns the quad into its subject, the first component.
sourcepub fn predicate(&self) -> &P
pub fn predicate(&self) -> &P
Returns a reference to the predicate of the quad, the second component.
sourcepub fn into_predicate(self) -> P
pub fn into_predicate(self) -> P
Turns the quad into its predicate, the second component.
sourcepub fn into_object(self) -> O
pub fn into_object(self) -> O
Turns the quad into its object, the third component.
sourcepub fn graph(&self) -> Option<&G>
pub fn graph(&self) -> Option<&G>
Returns a reference to the graph of the quad, the fourth component.
sourcepub fn into_graph(self) -> Option<G>
pub fn into_graph(self) -> Option<G>
Turns the quad into its graph, the fourth component.
pub fn into_parts(self) -> (S, P, O, Option<G>)
Trait Implementations
sourceimpl<S: RdfDisplay, P: RdfDisplay, O: RdfDisplay, G: RdfDisplay> Display for Quad<S, P, O, G>
impl<S: RdfDisplay, P: RdfDisplay, O: RdfDisplay, G: RdfDisplay> Display for Quad<S, P, O, G>
sourceimpl<S: Ord, P: Ord, O: Ord, G: Ord> Ord for Quad<S, P, O, G>
impl<S: Ord, P: Ord, O: Ord, G: Ord> Ord for Quad<S, P, O, G>
1.21.0 · sourceconst fn max(self, other: Self) -> Self
const fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
1.21.0 · sourceconst fn min(self, other: Self) -> Self
const fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
1.50.0 · sourceconst fn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
const fn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
Restrict a value to a certain interval. Read more
sourceimpl<S1: PartialEq<S2>, P1: PartialEq<P2>, O1: PartialEq<O2>, G1: PartialEq<G2>, S2, P2, O2, G2> PartialEq<Quad<S2, P2, O2, G2>> for Quad<S1, P1, O1, G1>
impl<S1: PartialEq<S2>, P1: PartialEq<P2>, O1: PartialEq<O2>, G1: PartialEq<G2>, S2, P2, O2, G2> PartialEq<Quad<S2, P2, O2, G2>> for Quad<S1, P1, O1, G1>
sourceimpl<S1: PartialOrd<S2>, P1: PartialOrd<P2>, O1: PartialOrd<O2>, G1: PartialOrd<G2>, S2, P2, O2, G2> PartialOrd<Quad<S2, P2, O2, G2>> for Quad<S1, P1, O1, G1>
impl<S1: PartialOrd<S2>, P1: PartialOrd<P2>, O1: PartialOrd<O2>, G1: PartialOrd<G2>, S2, P2, O2, G2> PartialOrd<Quad<S2, P2, O2, G2>> for Quad<S1, P1, O1, G1>
sourcefn partial_cmp(&self, other: &Quad<S2, P2, O2, G2>) -> Option<Ordering>
fn partial_cmp(&self, other: &Quad<S2, P2, O2, G2>) -> Option<Ordering>
1.0.0 · sourceconst fn le(&self, other: &Rhs) -> bool
const 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<S: Copy, P: Copy, O: Copy, G: Copy> Copy for Quad<S, P, O, G>
impl<S: Eq, P: Eq, O: Eq, G: Eq> Eq for Quad<S, P, O, G>
impl<S, P, O, G> StructuralEq for Quad<S, P, O, G>
Auto Trait Implementations
impl<S, P, O, G> RefUnwindSafe for Quad<S, P, O, G>where
G: RefUnwindSafe,
O: RefUnwindSafe,
P: RefUnwindSafe,
S: RefUnwindSafe,
impl<S, P, O, G> Send for Quad<S, P, O, G>where
G: Send,
O: Send,
P: Send,
S: Send,
impl<S, P, O, G> Sync for Quad<S, P, O, G>where
G: Sync,
O: Sync,
P: Sync,
S: Sync,
impl<S, P, O, G> Unpin for Quad<S, P, O, G>where
G: Unpin,
O: Unpin,
P: Unpin,
S: Unpin,
impl<S, P, O, G> UnwindSafe for Quad<S, P, O, G>where
G: UnwindSafe,
O: UnwindSafe,
P: UnwindSafe,
S: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more