This class is used to set up a server for remote file I/O. The init() method is called first with the port numbers and number of parallel sockets used. Then we can use process() to locate any clients wanting to perform remote I/O.
QUANTAnet_parallelRemoteFileIOClient32_c
A client instantiated using this class can upload() or download() files to the remote server established above. You can access the timestamp on the local file using getLocalDateTime() or on the remote file using getRemoteDateTime() , and then find out which of the two files is the latest by comparing the timestamps with compareDateTime() . Use getRemoteFileList() to obtain a list of files on the remote machine in a certain path.
In the demo programs, servertcp.cxx
sets up the TCP server and client.cxx tries to download a file from
a remote machine. The client compares the timestamp on the downloaded file
and the remote file, and determines if there was any change since the download.
Classes QUANTAmisc_fileInfo_c
and the QUANTAmisc_fileList_c
classes can be used to obtain a list of files in a given path(note : this
will work only on the SGI,LINUX or SUN platforms).
2. To run a client
client <hostname> <localfilename> <remotefilename>
for more information: Post your questions online on the Quanta forum page.