[−][src]Struct oxigraph::model::BlankNode
An owned RDF blank node.
The common way to create a new blank node is to use the BlankNode::default
function.
It is also possible to create a blank node from a blank node identifier using the BlankNode::new
function.
The blank node identifier must be valid according to N-Triples, Turtle and SPARQL grammars.
The default string formatter is returning an N-Triples, Turtle and SPARQL compatible representation:
use oxigraph::model::BlankNode; assert_eq!( "_:a122", BlankNode::new("a122")?.to_string() );
Implementations
impl BlankNode
[src]
pub fn new(id: impl Into<String>) -> Result<Self, BlankNodeIdParseError>
[src]
Creates a blank node from a unique identifier.
The blank node identifier must be valid according to N-Triples, Turtle and SPARQL grammars.
In most cases, it is much more convenient to create a blank node using BlankNode::default()
that creates a random ID that could be easily inlined by Oxigraph stores.
pub fn new_unchecked(id: impl Into<String>) -> Self
[src]
Creates a blank node from a unique identifier without validation.
It is the caller's responsibility to ensure that id
is a valid blank node identifier
according to N-Triples, Turtle and SPARQL grammars.
new
is a safe version of this constructor and should be used for untrusted data.
pub fn new_from_unique_id(id: impl Into<u128>) -> Self
[src]
Creates a blank node from a unique numerical id
In most cases, it is much more convenient to create a blank node using BlankNode::default()
.
pub fn as_str(&self) -> &str
[src]
Returns the underlying ID of this blank node
pub fn into_string(self) -> String
[src]
Returns the underlying ID of this blank node
pub fn as_ref(&self) -> BlankNodeRef<'_>
[src]
Trait Implementations
impl Clone for BlankNode
[src]
impl Debug for BlankNode
[src]
impl Default for BlankNode
[src]
fn default() -> Self
[src]
Builds a new RDF blank node with a unique id
impl Display for BlankNode
[src]
impl Eq for BlankNode
[src]
impl<'a> From<&'a BlankNode> for BlankNodeRef<'a>
[src]
impl<'a> From<&'a BlankNode> for NamedOrBlankNodeRef<'a>
[src]
impl<'a> From<&'a BlankNode> for TermRef<'a>
[src]
impl<'a> From<&'a BlankNode> for GraphNameRef<'a>
[src]
impl From<BlankNode> for NamedOrBlankNode
[src]
impl From<BlankNode> for Term
[src]
impl From<BlankNode> for GraphName
[src]
impl<'a> From<BlankNodeRef<'a>> for BlankNode
[src]
fn from(node: BlankNodeRef<'a>) -> Self
[src]
impl Hash for BlankNode
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl PartialEq<BlankNode> for BlankNode
[src]
impl<'_> PartialEq<BlankNode> for BlankNodeRef<'_>
[src]
impl<'_> PartialEq<BlankNodeRef<'_>> for BlankNode
[src]
fn eq(&self, other: &BlankNodeRef<'_>) -> bool
[src]
#[must_use]fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
impl StructuralEq for BlankNode
[src]
impl StructuralPartialEq for BlankNode
[src]
impl TTerm for BlankNode
[src]
fn kind(&self) -> TermKind
[src]
fn value_raw(&self) -> RawValue<'_>
[src]
fn as_dyn(&self) -> &dyn TTerm
[src]
fn value(&self) -> MownStr<'_>
[src]
fn datatype(&self) -> Option<SimpleIri<'_>>
[src]
fn language(&self) -> Option<&str>
[src]
fn is_absolute(&self) -> bool
[src]
impl TryCopyTerm for BlankNode
[src]
Auto Trait Implementations
impl RefUnwindSafe for BlankNode
impl Send for BlankNode
impl Sync for BlankNode
impl Unpin for BlankNode
impl UnwindSafe for BlankNode
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> CopiableTerm for T where
T: TTerm + ?Sized,
[src]
T: TTerm + ?Sized,
fn copied<U>(&self) -> U where
U: CopyTerm,
[src]
U: CopyTerm,
fn try_copied<U>(&self) -> Result<U, <U as TryCopyTerm>::Error> where
U: TryCopyTerm,
[src]
U: TryCopyTerm,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<U> TermMatcher for U where
U: TTerm + ?Sized,
[src]
U: TTerm + ?Sized,
type Term = U
Type of TTerm
used internally by this matcher.
fn constant(&self) -> Option<&U>
[src]
fn matches<T>(&self, t: &T) -> bool where
T: TTerm + ?Sized,
[src]
T: TTerm + ?Sized,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,