a library to use GPRS like ethernet or wifi, which makes it possible to connect to the internet with your GPRS module
Dependents: Seeed_GPRS_Library_HelloWorld Seeed_GPRS_Xively_HelloWorld Seeed_ARCH_GPRS_V2_Xively_HelloWorld Seeed_ARCH_GPRS_V2_ThingSpeak_HelloWorld ... more
TCPSocketServer Class Reference
TCP Server. More...
#include <TCPSocketServer.h>
Inherits Socket.
Public Member Functions | |
TCPSocketServer () | |
Instantiate a TCP Server. | |
int | bind (int port) |
Bind a socket to a specific port. | |
int | listen (int backlog=1) |
Start listening for incoming connections. | |
int | accept (TCPSocketConnection &connection) |
Accept a new connection. | |
int | close () |
Close the socket file descriptor. |
Detailed Description
TCP Server.
Definition at line 30 of file TCPSocketServer.h.
Constructor & Destructor Documentation
TCPSocketServer | ( | ) |
Instantiate a TCP Server.
Member Function Documentation
int accept | ( | TCPSocketConnection & | connection ) |
Accept a new connection.
- Parameters:
-
connection A TCPSocketConnection instance that will handle the incoming connection.
- Returns:
- 0 on success, -1 on failure.
int bind | ( | int | port ) |
Bind a socket to a specific port.
- Parameters:
-
port The port to listen for incoming connections on.
- Returns:
- 0 on success, -1 on failure.
int close | ( | ) | [inherited] |
Close the socket file descriptor.
Definition at line 37 of file Socket.cpp.
int listen | ( | int | backlog = 1 ) |
Start listening for incoming connections.
- Parameters:
-
backlog number of pending connections that can be queued up at any one time [Default: 1].
- Returns:
- 0 on success, -1 on failure.
Generated on Thu Jul 14 2022 07:16:02 by 1.7.2