pub struct ImageRunnerBuilder { /* private fields */ }Expand description
Builder for creating and running bootable images.
Implementations§
Source§impl ImageRunnerBuilder
impl ImageRunnerBuilder
Sourcepub fn with_config(self, config: Config) -> Self
pub fn with_config(self, config: Config) -> Self
Set the configuration directly.
Sourcepub fn from_cargo_metadata(self) -> Result<Self>
pub fn from_cargo_metadata(self) -> Result<Self>
Load configuration from Cargo.toml metadata.
Sourcepub fn from_config_file(self, path: impl Into<PathBuf>) -> Result<Self>
pub fn from_config_file(self, path: impl Into<PathBuf>) -> Result<Self>
Load configuration from a standalone TOML file.
Sourcepub fn executable(self, path: impl Into<PathBuf>) -> Self
pub fn executable(self, path: impl Into<PathBuf>) -> Self
Set the executable path.
Sourcepub fn workspace_root(self, path: impl Into<PathBuf>) -> Self
pub fn workspace_root(self, path: impl Into<PathBuf>) -> Self
Set the workspace root.
Sourcepub fn extra_args(self, args: Vec<String>) -> Self
pub fn extra_args(self, args: Vec<String>) -> Self
Set extra QEMU arguments from CLI passthrough (-- args).
Sourcepub fn bootloader<B: Bootloader + 'static>(self, bootloader: B) -> Self
pub fn bootloader<B: Bootloader + 'static>(self, bootloader: B) -> Self
Set a custom bootloader implementation.
Sourcepub fn no_bootloader(self) -> Self
pub fn no_bootloader(self) -> Self
Use no bootloader (direct boot).
Sourcepub fn image_builder<I: ImageBuilder + 'static>(self, builder: I) -> Self
pub fn image_builder<I: ImageBuilder + 'static>(self, builder: I) -> Self
Set a custom image builder implementation.
Sourcepub fn directory_output(self) -> Self
pub fn directory_output(self) -> Self
Output to a directory (for QEMU fat:rw:).
Sourcepub fn runner<R: Runner + 'static>(self, runner: R) -> Self
pub fn runner<R: Runner + 'static>(self, runner: R) -> Self
Set a custom runner implementation.
Sourcepub fn io_handler<H: IoHandler + 'static>(self, handler: H) -> Self
pub fn io_handler<H: IoHandler + 'static>(self, handler: H) -> Self
Set an I/O handler for serial capture/streaming.
When set, the runner will pipe QEMU’s serial output through the handler, enabling capture, pattern matching, and reactive input.
Sourcepub fn build(self) -> Result<ImageRunner>
pub fn build(self) -> Result<ImageRunner>
Build the image runner.
Sourcepub fn run_with_result(self) -> Result<RunResult>
pub fn run_with_result(self) -> Result<RunResult>
Build and immediately run, returning the full RunResult.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ImageRunnerBuilder
impl !RefUnwindSafe for ImageRunnerBuilder
impl Send for ImageRunnerBuilder
impl !Sync for ImageRunnerBuilder
impl Unpin for ImageRunnerBuilder
impl UnsafeUnpin for ImageRunnerBuilder
impl !UnwindSafe for ImageRunnerBuilder
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