#include <CAVERNnet_remoteFileIO32_c.hxx>
Public Methods | |
int | init (int inPort=CAVERNnet_remoteFileIOServer32_c::DEFAULT_PORT, char *neighborServer=NULL, int neighborPort=CAVERNnet_remoteFileIOServer32_c::DEFAULT_PORT, int storeLocally=1) |
Initialize server. | |
void | process (int threaded=CAVERNnet_remoteFileIOServer32_c::NON_THREADED) |
void | setRemotePort (int port=CAVERNnet_remoteFileIOServer32_c::DEFAULT_PORT) |
void | setNeighborServer (char *ServerName) |
void | setStore (int StoreLocally) |
long | getFileSize (FILE *readFile) |
Static Public Attributes | |
const int | DEFAULT_PORT |
const int | THREADED |
Create a thread to handle each client request. | |
const int | NON_THREADED |
Do not create a thread to handle each client request. | |
const int | TRANSFERSIZE |
Static Private Methods | |
int | getHostIPNumber (char *hostNameOrIP) |
void* | threadHandler (void *) |
Private Attributes | |
CAVERNnet_extendedTcpServer_c | server |
char | neighborServerName [MAXPATHLEN] |
int | neighborPortNumber |
int | store |
Note: currently there exists a strange behavior in threads that causes the network I/O to improperly complete. Hence checkForNewRequests() currently does not create a new thread for each client that makes an IO request. All clients must wait in line.
|
Check for incoming requests. Recommend doing this in a while loop.
|
|
Default port number to listen on. Default is 8000. |