Struct spice::core::Kernel[][src]

pub struct Kernel { /* fields omitted */ }

Kernel type to automatically load the kernel on the definition and keep a record of the status of the loading.

Implementations

impl Kernel[src]

pub fn new<P: Into<PathBuf>>(file: P) -> Result<Self, KernelAlreadyLoadedError>[src]

Constructor from the path of the file. Automatically load the kernel.

pub fn name(&self) -> String[src]

Get the path as a string.

pub fn load(&mut self) -> Result<(), KernelAlreadyLoadedError>[src]

Load the kernel if not loaded already.

pub fn unload(&mut self) -> Result<(), KernelNotLoadedError>[src]

Unload the kernel if loaded.

Trait Implementations

impl Clone for Kernel[src]

impl Debug for Kernel[src]

Auto Trait Implementations

impl RefUnwindSafe for Kernel

impl Send for Kernel

impl Sync for Kernel

impl Unpin for Kernel

impl UnwindSafe for Kernel

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[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, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<SS, SP> SupersetOf<SS> for SP where
    SS: SubsetOf<SP>, 

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>,