chore: Batch*Message document

This commit is contained in:
zonyitoo
2024-08-03 23:53:33 +08:00
parent 9d97bd4fd8
commit 15b00a2b75
+6
View File
@@ -53,8 +53,11 @@ use super::{
target_os = "freebsd"
))]
pub struct BatchSendMessage<'a> {
/// Optional target address
pub addr: Option<SocketAddr>,
/// Data to be transmitted
pub data: &'a [IoSlice<'a>],
/// Output result. The number of bytes sent by `batch_send`
pub data_len: usize,
}
@@ -67,8 +70,11 @@ pub struct BatchSendMessage<'a> {
target_os = "freebsd"
))]
pub struct BatchRecvMessage<'a> {
/// Peer address
pub addr: SocketAddr,
/// Data buffer for receiving
pub data: &'a mut [IoSliceMut<'a>],
/// Output result. The number of bytes received by `batch_recv`
pub data_len: usize,
}