TripleStoreQuery

Trait TripleStoreQuery 

Source
pub trait TripleStoreQuery<Id: IdType, NodeProps: Property, EdgeProps: Property>: TripleStoreError {
    type QueryResult: TripleStore<Id, NodeProps, EdgeProps>;
    type QueryResultError: Debug;

    // Required method
    fn run(
        &self,
        query: Query<Id>,
    ) -> Result<Self::QueryResult, QueryError<Self::Error, Self::QueryResultError>>;
}
Expand description

A trait for querying operations in a TripleStore.

Supports arbitrary source, predicate, and object queries, as well as lookups for properties of nodes and edges.

Required Associated Types§

Source

type QueryResult: TripleStore<Id, NodeProps, EdgeProps>

The result type of a query.

Source

type QueryResultError: Debug

Required Methods§

Source

fn run( &self, query: Query<Id>, ) -> Result<Self::QueryResult, QueryError<Self::Error, Self::QueryResultError>>

Execute a query and return the result.

Implementors§

Source§

impl<Id: IdType, NodeProps: Property + Serialize + DeserializeOwned, EdgeProps: Property + Serialize + DeserializeOwned> TripleStoreQuery<Id, NodeProps, EdgeProps> for SledTripleStore<Id, NodeProps, EdgeProps>

Source§

type QueryResult = MemTripleStore<Id, NodeProps, EdgeProps>

Source§

type QueryResultError = ()

Source§

impl<Id: IdType, NodeProps: Property, EdgeProps: Property> TripleStoreQuery<Id, NodeProps, EdgeProps> for MemTripleStore<Id, NodeProps, EdgeProps>

Source§

type QueryResult = MemTripleStore<Id, NodeProps, EdgeProps>

Source§

type QueryResultError = ()