Struct ntex_amqp::ConnectionRef
source · pub struct ConnectionRef(/* private fields */);
Implementations§
source§impl ConnectionRef
impl ConnectionRef
sourcepub fn force_close(&self)
pub fn force_close(&self)
Force close connection
sourcepub fn get_error(&self) -> Option<AmqpProtocolError>
pub fn get_error(&self) -> Option<AmqpProtocolError>
Get connection error
sourcepub fn get_session_by_local_id(&self, channel: u16) -> Option<Session>
pub fn get_session_by_local_id(&self, channel: u16) -> Option<Session>
Get existing session by local channel id
sourcepub fn close(&self) -> impl Future<Output = Result<(), AmqpProtocolError>>
pub fn close(&self) -> impl Future<Output = Result<(), AmqpProtocolError>>
Gracefully close connection
sourcepub fn close_with_error<E>(
&self,
err: E
) -> impl Future<Output = Result<(), AmqpProtocolError>>
pub fn close_with_error<E>( &self, err: E ) -> impl Future<Output = Result<(), AmqpProtocolError>>
Close connection with error
sourcepub fn open_session(
&self
) -> impl Future<Output = Result<Session, AmqpProtocolError>>
pub fn open_session( &self ) -> impl Future<Output = Result<Session, AmqpProtocolError>>
Opens the session
Trait Implementations§
source§impl AsRef<ConnectionRef> for Connection
impl AsRef<ConnectionRef> for Connection
source§fn as_ref(&self) -> &ConnectionRef
fn as_ref(&self) -> &ConnectionRef
Converts this type into a shared reference of the (usually inferred) input type.
source§impl Clone for ConnectionRef
impl Clone for ConnectionRef
source§fn clone(&self) -> ConnectionRef
fn clone(&self) -> ConnectionRef
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 moreAuto Trait Implementations§
impl Freeze for ConnectionRef
impl !RefUnwindSafe for ConnectionRef
impl !Send for ConnectionRef
impl !Sync for ConnectionRef
impl Unpin for ConnectionRef
impl !UnwindSafe for ConnectionRef
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more