pub struct SetMemoryTarget {
pub total_mib: u64,
}Expand description
Set a memory target without waiting for guest convergence.
Fields§
§total_mib: u64Full-width wire quantity; direct construction avoids SDK input narrowing.
Implementations§
Source§impl SetMemoryTarget
impl SetMemoryTarget
Sourcepub fn new(size: impl Into<Mebibytes>) -> Self
pub fn new(size: impl Into<Mebibytes>) -> Self
Accept the SDK’s existing integer/MiB helpers and their conversion rules.
SetMemoryTarget::new(2048.mib()) uses the shared SizeExt owner. This
does not change its existing sub-MiB truncation or overflow semantics.
For full-width MiB input construct the public total_mib field directly.
Trait Implementations§
Source§impl CheckedControlRequest for SetMemoryTarget
impl CheckedControlRequest for SetMemoryTarget
Source§fn json_request(&self) -> ControlClientResult<ControlRequest>
fn json_request(&self) -> ControlClientResult<ControlRequest>
Prepare the actual legacy operation, before any connection or write.
Source§fn decode_json(&self, reply: JsonReply) -> ControlClientResult<Self::Response>
fn decode_json(&self, reply: JsonReply) -> ControlClientResult<Self::Response>
Normalize a real JSON response, preserving its original bytes on failure.
Source§impl Clone for SetMemoryTarget
impl Clone for SetMemoryTarget
Source§fn clone(&self) -> SetMemoryTarget
fn clone(&self) -> SetMemoryTarget
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 moreimpl Copy for SetMemoryTarget
Source§impl Debug for SetMemoryTarget
impl Debug for SetMemoryTarget
Source§impl Request<ControlProtocol> for SetMemoryTarget
impl Request<ControlProtocol> for SetMemoryTarget
Source§type Response = MemoryState
type Response = MemoryState
Checked operation result, independent of SDK domain behavior.
Source§type Error = ControlClientError
type Error = ControlClientError
Application error that can also retain a local transport failure.
Source§fn message(&self) -> ControlClientResult<EncodedMessage>
fn message(&self) -> ControlClientResult<EncodedMessage>
Encode the prepared request without performing I/O.
Auto Trait Implementations§
impl Freeze for SetMemoryTarget
impl RefUnwindSafe for SetMemoryTarget
impl Send for SetMemoryTarget
impl Sync for SetMemoryTarget
impl Unpin for SetMemoryTarget
impl UnsafeUnpin for SetMemoryTarget
impl UnwindSafe for SetMemoryTarget
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