[][src]Struct libffi::high::arity9::ClosureOnce9

pub struct ClosureOnce9<A, B, C, D, E, F, G, H, I, R> { /* fields omitted */ }

A one-shot, typed closure with the given argument and result types.

Methods

impl<A: CType, B: CType, C: CType, D: CType, E: CType, F: CType, G: CType, H: CType, I: CType, R: CType> ClosureOnce9<A, B, C, D, E, F, G, H, I, R>[src]

pub fn new<Callback>(callback: Callback) -> Self where
    Callback: FnOnce(A, B, C, D, E, F, G, H, I) -> R + Any
[src]

Constructs a typed closure callable from C from a Rust closure.

impl<A: Copy, B: Copy, C: Copy, D: Copy, E: Copy, F: Copy, G: Copy, H: Copy, I: Copy, R> ClosureOnce9<A, B, C, D, E, F, G, H, I, R>[src]

pub fn new_with_cif<Callback>(
    cif: Cif9<A, B, C, D, E, F, G, H, I, R>,
    callback: Callback
) -> Self where
    Callback: FnOnce(A, B, C, D, E, F, G, H, I) -> R + Any
[src]

Constructs a one-shot closure callable from C from a CIF describing the calling convention for the resulting function and the Rust closure to call.

impl<A, B, C, D, E, F, G, H, I, R> ClosureOnce9<A, B, C, D, E, F, G, H, I, R>[src]

pub fn code_ptr(
    &self
) -> &extern "C" fn(_: A, _: B, _: C, _: D, _: E, _: F, _: G, _: H, _: I) -> R
[src]

Gets the C code pointer that is used to invoke the closure.

pub fn from_parts<U: Any>(
    cif: Cif9<A, B, C, D, E, F, G, H, I, R>,
    callback: CallbackOnce9<U, A, B, C, D, E, F, G, H, I, R>,
    userdata: U
) -> Self
[src]

Constructs a one-shot closure callable from C from a CIF describing the calling convention for the resulting function, a callback for the function to call, and userdata to pass to the callback.

Auto Trait Implementations

impl<A, B, C, D, E, F, G, H, I, R> !Send for ClosureOnce9<A, B, C, D, E, F, G, H, I, R>

impl<A, B, C, D, E, F, G, H, I, R> !Sync for ClosureOnce9<A, B, C, D, E, F, G, H, I, R>

impl<A, B, C, D, E, F, G, H, I, R> Unpin for ClosureOnce9<A, B, C, D, E, F, G, H, I, R>

impl<A, B, C, D, E, F, G, H, I, R> !UnwindSafe for ClosureOnce9<A, B, C, D, E, F, G, H, I, R>

impl<A, B, C, D, E, F, G, H, I, R> !RefUnwindSafe for ClosureOnce9<A, B, C, D, E, F, G, H, I, R>

Blanket Implementations

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

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

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

type Error = !

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<T> Borrow<T> for T where
    T: ?Sized
[src]

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

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