OFTCPSocket Class Reference

A class which provides functions to create and use TCP sockets. More...

#import <OFTCPSocket.h>

Inheritance diagram for OFTCPSocket:
OFSocket OFStream OFObject

List of all members.

Public Member Functions

(id) - connectToService:onNode:
(id) - bindService:onNode:withFamily:
(id) - listenWithBackLog:
(id) - listen
(OFTCPSocket *) - accept
(id) - enableKeepAlives:

Protected Attributes

struct sockaddr * saddr
socklen_t saddr_len

Detailed Description

A class which provides functions to create and use TCP sockets.


Member Function Documentation

- (OFTCPSocket *) accept  

Accept an incoming connection.

Returns:
An autoreleased OFTCPSocket for the accepted connection.
- (id) bindService: (OFString*)  service
onNode: (OFString*)  node
withFamily: (int)  family 

Bind socket on the specified node and service.

Parameters:
service The service to bind
node The node to bind to
family The family to use (AF_INET or AF_INET6)
- (id) connectToService: (OFString*)  service
onNode: (OFString*)  node 

Connect the OFTCPSocket to the specified destination.

Parameters:
service The service on the node to connect to
node The node to connect to
- (id) enableKeepAlives: (BOOL)  enable  

Enable or disable keep alives for the connection.

- (id) listen  

Listen on the socket.

- (id) listenWithBackLog: (int)  backlog  

Listen on the socket.

Parameters:
backlog Maximum length for the queue of pending connections.

The documentation for this class was generated from the following files:
 All Classes Functions Variables

Generated on Sun Mar 14 13:41:06 2010 for ObjFW by  doxygen 1.6.1