Struct rdf::namespace::Namespace[][src]

pub struct Namespace { /* fields omitted */ }

Representation of a specific namespace.

Methods

impl Namespace
[src]

Namespace constructor.

Examples

use rdf::namespace::Namespace;
use rdf::uri::Uri;

let ns = Namespace::new("example".to_string(),
                        Uri::new("http://example.org/".to_string()));

Returns the prefix of the namespace.

Examples

use rdf::namespace::Namespace;
use rdf::uri::Uri;

let ns = Namespace::new("example".to_string(),
                        Uri::new("http://example.org/".to_string()));

assert_eq!(ns.prefix(), "example");

Returns the URI of the namespace.

Examples

use rdf::namespace::Namespace;
use rdf::uri::Uri;

let ns = Namespace::new("example".to_string(),
                        Uri::new("http://example.org/".to_string()));

assert_eq!(ns.uri(), &Uri::new("http://example.org/".to_string()));

Trait Implementations

impl Debug for Namespace
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl Send for Namespace

impl Sync for Namespace