pub struct RamdiskClientBuilder { /* private fields */ }
Expand description
A type to help construct a [RamdeviceClient
] optionally from a VMO.
Implementations§
Source§impl RamdiskClientBuilder
impl RamdiskClientBuilder
Sourcepub fn new_with_vmo(vmo: Vmo, block_size: Option<u64>) -> Self
pub fn new_with_vmo(vmo: Vmo, block_size: Option<u64>) -> Self
Create a new ramdisk builder with a vmo
Sourcepub fn dev_root(self, dev_root: DirectoryProxy) -> Self
pub fn dev_root(self, dev_root: DirectoryProxy) -> Self
Use the given directory as “/dev” instead of opening “/dev” from the environment.
Sourcepub fn guid(self, guid: [u8; 16]) -> Self
pub fn guid(self, guid: [u8; 16]) -> Self
Initialize the ramdisk with the given GUID, which can be queried from the ramdisk instance.
Sourcepub fn ramdisk_service(self, service: DirectoryProxy) -> Self
pub fn ramdisk_service(self, service: DirectoryProxy) -> Self
Specifies the ramdisk service.
Sourcepub fn publish(self) -> Self
pub fn publish(self) -> Self
Publish this ramdisk as a fuchsia.hardware.block.volume.Service service.
Sourcepub async fn build(self) -> Result<RamdiskClient, Error>
pub async fn build(self) -> Result<RamdiskClient, Error>
Create the ramdisk.
Auto Trait Implementations§
impl Freeze for RamdiskClientBuilder
impl !RefUnwindSafe for RamdiskClientBuilder
impl Send for RamdiskClientBuilder
impl Sync for RamdiskClientBuilder
impl Unpin for RamdiskClientBuilder
impl !UnwindSafe for RamdiskClientBuilder
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