Struct bastion::Config[][src]

pub struct Config { /* fields omitted */ }

The configuration that should be used to initialize the system using Bastion::init_with.

The default behaviors are the following:

Example

use bastion::prelude::*;

let config = Config::new().show_backtraces();

Bastion::init_with(config);

// You can now use bastion...

Implementations

impl Config[src]

pub fn new() -> Self[src]

Creates a new configuration with the following default behaviors:

pub fn show_backtraces(mut self: Self) -> Self[src]

Makes Bastion show all backtraces, like an application without it would. This can be useful when trying to debug children panicking.

Note that this is the default behavior.

Example

use bastion::prelude::*;

let config = Config::new().show_backtraces();

Bastion::init_with(config);

// You can now use bastion and it will show you the
// backtraces of panics...

pub fn hide_backtraces(mut self: Self) -> Self[src]

Makes Bastion hide all backtraces.

Note that the default behavior is to show all backtraces (see Config::show_backtraces).

Example

use bastion::prelude::*;

let config = Config::new().hide_backtraces();

Bastion::init_with(config);

// You can now use bastion and no panic backtraces
// will be shown...

Trait Implementations

impl Clone for Config[src]

impl Debug for Config[src]

impl Default for Config[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> AsAny for T where
    T: Any
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Message for T where
    T: Any + Send + Sync + Debug
[src]

impl<T> Pointable for T

type Init = T

The type for initializers.

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> State for T where
    T: Send + Sync + 'static, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,