Struct lunatic_runtime::DefaultProcessState
source · [−]pub struct DefaultProcessState { /* private fields */ }Trait Implementations
sourceimpl Debug for DefaultProcessState
impl Debug for DefaultProcessState
sourceimpl Default for DefaultProcessState
impl Default for DefaultProcessState
sourceimpl ErrorCtx for DefaultProcessState
impl ErrorCtx for DefaultProcessState
fn error_resources(&self) -> &ErrorResource
fn error_resources_mut(&mut self) -> &mut ErrorResource
sourceimpl LunaticWasiCtx for DefaultProcessState
impl LunaticWasiCtx for DefaultProcessState
fn wasi(&self) -> &WasiCtx
fn wasi_mut(&mut self) -> &mut WasiCtx
fn set_stdout(&mut self, stdout: StdoutCapture)
fn set_stderr(&mut self, stderr: StdoutCapture)
fn get_stdout(&self) -> Option<&StdoutCapture>
fn get_stderr(&self) -> Option<&StdoutCapture>
sourceimpl NetworkingCtx for DefaultProcessState
impl NetworkingCtx for DefaultProcessState
fn tcp_listener_resources(&self) -> &TcpListenerResources
fn tcp_listener_resources_mut(&mut self) -> &mut TcpListenerResources
fn tcp_stream_resources(&self) -> &TcpStreamResources
fn tcp_stream_resources_mut(&mut self) -> &mut TcpStreamResources
fn udp_resources(&self) -> &UdpResources
fn udp_resources_mut(&mut self) -> &mut UdpResources
fn dns_resources(&self) -> &DnsResources
fn dns_resources_mut(&mut self) -> &mut DnsResources
sourceimpl ProcessCtx<DefaultProcessState> for DefaultProcessState
impl ProcessCtx<DefaultProcessState> for DefaultProcessState
fn mailbox(&mut self) -> &mut MessageMailbox
fn message_scratch_area(&mut self) -> &mut Option<Message>
fn module_resources(&self) -> &ModuleResources<DefaultProcessState>
fn module_resources_mut(&mut self) -> &mut ModuleResources<DefaultProcessState>
fn process_resources(&self) -> &ProcessResources
fn process_resources_mut(&mut self) -> &mut ProcessResources
sourceimpl ProcessState for DefaultProcessState
impl ProcessState for DefaultProcessState
type Config = DefaultProcessConfig
fn new(
runtime: WasmtimeRuntime,
module: WasmtimeCompiledModule<Self>,
config: Arc<DefaultProcessConfig>,
registry: Arc<DashMap<String, Arc<dyn Process>>>
) -> Result<Self>
sourcefn register(linker: &mut Linker<Self>) -> Result<()>
fn register(linker: &mut Linker<Self>) -> Result<()>
Register all host functions to the linker.
sourcefn initialize(&mut self)
fn initialize(&mut self)
Marks a wasm instance as initialized
sourcefn is_initialized(&self) -> bool
fn is_initialized(&self) -> bool
Returns true if the instance was initialized
sourcefn runtime(&self) -> &WasmtimeRuntime
fn runtime(&self) -> &WasmtimeRuntime
Returns the WebAssembly runtime
sourcefn config(&self) -> &Arc<DefaultProcessConfig>
fn config(&self) -> &Arc<DefaultProcessConfig>
Returns the process configuration
fn module(&self) -> &WasmtimeCompiledModule<Self>
fn id(&self) -> Uuid
fn signal_mailbox(&self) -> &(Sender<Signal>, Receiver<Signal>)
fn message_mailbox(&self) -> &MessageMailbox
fn config_resources(
&self
) -> &ConfigResources<<DefaultProcessState as ProcessState>::Config>
fn config_resources_mut(
&mut self
) -> &mut ConfigResources<<DefaultProcessState as ProcessState>::Config>
fn registry(&self) -> &Arc<DashMap<String, Arc<dyn Process>>>
sourceimpl ResourceLimiter for DefaultProcessState
impl ResourceLimiter for DefaultProcessState
sourcefn memory_growing(
&mut self,
_current: usize,
desired: usize,
_maximum: Option<usize>
) -> bool
fn memory_growing(
&mut self,
_current: usize,
desired: usize,
_maximum: Option<usize>
) -> bool
Notifies the resource limiter that an instance’s linear memory has been requested to grow. Read more
sourcefn table_growing(
&mut self,
_current: u32,
desired: u32,
_maximum: Option<u32>
) -> bool
fn table_growing(
&mut self,
_current: u32,
desired: u32,
_maximum: Option<u32>
) -> bool
Notifies the resource limiter that an instance’s table has been requested to grow. Read more
sourcefn instances(&self) -> usize
fn instances(&self) -> usize
The maximum number of instances that can be created for a Store. Read more
sourcefn tables(&self) -> usize
fn tables(&self) -> usize
The maximum number of tables that can be created for a Store. Read more
sourcefn memories(&self) -> usize
fn memories(&self) -> usize
The maximum number of linear memories that can be created for a Store Read more
sourcefn memory_grow_failed(&mut self, _error: &Error)
fn memory_grow_failed(&mut self, _error: &Error)
Notifies the resource limiter that growing a linear memory, permitted by
the memory_growing method, has failed. Read more
sourcefn table_grow_failed(&mut self, _error: &Error)
fn table_grow_failed(&mut self, _error: &Error)
Notifies the resource limiter that growing a linear memory, permitted by
the table_growing method, has failed. Read more
Auto Trait Implementations
impl !RefUnwindSafe for DefaultProcessState
impl Send for DefaultProcessState
impl Sync for DefaultProcessState
impl Unpin for DefaultProcessState
impl !UnwindSafe for DefaultProcessState
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> GetSetFdFlags for T
impl<T> GetSetFdFlags for T
fn get_fd_flags(&self) -> Result<FdFlags, Error> where
T: AsFilelike,
fn get_fd_flags(&self) -> Result<FdFlags, Error> where
T: AsFilelike,
Query the “status” flags for the self file descriptor.
fn new_set_fd_flags(&self, fd_flags: FdFlags) -> Result<SetFdFlags<T>, Error> where
T: AsFilelike,
fn new_set_fd_flags(&self, fd_flags: FdFlags) -> Result<SetFdFlags<T>, Error> where
T: AsFilelike,
Create a new SetFdFlags value for use with set_fd_flags. Read more
fn set_fd_flags(&mut self, set_fd_flags: SetFdFlags<T>) -> Result<(), Error> where
T: AsFilelike,
fn set_fd_flags(&mut self, set_fd_flags: SetFdFlags<T>) -> Result<(), Error> where
T: AsFilelike,
Set the “status” flags for the self file descriptor. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<T> Pointable for T
impl<T> Pointable for T
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more