[][src]Struct wasccgraph_actor::graph::GraphHostBinding

pub struct GraphHostBinding { /* fields omitted */ }

Implementations

impl GraphHostBinding[src]

pub fn query<T: FromTable>(&self, query: &str) -> Result<T, Box<dyn Error>>[src]

Executes a query against the host graph. For this provider, we assume the query is a Cypher query but it could be Gremlin or GraphQL, etc, depending on the capability provider satisfying wascc:graphdb. This can be used to perform mutations if you also return data from the mutation query

pub fn query_with_statistics<T: FromTable>(
    &self,
    query: &str
) -> Result<(T, Statistics), Box<dyn Error>>
[src]

The same as query, but returns statistics from the query like execution time and nodes/relations affected, etc.

pub fn mutate(&mut self, query: &str) -> Result<(), Box<dyn Error>>[src]

Executes the given query without returning any values

If you want to mutate the graph and retrieve values using one query, use query instead.

pub fn mutate_with_statistics(
    &mut self,
    query: &str
) -> Result<Statistics, Box<dyn Error>>
[src]

Same as mutate, but returns statistics about the query.

pub fn delete(self) -> Result<(), Box<dyn Error>>[src]

Deletes the entire graph from the database.

This is a potentially very destructive function. Use with care.

pub fn name(&self) -> &str[src]

Returns the name of the graph

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.