NetSocket Class Reference

#import <NetSocket.h>

List of all members.

Public Member Functions

(id) - delegate
(void) - setDelegate:
(BOOL) - open
(void) - close
(BOOL) - scheduleOnCurrentRunLoop
(BOOL) - scheduleOnRunLoop:
(BOOL) - listenOnRandomPort
(BOOL) - listenOnPort:
(BOOL) - listenOnPort:maxPendingConnections:
(BOOL) - connectToHost:port:
(BOOL) - connectToHost:port:timeout:
(NSData *) - peekData
(unsigned) - read:amount:
(unsigned) - readOntoData:
(unsigned) - readOntoData:amount:
(unsigned) - readOntoString:encoding:amount:
(NSData *) - readData
(NSData *) - readData:
(NSString *) - readString:
(NSString *) - readString:amount:
(void) - write:length:
(void) - writeData:
(void) - writeString:encoding:
(NSString *) - remoteHost
(UInt16) - remotePort
(NSString *) - localHost
(UInt16) - localPort
(BOOL) - isConnected
(BOOL) - isListening
(unsigned) - incomingBufferLength
(unsigned) - outgoingBufferLength
(CFSocketNativeHandle) - nativeSocketHandle
(CFSocketRef) - cfsocketRef
(id) - init [implementation]
(id) - initWithNativeSocket: [implementation]
(void) - dealloc [implementation]
(void) - unscheduleFromRunLoop [implementation]
(void) - _cfsocketCreateForNative: [implementation]
(BOOL) - _cfsocketCreated [implementation]
(void) - _cfsocketConnected [implementation]
(void) - _cfsocketDisconnected [implementation]
(void) - _cfsocketNewConnection [implementation]
(void) - _cfsocketDataAvailable [implementation]
(void) - _cfsocketWritable [implementation]
(void) - _socketConnectionTimedOut: [implementation]
(NetSocket *) - _socketAcceptConnection [implementation]
(void) - _socketReadData [implementation]
(void) - _socketWriteData [implementation]
(BOOL) - _socketIsWritable [implementation]
(int) - _socketReadableByteCount [implementation]
(void) - _scheduleConnectionTimeoutTimer: [implementation]
(void) - _unscheduleConnectionTimeoutTimer [implementation]

Static Public Member Functions

(NetSocket *) + netsocket
(NetSocket *) + netsocketListeningOnRandomPort
(NetSocket *) + netsocketListeningOnPort:
(NetSocket *) + netsocketConnectedToHost:port:
(void) + ignoreBrokenPipes
(NSString *) + stringWithSocketAddress:

Protected Attributes

CFSocketRef mCFSocketRef
CFRunLoopSourceRef mCFSocketRunLoopSourceRef
id mDelegate
NSTimer * mConnectionTimer
BOOL mSocketConnected
BOOL mSocketListening
NSMutableData * mOutgoingBuffer
NSMutableData * mIncomingBuffer


Detailed Description

Definition at line 10 of file NetSocket.h.


Member Function Documentation

- (void) _cfsocketConnected   [implementation]

Definition at line 810 of file NetSocket.m.

Here is the call graph for this function:

- (BOOL) _cfsocketCreated   [implementation]

Definition at line 805 of file NetSocket.m.

Here is the caller graph for this function:

- (void) _cfsocketCreateForNative: (CFSocketNativeHandle)  inNativeSocket   [implementation]

Definition at line 765 of file NetSocket.m.

Here is the caller graph for this function:

- (void) _cfsocketDataAvailable   [implementation]

Definition at line 849 of file NetSocket.m.

Here is the call graph for this function:

- (void) _cfsocketDisconnected   [implementation]

Definition at line 826 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (void) _cfsocketNewConnection   [implementation]

Definition at line 836 of file NetSocket.m.

- (void) _cfsocketWritable   [implementation]

Definition at line 868 of file NetSocket.m.

Here is the call graph for this function:

- (void) _scheduleConnectionTimeoutTimer: (NSTimeInterval)  inTimeout   [implementation]

Definition at line 1076 of file NetSocket.m.

Here is the caller graph for this function:

- (NetSocket *) _socketAcceptConnection   [implementation]

Definition at line 891 of file NetSocket.m.

Here is the call graph for this function:

- (void) _socketConnectionTimedOut: (NSTimer*)  inTimer   [implementation]

Definition at line 876 of file NetSocket.m.

Here is the call graph for this function:

- (BOOL) _socketIsWritable   [implementation]

Definition at line 1024 of file NetSocket.m.

Here is the call graph for this function:

- (int) _socketReadableByteCount   [implementation]

Definition at line 1052 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (void) _socketReadData   [implementation]

Definition at line 921 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (void) _socketWriteData   [implementation]

Definition at line 967 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (void) _unscheduleConnectionTimeoutTimer   [implementation]

Definition at line 1082 of file NetSocket.m.

Here is the caller graph for this function:

- (CFSocketRef) cfsocketRef  

Definition at line 745 of file NetSocket.m.

- (void) close  

Definition at line 200 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (BOOL) connectToHost: (NSString*)  inHostname
port: (UInt16)  inPort 

Definition at line 350 of file NetSocket.m.

Here is the call graph for this function:

- (BOOL) connectToHost: (NSString*)  inHostname
port: (UInt16)  inPort
timeout: (NSTimeInterval)  inTimeout 

Definition at line 355 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (void) dealloc   [implementation]

Definition at line 83 of file NetSocket.m.

Here is the call graph for this function:

- (id) delegate  

