pub struct PreparedQueuePair { /* private fields */ }Expand description
An allocated but unconnected QueuePair.
This struct represents a QP that has been created on the device but is not yet connected to a remote peer.
§The Connection Process
- Exchange Endpoints: Use
endpoint()to get your local connection info. Send this to the remote peer via an out-of-band channel (e.g., TCP). Receive the peer’sQueuePairEndpointin return. - Handshake: Call
handshakewith the remote peer’s endpoint.
Implementations§
Source§impl PreparedQueuePair
impl PreparedQueuePair
Sourcepub fn endpoint(&self) -> QueuePairEndpoint
pub fn endpoint(&self) -> QueuePairEndpoint
Returns the network endpoint information for this QueuePair.
Share this with the remote peer so it can connect its remote QP to this one.
Sourcepub fn handshake(self, remote: QueuePairEndpoint) -> IbvResult<QueuePair>
pub fn handshake(self, remote: QueuePairEndpoint) -> IbvResult<QueuePair>
Connects this Queue Pair to a remote peer.
This consumes the PreparedQueuePair and returns a connected QueuePair.
§Arguments
remote— The endpoint information received from the remote peer.
§Errors
IbvError::InvalidInput— Invalid state transition parameters (e.g., invalid port or access flags).IbvError::Resource— Hardware resource exhaustion during state transition.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PreparedQueuePair
impl RefUnwindSafe for PreparedQueuePair
impl Send for PreparedQueuePair
impl Sync for PreparedQueuePair
impl Unpin for PreparedQueuePair
impl UnsafeUnpin for PreparedQueuePair
impl UnwindSafe for PreparedQueuePair
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