pub trait GraphView: Sized + Send {
type Stream: Send + Unpin + Stream<Item = Arc<Triple>>;
type Filter<T: TripleFilter + Send + Sync + Unpin>: GraphView;
type Matches<'g>: GraphView;
type Describe<'g>: GraphView;
type SubjectStream<'g>: Send + Unpin + Stream<Item = Arc<Term>>;
type PredicateStream<'g>: Send + Unpin + Stream<Item = Arc<Term>>;
type ObjectStream<'g>: Send + Unpin + Stream<Item = Arc<Term>>;
Show 15 methods
// Required methods
fn stream(
self,
) -> impl Future<Output = Result<Self::Stream, GraphError>> + Send;
fn filter<F>(
self,
filter: F,
) -> impl Future<Output = Result<Self::Filter<F>, GraphError>> + Send
where F: TripleFilter + Send + Sync + Unpin;
fn matches<'g>(
self,
subject: Option<&'g Term>,
predicate: Option<&'g Term>,
object: Option<&'g Term>,
limit: Option<usize>,
) -> impl Future<Output = Result<Self::Matches<'g>, GraphError>> + Send;
fn describe(
self,
subject: Option<&Term>,
limit: Option<usize>,
) -> impl Future<Output = Result<Self::Describe<'_>, GraphError>> + Send;
fn subjects<'g>(
self,
predicate: Option<&'g Term>,
object: Option<&'g Term>,
limit: Option<usize>,
) -> impl Future<Output = Result<Self::SubjectStream<'g>, GraphError>> + Send;
fn predicates<'g>(
self,
subject: Option<&'g Term>,
object: Option<&'g Term>,
limit: Option<usize>,
) -> impl Future<Output = Result<Self::ObjectStream<'g>, GraphError>> + Send;
fn objects<'g>(
self,
subject: Option<&'g Term>,
predicate: Option<&'g Term>,
limit: Option<usize>,
) -> impl Future<Output = Result<Self::ObjectStream<'g>, GraphError>> + Send;
// Provided methods
fn subject(
self,
predicate: Option<&Term>,
object: Option<&Term>,
) -> impl Future<Output = Result<Option<Arc<Term>>, GraphError>> + Send { ... }
fn predicate(
self,
subject: Option<&Term>,
object: Option<&Term>,
) -> impl Future<Output = Result<Option<Arc<Term>>, GraphError>> + Send { ... }
fn object(
self,
subject: Option<&Term>,
predicate: Option<&Term>,
) -> impl Future<Output = Result<Option<Arc<Term>>, GraphError>> + Send { ... }
fn contains(
self,
triple: TripleRef<'_>,
) -> impl Future<Output = Result<bool, GraphError>> + Send { ... }
fn default_triple_size_hint() -> usize { ... }
fn default_buf_size_hint() -> usize { ... }
fn triple_size_hint(&self) -> usize { ... }
fn buf_size_hint(&self) -> usize { ... }
}Required Associated Types§
type Stream: Send + Unpin + Stream<Item = Arc<Triple>>
type Filter<T: TripleFilter + Send + Sync + Unpin>: GraphView
type Matches<'g>: GraphView
type Describe<'g>: GraphView
type SubjectStream<'g>: Send + Unpin + Stream<Item = Arc<Term>>
type PredicateStream<'g>: Send + Unpin + Stream<Item = Arc<Term>>
type ObjectStream<'g>: Send + Unpin + Stream<Item = Arc<Term>>
Required Methods§
fn stream(self) -> impl Future<Output = Result<Self::Stream, GraphError>> + Send
fn filter<F>( self, filter: F, ) -> impl Future<Output = Result<Self::Filter<F>, GraphError>> + Send
fn matches<'g>( self, subject: Option<&'g Term>, predicate: Option<&'g Term>, object: Option<&'g Term>, limit: Option<usize>, ) -> impl Future<Output = Result<Self::Matches<'g>, GraphError>> + Send
fn describe( self, subject: Option<&Term>, limit: Option<usize>, ) -> impl Future<Output = Result<Self::Describe<'_>, GraphError>> + Send
fn subjects<'g>( self, predicate: Option<&'g Term>, object: Option<&'g Term>, limit: Option<usize>, ) -> impl Future<Output = Result<Self::SubjectStream<'g>, GraphError>> + Send
fn predicates<'g>( self, subject: Option<&'g Term>, object: Option<&'g Term>, limit: Option<usize>, ) -> impl Future<Output = Result<Self::ObjectStream<'g>, GraphError>> + Send
fn objects<'g>( self, subject: Option<&'g Term>, predicate: Option<&'g Term>, limit: Option<usize>, ) -> impl Future<Output = Result<Self::ObjectStream<'g>, GraphError>> + Send
Provided Methods§
fn subject( self, predicate: Option<&Term>, object: Option<&Term>, ) -> impl Future<Output = Result<Option<Arc<Term>>, GraphError>> + Send
fn predicate( self, subject: Option<&Term>, object: Option<&Term>, ) -> impl Future<Output = Result<Option<Arc<Term>>, GraphError>> + Send
fn object( self, subject: Option<&Term>, predicate: Option<&Term>, ) -> impl Future<Output = Result<Option<Arc<Term>>, GraphError>> + Send
fn contains( self, triple: TripleRef<'_>, ) -> impl Future<Output = Result<bool, GraphError>> + Send
fn default_triple_size_hint() -> usize
fn default_buf_size_hint() -> usize
fn triple_size_hint(&self) -> usize
fn buf_size_hint(&self) -> usize
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.