pub struct Bsu {
pub vm_id: Option<String>,
pub drive_name: String,
pub id: String,
pub size_bytes: usize,
pub size_gib: usize,
pub device_path: Option<String>,
}
Fields§
§vm_id: Option<String>
§drive_name: String
§id: String
§size_bytes: usize
§size_gib: usize
§device_path: Option<String>
Implementations§
Source§impl Bsu
impl Bsu
pub fn new(volume: &Volume) -> Result<Self, Box<dyn Error>>
pub fn fetch_drive(drive_name: &String) -> Result<Vec<Bsu>, Box<dyn Error>>
pub fn detach(&self) -> Result<(), Box<dyn Error>>
pub fn multiple_attach( vm_id: &String, bsus: &Vec<Bsu>, ) -> Result<(), Box<dyn Error>>
pub fn multiple_detach(bsus: &Vec<Bsu>) -> Result<(), Box<dyn Error>>
pub fn delete(&self) -> Result<(), Box<dyn Error>>
pub fn wait_state( bsu_id: &String, desired_state: &str, ) -> Result<(), Box<dyn Error>>
pub fn wait_states( bsus: &[Bsu], desired_state: &str, ) -> Result<(), Box<dyn Error>>
pub fn get_state(bsu_id: &String) -> Result<String, Box<dyn Error>>
pub fn create_gib( drive_name: &String, disk_type: &DiskType, disk_iops_per_gib: Option<usize>, disk_size_gib: usize, ) -> Result<(), Box<dyn Error>>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Bsu
impl RefUnwindSafe for Bsu
impl Send for Bsu
impl Sync for Bsu
impl Unpin for Bsu
impl UnwindSafe for Bsu
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