Skip to main content

Spawn

Struct Spawn 

Source
#[repr(C)]
pub struct Spawn { pub size: u32, pub flags: u32, pub arguments: *const XilaString, pub argument_count: usize, pub environment: *const XilaString, pub environment_count: usize, pub standard_input: *const File, pub standard_output: *const File, pub standard_error: *const File, pub home: *const Directory, }
Expand description

Arguments of xila_process_spawn. Set size to sizeof(XilaSpawn). All pointers are borrowed for the call.

Fields§

§size: u32§flags: u32

The network rights the child gets (XILA_SPAWN_NETWORK_*). Zero gives it no network. Each right must be one the parent holds: a child never gets more than its parent. Other bits are reserved and must be zero.

§arguments: *const XilaString

Arguments of the child, with no implicit program name. A null array has count zero.

§argument_count: usize§environment: *const XilaString

The child’s whole environment as NAME=VALUE strings, a later entry overriding an earlier one. A null array gives the child a copy of the parent’s environment and requires count zero. An array with count zero gives it an empty one.

§environment_count: usize§standard_input: *const File

Streams the child gets as duplicates of these. All three are required.

§standard_output: *const File§standard_error: *const File§home: *const Directory

Optional home directory capability the child gets a copy of.

Auto Trait Implementations§

§

impl Freeze for Spawn

§

impl !RefUnwindSafe for Spawn

§

impl !Send for Spawn

§

impl !Sync for Spawn

§

impl Unpin for Spawn

§

impl UnsafeUnpin for Spawn

§

impl !UnwindSafe for Spawn

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.