pub struct OclaRuntime { /* private fields */ }Expand description
Owns the OCLA REST server task and its graceful-shutdown signal.
Implementations§
Source§impl OclaRuntime
impl OclaRuntime
Sourcepub async fn start(config: &OclaConfig) -> OclaResult<Self>
pub async fn start(config: &OclaConfig) -> OclaResult<Self>
Starts the OCLA REST API on an OS-assigned loopback port.
Sourcepub async fn stop(self) -> OclaResult<()>
pub async fn stop(self) -> OclaResult<()>
Requests graceful shutdown and waits for the REST task to finish.
Sourcepub fn is_running(&self) -> bool
pub fn is_running(&self) -> bool
Returns whether the REST server task has not finished.
Auto Trait Implementations§
impl Freeze for OclaRuntime
impl RefUnwindSafe for OclaRuntime
impl Send for OclaRuntime
impl Sync for OclaRuntime
impl Unpin for OclaRuntime
impl UnsafeUnpin for OclaRuntime
impl UnwindSafe for OclaRuntime
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
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