This class is used to set up a server for remote file I/O. The init() method is called first and then we cam use process() to locate any clients wanting to perform remote I/O.
QUANTAnet_remoteFileIOClient32_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.
The client.cxx also shows how the class 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
Download remote file:
client <hostname> -d localfilename remotefilename
Remote File List:
client <hostname> -f remotePathname -r(optional)
for more information: Post your questions online on the Quanta forum page.