pub struct MobRuntime { /* private fields */ }Expand description
Live mob runtime backed by a MobHandle.
Implementations§
Source§impl MobRuntime
impl MobRuntime
pub async fn bootstrap(spec: MobBootstrapSpec) -> Result<Self, MobRuntimeError>
pub fn from_handle(handle: MobHandle) -> Self
pub fn handle(&self) -> MobHandle
pub fn agent_mob_mcp_state(&self) -> Option<Arc<MobMcpState>>
pub async fn set_baseline_member_specs(&self, specs: Vec<SpawnMemberSpec>)
pub async fn baseline_member_specs(&self) -> Vec<SpawnMemberSpec>
pub async fn read_session_history( &self, session_id_str: &str, offset: usize, limit: Option<usize>, ) -> Result<SessionHistoryPage, MobRuntimeError>
Sourcepub fn session_service(&self) -> Option<&Arc<dyn MobSessionService>>
pub fn session_service(&self) -> Option<&Arc<dyn MobSessionService>>
Access the session service this runtime was bootstrapped with, if any.
Present for MobRuntime::bootstrap(...)-produced runtimes; None for
MobRuntime::from_handle(...). HTTP handlers that need to read session
history reach through this accessor.
pub fn binary_blob_store(&self) -> Option<Arc<dyn BinaryBlobStore>>
Trait Implementations§
Source§impl Clone for MobRuntime
impl Clone for MobRuntime
Source§fn clone(&self) -> MobRuntime
fn clone(&self) -> MobRuntime
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for MobRuntime
impl !RefUnwindSafe for MobRuntime
impl Send for MobRuntime
impl Sync for MobRuntime
impl Unpin for MobRuntime
impl UnsafeUnpin for MobRuntime
impl !UnwindSafe for MobRuntime
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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