VTK
|
Encapsulate a socket that accepts connections. More...
#include <vtkServerSocket.h>
Public Types | |
typedef vtkSocket | Superclass |
Public Member Functions | |
virtual int | IsA (const char *type) |
vtkServerSocket * | NewInstance () const |
void | PrintSelf (ostream &os, vtkIndent indent) |
int | CreateServer (int port) |
vtkClientSocket * | WaitForConnection (unsigned long msec=0) |
Static Public Member Functions | |
static vtkServerSocket * | New () |
static int | IsTypeOf (const char *type) |
static vtkServerSocket * | SafeDownCast (vtkObjectBase *o) |
Protected Member Functions | |
virtual vtkObjectBase * | NewInstanceInternal () const |
int | GetServerPort () |
vtkServerSocket () | |
~vtkServerSocket () |
Encapsulate a socket that accepts connections.
Definition at line 28 of file vtkServerSocket.h.
typedef vtkSocket vtkServerSocket::Superclass |
Reimplemented from vtkSocket.
Definition at line 32 of file vtkServerSocket.h.
vtkServerSocket::vtkServerSocket | ( | ) | [protected] |
Returns the port on which the server is running.
vtkServerSocket::~vtkServerSocket | ( | ) | [protected] |
Returns the port on which the server is running.
static vtkServerSocket* vtkServerSocket::New | ( | ) | [static] |
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
Reimplemented from vtkObject.
static int vtkServerSocket::IsTypeOf | ( | const char * | name | ) | [static] |
Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
Reimplemented from vtkSocket.
virtual int vtkServerSocket::IsA | ( | const char * | name | ) | [virtual] |
Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
Reimplemented from vtkSocket.
static vtkServerSocket* vtkServerSocket::SafeDownCast | ( | vtkObjectBase * | o | ) | [static] |
Reimplemented from vtkSocket.
virtual vtkObjectBase* vtkServerSocket::NewInstanceInternal | ( | ) | const [protected, virtual] |
Reimplemented from vtkSocket.
vtkServerSocket* vtkServerSocket::NewInstance | ( | ) | const |
Reimplemented from vtkSocket.
void vtkServerSocket::PrintSelf | ( | ostream & | os, |
vtkIndent | indent | ||
) | [virtual] |
int vtkServerSocket::CreateServer | ( | int | port | ) |
Creates a server socket at a given port and binds to it. Returns -1 on error. 0 on success.
vtkClientSocket* vtkServerSocket::WaitForConnection | ( | unsigned long | msec = 0 | ) |
Waits for a connection. When a connection is received a new vtkClientSocket object is created and returned. Returns NULL on timeout.
Returns the port on which the server is running.