Tekkotsu Homepage
Demos
Overview
Downloads
Dev. Resources
Reference
Credits

DummySocket Class Reference

#include <DummySocket.h>

Inheritance diagram for DummySocket:

Inheritance graph
[legend]
List of all members.

Detailed Description

provides a no-op implementation of Socket for disabled operation

This class provides a DummySocket that doesn't really do anything It exists to maintain code readability; while supporting dogs without wireless Of course, since it does nothing, it doesn't need documentation

Definition at line 17 of file DummySocket.h.

Public Member Functions

 DummySocket (int sockn)
 constructor
virtual ~DummySocket ()
 destructor
byte * getWriteBuffer (int)
 returns NULL
void write (int)
 no-op
int read ()
 no-op (returns -1)
byte * getReadBuffer ()
 getReadBuffer is used with blocking read's NOT IMPLEMENTED
void init ()
 no-op (returns NULL) no-op
int setFlushType (FlushType_t)
 no-op
void setTextForward ()
 no-op
void setForward (DummySocket *)
 sets another socket to send data to if this one is not connected
void setVerbosity (int)
 no-op
int write (const byte *, int)
 no-op (returns -1)
int read (byte *, int)
 no-ip (returns -1)
int printf (const char *,...)
 no-op
int vprintf (const char *, va_list)
 no-op
int pprintf (int, const char *,...)
 no-op
void flush ()
 no-op

Friends

class Wireless


Member Function Documentation

byte* DummySocket::getReadBuffer (  )  [inline]

getReadBuffer is used with blocking read's NOT IMPLEMENTED

The read(void) and getReadBuffer combo eliminates one buffer copy. You don't need to use getReadBuffer with read(byte*, int)

Blocking read is currently broken - it will be fixed in the next release

Returns:
pointer to the buffer the previous call to blocking read wrote into or NULL if no data was read

Reimplemented from Socket.

Definition at line 29 of file DummySocket.h.


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

Tekkotsu v3.0
Generated Fri May 11 20:08:01 2007 by Doxygen 1.4.7