[−][src]Struct deno_cli::state::ThreadSafeState
Isolate cannot be passed between threads but ThreadSafeState can. ThreadSafeState satisfies Send and Sync. So any state that needs to be accessed outside the main V8 thread should be inside ThreadSafeState.
Methods
impl ThreadSafeState[src]
impl ThreadSafeState[src]
pub fn new(
flags: DenoFlags,
argv_rest: Vec<String>,
progress: Progress,
include_deno_namespace: bool
) -> Result<Self, ErrBox>[src]
flags: DenoFlags,
argv_rest: Vec<String>,
progress: Progress,
include_deno_namespace: bool
) -> Result<Self, ErrBox>
pub fn fetch_compiled_module(
&self,
module_specifier: &ModuleSpecifier
) -> impl Future<Item = CompiledModule, Error = ErrBox>[src]
&self,
module_specifier: &ModuleSpecifier
) -> impl Future<Item = CompiledModule, Error = ErrBox>
pub fn main_module(&self) -> Option<ModuleSpecifier>[src]
Read main module from argv
pub fn check_read(&self, filename: &str) -> Result<(), ErrBox>[src]
pub fn check_write(&self, filename: &str) -> Result<(), ErrBox>[src]
pub fn check_env(&self) -> Result<(), ErrBox>[src]
pub fn check_net(&self, host_and_port: &str) -> Result<(), ErrBox>[src]
pub fn check_net_url(&self, url: &Url) -> Result<(), ErrBox>[src]
pub fn check_run(&self) -> Result<(), ErrBox>[src]
pub fn check_dyn_import(
&self,
module_specifier: &ModuleSpecifier
) -> Result<(), ErrBox>[src]
&self,
module_specifier: &ModuleSpecifier
) -> Result<(), ErrBox>
pub fn metrics_op_dispatched(
&self,
bytes_sent_control: usize,
bytes_sent_data: usize
)[src]
&self,
bytes_sent_control: usize,
bytes_sent_data: usize
)
pub fn metrics_op_completed(&self, bytes_received: usize)[src]
Methods from Deref<Target = Arc<State>>
Trait Implementations
impl Clone for ThreadSafeState[src]
fn clone(&self) -> Self[src]
fn clone_from(&mut self, source: &Self)1.0.0[src]
impl Deref for ThreadSafeState[src]
type Target = Arc<State>
The resulting type after dereferencing.
fn deref(&self) -> &Self::Target[src]
impl Loader for ThreadSafeState[src]
fn resolve(
&self,
specifier: &str,
referrer: &str,
is_main: bool,
is_dyn_import: bool
) -> Result<ModuleSpecifier, ErrBox>[src]
&self,
specifier: &str,
referrer: &str,
is_main: bool,
is_dyn_import: bool
) -> Result<ModuleSpecifier, ErrBox>
fn load(&self, module_specifier: &ModuleSpecifier) -> Box<SourceCodeInfoFuture>[src]
Given an absolute url, load its source code.
Auto Trait Implementations
impl Send for ThreadSafeState
impl Unpin for ThreadSafeState
impl Sync for ThreadSafeState
impl UnwindSafe for ThreadSafeState
impl RefUnwindSafe for ThreadSafeState
Blanket Implementations
impl<T> ToOwned for T where
T: Clone, [src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T[src]
fn clone_into(&self, target: &mut T)[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> From<T> for T[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,
fn vzip(self) -> V
impl<T> Erased for T
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
U: TryFrom<T>,
impl<T, F> ComparatorFunction<Option<T>> for F where
F: ComparatorFunction<T>, [src]
F: ComparatorFunction<T>,