pub struct CoreVM { /* private fields */ }
Trait Implementations§
Source§impl VM for CoreVM
impl VM for CoreVM
fn new( request_headers: impl HeaderMap, options: VMOptions, ) -> Result<Self, Error>
fn get_response_head(&self) -> ResponseHead
fn notify_input(&mut self, buffer: Bytes)
fn notify_input_closed(&mut self)
fn notify_error( &mut self, error: Error, command_relationship: Option<CommandRelationship>, )
fn take_output(&mut self) -> TakeOutputResult
fn is_ready_to_execute(&self) -> Result<bool, Error>
fn is_completed(&self, handle: NotificationHandle) -> bool
fn do_progress( &mut self, any_handle: Vec<NotificationHandle>, ) -> VMResult<DoProgressResponse>
fn take_notification( &mut self, handle: NotificationHandle, ) -> VMResult<Option<Value>>
fn sys_input(&mut self) -> Result<Input, Error>
fn sys_state_get(&mut self, key: String) -> Result<NotificationHandle, Error>
fn sys_state_get_keys(&mut self) -> VMResult<NotificationHandle>
fn sys_state_set(&mut self, key: String, value: Bytes) -> Result<(), Error>
fn sys_state_clear(&mut self, key: String) -> Result<(), Error>
fn sys_state_clear_all(&mut self) -> Result<(), Error>
Source§fn sys_sleep(
&mut self,
name: String,
wake_up_time_since_unix_epoch: Duration,
now_since_unix_epoch: Option<Duration>,
) -> VMResult<NotificationHandle>
fn sys_sleep( &mut self, name: String, wake_up_time_since_unix_epoch: Duration, now_since_unix_epoch: Option<Duration>, ) -> VMResult<NotificationHandle>
Note:
now_since_unix_epoch
is only used for debugging purposesfn sys_call(&mut self, target: Target, input: Bytes) -> VMResult<CallHandle>
fn sys_send( &mut self, target: Target, input: Bytes, delay: Option<Duration>, ) -> VMResult<SendHandle>
fn sys_awakeable(&mut self) -> VMResult<(String, NotificationHandle)>
fn sys_complete_awakeable( &mut self, id: String, value: NonEmptyValue, ) -> VMResult<()>
fn create_signal_handle( &mut self, signal_name: String, ) -> VMResult<NotificationHandle>
fn sys_complete_signal( &mut self, target_invocation_id: String, signal_name: String, value: NonEmptyValue, ) -> VMResult<()>
fn sys_get_promise(&mut self, key: String) -> VMResult<NotificationHandle>
fn sys_peek_promise(&mut self, key: String) -> VMResult<NotificationHandle>
fn sys_complete_promise( &mut self, key: String, value: NonEmptyValue, ) -> VMResult<NotificationHandle>
fn sys_run(&mut self, name: String) -> VMResult<NotificationHandle>
fn propose_run_completion( &mut self, notification_handle: NotificationHandle, value: RunExitResult, retry_policy: RetryPolicy, ) -> VMResult<()>
fn sys_cancel_invocation( &mut self, target_invocation_id: String, ) -> VMResult<()>
fn sys_attach_invocation( &mut self, target: AttachInvocationTarget, ) -> VMResult<NotificationHandle>
fn sys_get_invocation_output( &mut self, target: AttachInvocationTarget, ) -> VMResult<NotificationHandle>
fn sys_write_output(&mut self, value: NonEmptyValue) -> Result<(), Error>
fn sys_end(&mut self) -> Result<(), Error>
fn is_waiting_preflight(&self) -> bool
fn is_replaying(&self) -> bool
Source§fn is_processing(&self) -> bool
fn is_processing(&self) -> bool
Returns true if the state machine is in processing state
Source§fn last_command_index(&self) -> i64
fn last_command_index(&self) -> i64
Returns last command index. Returns
-1
if there was no progress in the journal.Auto Trait Implementations§
impl !Freeze for CoreVM
impl RefUnwindSafe for CoreVM
impl Send for CoreVM
impl Sync for CoreVM
impl Unpin for CoreVM
impl UnwindSafe for CoreVM
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> 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