pub struct UltraIndex { /* private fields */ }Expand description
Ultra-fast lock-free index for quad storage
Implementations§
Source§impl UltraIndex
impl UltraIndex
Sourcepub fn insert_quad(&self, quad: &Quad) -> u64
pub fn insert_quad(&self, quad: &Quad) -> u64
Insert a quad and return its ID
Sourcepub fn bulk_insert_quads(&self, quads: &[Quad]) -> Vec<u64>
pub fn bulk_insert_quads(&self, quads: &[Quad]) -> Vec<u64>
Bulk insert multiple quads and return their IDs
Sourcepub fn find_quads(
&self,
subject: Option<&Subject>,
predicate: Option<&Predicate>,
object: Option<&Object>,
graph_name: Option<&GraphName>,
) -> Vec<Quad>
pub fn find_quads( &self, subject: Option<&Subject>, predicate: Option<&Predicate>, object: Option<&Object>, graph_name: Option<&GraphName>, ) -> Vec<Quad>
Find quads matching the given pattern
Sourcepub fn stats(&self) -> Arc<IndexStats>
pub fn stats(&self) -> Arc<IndexStats>
Get statistics for this index
Sourcepub fn memory_usage(&self) -> MemoryUsage
pub fn memory_usage(&self) -> MemoryUsage
Get memory usage information
Sourcepub fn remove_quad(&self, quad: &Quad) -> bool
pub fn remove_quad(&self, quad: &Quad) -> bool
Remove a quad by its content (basic implementation)
Sourcepub fn clear_arena(&self)
pub fn clear_arena(&self)
Clear the memory arena
Trait Implementations§
Source§impl Debug for UltraIndex
impl Debug for UltraIndex
Auto Trait Implementations§
impl !Freeze for UltraIndex
impl !RefUnwindSafe for UltraIndex
impl Send for UltraIndex
impl Sync for UltraIndex
impl Unpin for UltraIndex
impl UnsafeUnpin for UltraIndex
impl UnwindSafe for UltraIndex
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more