diff options
author | schmidt <douglascraigschmidt@users.noreply.github.com> | 1999-07-02 21:02:20 +0000 |
---|---|---|
committer | schmidt <douglascraigschmidt@users.noreply.github.com> | 1999-07-02 21:02:20 +0000 |
commit | 70d64c82bf9347563b4242d5c43cbca3a0176fcf (patch) | |
tree | 079722fa7d30976badb35c975d96f51cc152586f /ace/SOCK_Dgram.i | |
parent | a4ef4a23df8d1240d07e61d9b05708ffdf1a07c3 (diff) | |
download | ATCD-70d64c82bf9347563b4242d5c43cbca3a0176fcf.tar.gz |
.
Diffstat (limited to 'ace/SOCK_Dgram.i')
-rw-r--r-- | ace/SOCK_Dgram.i | 56 |
1 files changed, 54 insertions, 2 deletions
diff --git a/ace/SOCK_Dgram.i b/ace/SOCK_Dgram.i index b6b9a5afacf..5d713b9872e 100644 --- a/ace/SOCK_Dgram.i +++ b/ace/SOCK_Dgram.i @@ -59,7 +59,7 @@ ACE_SOCK_Dgram::recv (void *buf, } ASYS_INLINE ssize_t -ACE_SOCK_Dgram::send (const iovec *buffers, +ACE_SOCK_Dgram::send (const iovec buffers[], int buffer_count, size_t &number_of_bytes_sent, int flags, @@ -82,7 +82,7 @@ ACE_SOCK_Dgram::send (const iovec *buffers, } ASYS_INLINE ssize_t -ACE_SOCK_Dgram::recv (iovec *buffers, +ACE_SOCK_Dgram::recv (iovec buffers[], int buffer_count, size_t &number_of_bytes_recvd, int &flags, @@ -106,3 +106,55 @@ ACE_SOCK_Dgram::recv (iovec *buffers, addr.set_size (addr_len); return status; } + +// <sendto> an N byte datagram to <addr> (connectionless version). + +ASYS_INLINE ssize_t +ACE_SOCK_Dgram::send (const void *buf, + size_t n, + const ACE_Addr &addr, + int flags, + ACE_OVERLAPPED *overlapped, + ACE_OVERLAPPED_COMPLETION_FUNC func) const +{ + ACE_TRACE ("ACE_SOCK_Dgram::send"); + + iovec buffer[1]; + buffer[0].iov_len = n; + buffer[0].iov_base = buf; + size_t number_of_bytes_sent = 0; + return this->send (this->get_handle (), + buffer, + 1, + number_of_bytes_sent, + flags, + addr, + overlapped, + func); +} + +// <recvfrom> an n byte datagram (connectionless version). + +ASYS_INLINE ssize_t +ACE_SOCK_Dgram::recv (void *buf, + size_t n, + ACE_Addr &addr, + int flags, + ACE_OVERLAPPED *overlapped, + ACE_OVERLAPPED_COMPLETION_FUNC func) const +{ + ACE_TRACE ("ACE_SOCK_Dgram::recv"); + + iovec buffer[1]; + buffer[0].iov_len = n; + buffer[0].iov_base = buf; + size_t number_of_bytes_recvd = 0; + return this->recv (this->get_handle (), + buffer, + 1, + number_of_bytes_recvd, + flags, + addr, + overlapped, + func); +} |