Struct block::ConcreteBlock
[−]
[src]
#[repr(C)]pub struct ConcreteBlock<A, R, F> { /* fields omitted */ }
An Objective-C block whose size is known at compile time and may be constructed on the stack.
Methods
impl<A, R, F> ConcreteBlock<A, R, F> where
A: BlockArguments,
F: IntoConcreteBlock<A, Ret = R>,
[src]
A: BlockArguments,
F: IntoConcreteBlock<A, Ret = R>,
fn new(closure: F) -> Self
Constructs a ConcreteBlock
with the given closure.
When the block is called, it will return the value that results from
calling the closure.
impl<A, R, F> ConcreteBlock<A, R, F> where
F: 'static,
[src]
F: 'static,
Methods from Deref<Target = Block<A, R>>
unsafe fn call(&self, args: A) -> R
Call self with the given arguments.
Unsafe because this invokes foreign code that the caller must verify doesn't violate any of Rust's safety rules. For example, if this block is shared with multiple references, the caller must ensure that calling it will not cause a data race.
Trait Implementations
impl<A, R, F> Clone for ConcreteBlock<A, R, F> where
F: Clone,
[src]
F: Clone,
fn clone(&self) -> Self
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl<A, R, F> Deref for ConcreteBlock<A, R, F>
[src]
type Target = Block<A, R>
The resulting type after dereferencing
fn deref(&self) -> &Block<A, R>
The method called to dereference a value