pub struct BobHarness;Expand description
Implementations§
Source§impl BobHarness
impl BobHarness
Trait Implementations§
Source§impl Clone for BobHarness
impl Clone for BobHarness
Source§fn clone(&self) -> BobHarness
fn clone(&self) -> BobHarness
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 moreSource§impl Debug for BobHarness
impl Debug for BobHarness
Source§impl Default for BobHarness
impl Default for BobHarness
Source§fn default() -> BobHarness
fn default() -> BobHarness
Returns the “default value” for a type. Read more
Source§impl Harness for BobHarness
impl Harness for BobHarness
Source§fn info(&self) -> HarnessInfo
fn info(&self) -> HarnessInfo
Static metadata for the UI.
Source§fn readiness(&self) -> HarnessReadiness
fn readiness(&self) -> HarnessReadiness
Probe availability / version / auth. May shell out; callers
should treat it as blocking and run it off the UI thread.
Source§fn install(&self, on_event: InstallCallback) -> Result<(), HarnessError>
fn install(&self, on_event: InstallCallback) -> Result<(), HarnessError>
Stream a one-time install. Harnesses that need no install
(e.g. a hosted-API adapter) return
Ok(()) immediately.Source§fn run(
&self,
request: RunRequest,
on_event: RunCallback,
) -> Result<RunHandle, HarnessError>
fn run( &self, request: RunRequest, on_event: RunCallback, ) -> Result<RunHandle, HarnessError>
Start a run, streaming events through
on_event. Returns a
handle immediately; work continues on background threads.Source§fn credential(&self) -> CredentialSpec
fn credential(&self) -> CredentialSpec
The credential this harness needs.
Source§fn login(&self, _on_event: InstallCallback) -> Result<(), HarnessError>
fn login(&self, _on_event: InstallCallback) -> Result<(), HarnessError>
Trigger the harness’s own interactive sign-in (its CLI’s OAuth),
streaming progress as
InstallEvents — the same subprocess
stream shape as install. The flow opens the
user’s browser; this blocks until the login process exits, then
Done { ok } reports success. Default: unsupported — harnesses
that Compose authenticates itself (bob, via its API key) keep it.Source§fn run_channel(
&self,
request: RunRequest,
) -> Result<(RunHandle, Receiver<RunEvent>), HarnessError>
fn run_channel( &self, request: RunRequest, ) -> Result<(RunHandle, Receiver<RunEvent>), HarnessError>
Convenience over
run for callers that want to
pull events off a channel instead of supplying a push callback.
Forwards each RunEvent into an mpsc channel and hands the
receiver back alongside the run handle, so the caller can simply
for event in rx { … } rather than re-write the
Arc::new(move |ev| tx.send(ev)) plumbing at every call site. Read moreAuto Trait Implementations§
impl Freeze for BobHarness
impl RefUnwindSafe for BobHarness
impl Send for BobHarness
impl Sync for BobHarness
impl Unpin for BobHarness
impl UnsafeUnpin for BobHarness
impl UnwindSafe for BobHarness
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