Struct common::client_datastore::ClientTransaction
source · pub struct ClientTransaction { /* private fields */ }Trait Implementations
sourceimpl Transaction for ClientTransaction
impl Transaction for ClientTransaction
sourcefn create_vertex(&self, v: &Vertex) -> Result<bool, Error>
fn create_vertex(&self, v: &Vertex) -> Result<bool, Error>
Creates a new vertex. Returns whether the vertex was successfully
created - if this is false, it’s because a vertex with the same UUID
already exists. Read more
sourcefn create_vertex_from_type(&self, t: Type) -> Result<Uuid, Error>
fn create_vertex_from_type(&self, t: Type) -> Result<Uuid, Error>
Creates a new vertex with just a type specification. As opposed to
create_vertex, this is used when you do not want to manually specify
the vertex’s UUID. Returns the new vertex’s UUID. Read moresourcefn get_vertices(&self, q: &VertexQuery) -> Result<Vec<Vertex>, Error>
fn get_vertices(&self, q: &VertexQuery) -> Result<Vec<Vertex>, Error>
Gets a range of vertices specified by a query. Read more
sourcefn delete_vertices(&self, q: &VertexQuery) -> Result<(), Error>
fn delete_vertices(&self, q: &VertexQuery) -> Result<(), Error>
Deletes existing vertices specified by a query. Read more
sourcefn get_vertex_count(&self) -> Result<u64, Error>
fn get_vertex_count(&self) -> Result<u64, Error>
Gets the number of vertices in the datastore..
sourcefn create_edge(&self, e: &EdgeKey) -> Result<bool, Error>
fn create_edge(&self, e: &EdgeKey) -> Result<bool, Error>
Creates a new edge. If the edge already exists, this will update it
with a new update datetime. Returns whether the edge was successfully
created - if this is false, it’s because one of the specified vertices
is missing. Read more
sourcefn get_edges(&self, q: &EdgeQuery) -> Result<Vec<Edge>, Error>
fn get_edges(&self, q: &EdgeQuery) -> Result<Vec<Edge>, Error>
Gets a range of edges specified by a query. Read more
sourcefn delete_edges(&self, q: &EdgeQuery) -> Result<(), Error>
fn delete_edges(&self, q: &EdgeQuery) -> Result<(), Error>
Deletes a set of edges specified by a query. Read more
sourcefn get_edge_count(
&self,
id: Uuid,
type_filter: Option<&Type>,
direction: EdgeDirection
) -> Result<u64, Error>
fn get_edge_count(
&self,
id: Uuid,
type_filter: Option<&Type>,
direction: EdgeDirection
) -> Result<u64, Error>
Gets the number of edges associated with a vertex. Read more
sourcefn get_vertex_properties(
&self,
q: &VertexQuery,
name: &str
) -> Result<Vec<VertexProperty>, Error>
fn get_vertex_properties(
&self,
q: &VertexQuery,
name: &str
) -> Result<Vec<VertexProperty>, Error>
Gets vertex properties. Read more
sourcefn set_vertex_properties(
&self,
q: &VertexQuery,
name: &str,
value: &JsonValue
) -> Result<(), Error>
fn set_vertex_properties(
&self,
q: &VertexQuery,
name: &str,
value: &JsonValue
) -> Result<(), Error>
Sets a vertex properties. Read more
sourcefn delete_vertex_properties(
&self,
q: &VertexQuery,
name: &str
) -> Result<(), Error>
fn delete_vertex_properties(
&self,
q: &VertexQuery,
name: &str
) -> Result<(), Error>
Deletes vertex properties. Read more
sourcefn get_edge_properties(
&self,
q: &EdgeQuery,
name: &str
) -> Result<Vec<EdgeProperty>, Error>
fn get_edge_properties(
&self,
q: &EdgeQuery,
name: &str
) -> Result<Vec<EdgeProperty>, Error>
Gets edge properties. Read more
Auto Trait Implementations
impl !RefUnwindSafe for ClientTransaction
impl !Send for ClientTransaction
impl !Sync for ClientTransaction
impl Unpin for ClientTransaction
impl !UnwindSafe for ClientTransaction
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more