pub struct SqliteStorage { /* private fields */ }Expand description
SQLite backend implementation
Wraps a rusqlite Connection and implements StorageTrait using direct SQL queries to Magellan’s cfg_blocks table.
Implementations§
Source§impl SqliteStorage
impl SqliteStorage
Trait Implementations§
Source§impl Debug for SqliteStorage
impl Debug for SqliteStorage
Source§impl StorageTrait for SqliteStorage
impl StorageTrait for SqliteStorage
Source§fn get_cfg_blocks(&self, function_id: i64) -> Result<Vec<CfgBlockData>>
fn get_cfg_blocks(&self, function_id: i64) -> Result<Vec<CfgBlockData>>
Get CFG blocks for a function from SQLite backend
Queries Magellan’s cfg_blocks table for all blocks belonging to the given function_id, ordered by block ID.
§Arguments
function_id- ID of the function in graph_entities
§Returns
Ok(Vec<CfgBlockData>)- Vector of CFG block dataErr(...)- Error if query fails
§Note
- Uses prepare_cached for performance on repeated calls
- Returns empty Vec if function has no CFG blocks (not an error)
Source§fn get_entity(&self, entity_id: i64) -> Option<GraphEntity>
fn get_entity(&self, entity_id: i64) -> Option<GraphEntity>
Auto Trait Implementations§
impl !Freeze for SqliteStorage
impl !RefUnwindSafe for SqliteStorage
impl Send for SqliteStorage
impl !Sync for SqliteStorage
impl Unpin for SqliteStorage
impl UnsafeUnpin for SqliteStorage
impl !UnwindSafe for SqliteStorage
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