Struct simics::api::simulator::hap_consumer::haps::CoreSimulationStoppedHap
source · pub struct CoreSimulationStoppedHap {}
Expand description
Index: exception Description: Triggered when the simulation stops. The Automatically generated struct for the HAP
Implementations§
source§impl CoreSimulationStoppedHap
impl CoreSimulationStoppedHap
sourcepub fn add_callback<F>(callback: F) -> Result<HapHandle>
pub fn add_callback<F>(callback: F) -> Result<HapHandle>
Add a callback to be called on each occurrence of this HAP. The callback may capture its environment.
§Arguments
callback
- The closure to fire as a callback. The closure will be doubly boxed. Any program state accessed inside the closure must have the static lifetime. This is not enforced by the compiler, it is up to the programmer to ensure the soundness of their callback code.
sourcepub fn add_callback_object<F>(
callback: F,
obj: *mut ConfObject,
) -> Result<HapHandle>
pub fn add_callback_object<F>( callback: F, obj: *mut ConfObject, ) -> Result<HapHandle>
Add a callback to be called on each occurrence of this HAP for a specific object. The callback may capture its environment.
§Arguments
callback
- The closure to fire as a callback. The closure will be doubly boxed. Any program state accessed inside the closure must have the static lifetime. This is not enforced by the compiler, it is up to the programmer to ensure the soundness of their callback code.obj
- The object to fire this callback for. This HAP will not trigger the callback when firing on any object other than this one.
sourcepub fn add_callback_index<F>(callback: F, index: i64) -> Result<HapHandle>
pub fn add_callback_index<F>(callback: F, index: i64) -> Result<HapHandle>
Add a callback to be called on each occurrence of this HAP for a specific index value. The callback may capture its environment.
Only HAPs which support an index may add a callback in this manner, and the index varies for each HAP. For example, the
CoreMagicInstructionHap
supports an index equal to the magic value.
§Arguments
callback
- The closure to fire as a callback. The closure will be doubly boxed. Any program state accessed inside the closure must have the static lifetime. This is not enforced by the compiler, it is up to the programmer to ensure the soundness of their callback code.index
- The index value for this HAP: Index: exception Description: Triggered when the simulation stops. The
sourcepub fn add_callback_range<F>(
callback: F,
start: i64,
end: i64,
) -> Result<HapHandle>
pub fn add_callback_range<F>( callback: F, start: i64, end: i64, ) -> Result<HapHandle>
Add a callback to be called on each occurrence of this HAP for a specific index value range. The callback may capture its environment.
Only HAPs which support an index may add a callback in this manner, and the index varies for each HAP. For example, the
CoreMagicInstructionHap
supports an index equal to the magic value.
§Arguments
callback
- The closure to fire as a callback. The closure will be doubly boxed. Any program state accessed inside the closure must have the static lifetime. This is not enforced by the compiler, it is up to the programmer to ensure the soundness of their callback code.start
- The start of the range of index values for this HAP: Index: exception Description: Triggered when the simulation stops. Theend
- The start of the range of index values for this HAP: Index: exception Description: Triggered when the simulation stops. The
sourcepub fn add_callback_object_index<F>(
callback: F,
obj: *mut ConfObject,
index: i64,
) -> Result<HapHandle>
pub fn add_callback_object_index<F>( callback: F, obj: *mut ConfObject, index: i64, ) -> Result<HapHandle>
Add a callback to be called on each occurrence of this HAP on a specific object for a specific index value. The callback may capture its environment.
Only HAPs which support an index may add a callback in this manner, and the index varies for each HAP. For example, the
CoreMagicInstructionHap
supports an index equal to the magic value.
§Arguments
callback
- The closure to fire as a callback. The closure will be doubly boxed. Any program state accessed inside the closure must have the static lifetime. This is not enforced by the compiler, it is up to the programmer to ensure the soundness of their callback code.obj
- The object to fire this callback for. This HAP will not trigger the callback when firing on any object other than this one.index
- The index value for this HAP: Index: exception Description: Triggered when the simulation stops. The
sourcepub fn add_callback_object_range<F>(
callback: F,
obj: *mut ConfObject,
start: i64,
end: i64,
) -> Result<HapHandle>
pub fn add_callback_object_range<F>( callback: F, obj: *mut ConfObject, start: i64, end: i64, ) -> Result<HapHandle>
Add a callback to be called on each occurrence of this HAP on a specific object for a specific index value range. The callback may capture its environment.
Only HAPs which support an index may add a callback in this manner, and the index varies for each HAP. For example, the
CoreMagicInstructionHap
supports an index equal to the magic value.
§Arguments
callback
- The closure to fire as a callback. The closure will be doubly boxed. Any program state accessed inside the closure must have the static lifetime. This is not enforced by the compiler, it is up to the programmer to ensure the soundness of their callback code.obj
- The object to fire this callback for. This HAP will not trigger the callback when firing on any object other than this one.start
- The start of the range of index values for this HAP: Index: exception Description: Triggered when the simulation stops. Theend
- The start of the range of index values for this HAP: Index: exception Description: Triggered when the simulation stops. The