-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Generalised resource manager (#340)
* add initial resource manager * add `ApplicationResourceManager` struct * update resource manager implementations, update crypto runtime extensions with the usage of new resource manager struct * refactor * fix spelling * fix * wip * update Sqlite state handling * add resource manager tests, fix issue * refactor resource manager interface * wip * update resource manager interface * add InputStreams state * fix input streams state initialization * add output streams state * add usage of output streams * refactor preopen dir state * refactor fs descriptors state * refactor resource manager api * fix deadlock issue * update docs * cleanup * fix spelling * rename resource manager to resource storage
- Loading branch information
Showing
22 changed files
with
529 additions
and
1,014 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,11 @@ | ||
//! Crypto runtime extension implementation. | ||
use self::state::{get_state, set_state}; | ||
|
||
mod bip32_ed25519; | ||
mod bip39; | ||
mod host; | ||
mod state; | ||
|
||
/// Advise Runtime Extensions of a new context | ||
pub(crate) fn new_context(ctx: &crate::runtime_context::HermesRuntimeContext) { | ||
// check whether it exist | ||
let state = get_state(); | ||
if !state.contains_key(ctx.app_name()) { | ||
set_state(ctx.app_name().clone()); | ||
} | ||
state::get_state().add_app(ctx.app_name().clone()); | ||
} |
Oops, something went wrong.