Winsock API function Encyclopedia 1

Source: Internet
Author: User

The Windows Sockets API interface provided by this system (winking) is a function (routine) as defined in version 1.1 of WINSOCK (as appendix) published on January 20, 1993; includes 30 Berkeley Software Dis Tribution (BSD) function and 16 functions that conform to the Windows message-driven feature.

The BSD functions include:

Accept () bind () closesocket () Connect ()

Getpeername () getsockname () getsockopt () htonl ()

Htons () inet_addr () Inet_ntoa () ioctlsocket ()

Listen () Ntohl () Ntohs () recv ()

Recvfrom () Select () Send () sendto ()

SetSockOpt () shutdown () socket () GetHostName ()

GETHOSTBYADDR () gethostbyname ()

Getprotobyname () Getprotobynumber ()

Getservbyname () Getservbyport ()

The Microsoft windows-specific Extensions functions include:

WSAASYNCGETHOSTBYADDR () WSAAsyncGetHostByName ()

Wsaasyncgetprotobyname () Wsaasyncgetprotobynumber ()

Wsaasyncgetservbyname () Wsaasyncgetservbyport ()

WSAAsyncSelect () wsacancelasyncrequest ()

WSACancelBlockingCall () WSACleanup ()

WSAGetLastError () wsaisblocking ()

Wsasetblockinghook () Wsasetlasterror ()

WSAStartup () Wsaunhookblockinghook ()

These API interfaces apply to the Internet Protocol Suite (IPS, commonly referred to as TCP/IP),

Support Stream (TCP) and Datagram (UDP) sockets.

Stream (TCP) sockets provide "two-way", "reliable", "orderly", "not repeated" data transfer.

Datagram (UDP) sockets provide "two-way" communication, but there is no "reliable", "orderly", "no repeat" and so on, so users may receive the information is not ordered, repeated, and even the data may be missing in the transmission process.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.