Definition at line 167 of file NetSocket.m.

+ (void) ignoreBrokenPipes  

Definition at line 752 of file NetSocket.m.

- (unsigned) incomingBufferLength  

Definition at line 725 of file NetSocket.m.

- (id) init   [implementation]

Definition at line 44 of file NetSocket.m.

Here is the caller graph for this function:

- (id) initWithNativeSocket: (int)  inNativeSocket   [implementation]

Definition at line 62 of file NetSocket.m.

Here is the call graph for this function:

- (BOOL) isConnected  

Definition at line 714 of file NetSocket.m.

Here is the caller graph for this function:

- (BOOL) isListening  

Definition at line 720 of file NetSocket.m.

Here is the caller graph for this function:

- (BOOL) listenOnPort: (UInt16)  inPort  

Definition at line 299 of file NetSocket.m.

Here is the call graph for this function:

- (BOOL) listenOnPort: (UInt16)  inPort
maxPendingConnections: (int)  inMaxPendingConnections 

Definition at line 304 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (BOOL) listenOnRandomPort  

Definition at line 294 of file NetSocket.m.

Here is the call graph for this function:

- (NSString *) localHost  

Definition at line 676 of file NetSocket.m.

Here is the call graph for this function:

- (UInt16) localPort  

Definition at line 695 of file NetSocket.m.

Here is the call graph for this function:

- (CFSocketNativeHandle) nativeSocketHandle  

Definition at line 735 of file NetSocket.m.

Here is the caller graph for this function:

+ (NetSocket *) netsocket  

Definition at line 110 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

+ (NetSocket *) netsocketConnectedToHost: (NSString*)  inHostname
port: (UInt16)  inPort 

Definition at line 149 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

+ (NetSocket *) netsocketListeningOnPort: (UInt16)  inPort  

Definition at line 133 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

+ (NetSocket *) netsocketListeningOnRandomPort  

Definition at line 127 of file NetSocket.m.

Here is the call graph for this function:

- (BOOL) open  

Definition at line 180 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (unsigned) outgoingBufferLength  

Definition at line 730 of file NetSocket.m.

- (NSData *) peekData  

Definition at line 397 of file NetSocket.m.

- (unsigned) read: (void*)  inBuffer
amount: (unsigned)  inAmount 

Definition at line 404 of file NetSocket.m.

- (NSData *) readData  

Definition at line 504 of file NetSocket.m.

Here is the caller graph for this function:

- (NSData *) readData: (unsigned)  inAmount  

Definition at line 523 of file NetSocket.m.

- (unsigned) readOntoData: (NSMutableData*)  inData  

Definition at line 422 of file NetSocket.m.

- (unsigned) readOntoData: (NSMutableData*)  inData
amount: (unsigned)  inAmount 

Definition at line 442 of file NetSocket.m.

- (unsigned) readOntoString: (NSMutableString*)  inString
encoding: (NSStringEncoding)  inEncoding
amount: (unsigned)  inAmount 

Definition at line 460 of file NetSocket.m.

- (NSString *) readString: (NSStringEncoding)  inEncoding  

Definition at line 546 of file NetSocket.m.

- (NSString *) readString: (NSStringEncoding)  inEncoding
amount: (unsigned)  inAmount 

Definition at line 565 of file NetSocket.m.

- (NSString *) remoteHost  

Definition at line 638 of file NetSocket.m.

Here is the call graph for this function:

- (UInt16) remotePort  

Definition at line 657 of file NetSocket.m.

Here is the call graph for this function:

- (BOOL) scheduleOnCurrentRunLoop  

Definition at line 242 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (BOOL) scheduleOnRunLoop: (NSRunLoop*)  inRunLoop  

Definition at line 247 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (void) setDelegate: (id)  inDelegate  

Definition at line 172 of file NetSocket.m.

Here is the caller graph for this function:

+ (NSString *) stringWithSocketAddress: (struct in_addr*)  inAddress  

Definition at line 758 of file NetSocket.m.

Here is the caller graph for this function:

- (void) unscheduleFromRunLoop   [implementation]

Definition at line 274 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (void) write: (const void*)  inBytes
length: (unsigned)  inLength 

Definition at line 605 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (void) writeData: (NSData*)  inData  

Definition at line 626 of file NetSocket.m.

Here is the call graph for this function:

Here is the caller graph for this function:

- (void) writeString: (NSString*)  inString
encoding: (NSStringEncoding)  inEncoding 

Definition at line 631 of file NetSocket.m.

Here is the call graph for this function:


Member Data Documentation

- (CFSocketRef) mCFSocketRef [protected]

Definition at line 12 of file NetSocket.h.

- (CFRunLoopSourceRef) mCFSocketRunLoopSourceRef [protected]

Definition at line 13 of file NetSocket.h.

- (NSTimer*) mConnectionTimer [protected]

Definition at line 15 of file NetSocket.h.

- (id) mDelegate [protected]

Definition at line 14 of file NetSocket.h.

- (NSMutableData*) mIncomingBuffer [protected]

Definition at line 19 of file NetSocket.h.

- (NSMutableData*) mOutgoingBuffer [protected]

Definition at line 18 of file NetSocket.h.

- (BOOL) mSocketConnected [protected]

Definition at line 16 of file NetSocket.h.

- (BOOL) mSocketListening [protected]

Definition at line 17 of file NetSocket.h.


The documentation for this class was generated from the following files:

Generated on Tue May 26 18:26:48 2009 for Ambient-C Documentation by  doxygen 1.5.8