Struct go_engine::ffi::types::ChannelObj   
source · pub struct ChannelObj {
    pub recv_zero: GosValue,
    pub chan: Channel,
}Fields§
§recv_zero: GosValue§chan: ChannelImplementations§
source§impl ChannelObj
 
impl ChannelObj
pub fn new(cap: usize, recv_zero: GosValue) -> ChannelObj
pub fn with_chan(chan: Channel, recv_zero: GosValue) -> ChannelObj
pub fn len(&self) -> usize
pub fn cap(&self) -> usize
pub fn close(&self)
pub async fn send( &self, v: &GosValue ) -> impl Future<Output = Result<(), RuntimeError>>
pub async fn recv(&self) -> impl Future<Output = Option<GosValue>>
Trait Implementations§
source§impl Clone for ChannelObj
 
impl Clone for ChannelObj
source§fn clone(&self) -> ChannelObj
 
fn clone(&self) -> ChannelObj
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
 
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from 
source. Read more