[ROOT] --> C++Client
The PCREFileServer class provides FTP manangement for the C++ client.
friend class PCREClient ; | |
friend class PCREAppClient ; |
PCREFileServer
PCREFileServer
PCREFileServer
CloseFTP
Connect
CreateDirectory
DeleteFile
DeleteLocalFile
Disconnect
GetCurrentDir
GetFile
GetFile
GetFiles
GetFiles
getFTPPassword
getFTPPortNumber
getFTPRootDir
getFTPUsername
getService
IsFTPConnected
OpenFTP
PurgeDirectory
PutFile
PutFile
PutFiles
RemoveDirectory
RenameFile
SetCurrentDir
useAnonymousFTP
Validate
PCREFileServer ( const char* host , const char* name ) ;
Request a PCREFileServer with the given host and server name.
| host | The host machine. |
| name | The server name. |
PCREFileServer ( const char * host ) ;
Request a PCREFileServer with the given host.
| host | The host machine. |
PCREFileServer ( ) ;
Request a PCREFileServer.
const char * getService ( ) ;
Retrieve the name of this service.
BOOL Validate ( ) ;
Validate the file-transfer service provided by the report-server.
void Connect ( ) ;
Connect client to file server.
void Disconnect ( ) ;
Terminate the connection to this server.
char * getFTPRootDir ( ) ;
Retrieve FTP Server's root directory.
BOOL useAnonymousFTP ( ) ;
Retrieve the anonymous login permission.
int getFTPPortNumber ( ) ;
Retrieve the FTP Server's port-number.
char * getFTPUsername ( ) ;
Retrieve the FTP Server's user-name
char * getFTPPassword ( ) ;
Retrieve the FTP Server's password.
void OpenFTP ( char * username ,
char * password ,
int port = 21) ) ;
Open a connection to the FTP Server using the supplied username and password.
| username | The username to use when loggin onto the server. |
| password | The password associated with the supplied username. |
BOOL IsFTPConnected ( ) ;
Query the connection state of the FTP server.
void CloseFTP ( ) ;
Close the connection to the FTP Server.
void GetFile ( char * remoteFile ) ;
Retrieve a file from the remote server, give it the same name locally.
| remoteFile | The name of the remote file to retrieve. |
void GetFile ( char * remoteFile ,
char * localFile ) ;
Retrieve a file from the remote server, give it the different name locally.
| remoteFile | The name of the remote file to retrieve. |
| localFile | The place to save the retrieved file locally. |
void GetFiles ( char * remoteFileRegexp ,
BOOL del = FALSE ) ;
Retrieve multiple files from the remote server.
| remoteFileRegexp | The pattern for files to be retrieving. This is a regular expression. |
| del | If this is TRUE, delete the files after retrieving them. |
void GetFiles ( char * localDirectory ,
char * remoteFileRegexp ,
BOOL del = FALSE ) ;
Retrieve multiple files from the remote server, storing them in a named local directory.
| localDirectory | The directory to store the files into locally. |
| remoteFileRegexp | The pattern for files to be retrieving. This is a regular expression. |
| del | If this is TRUE, delete the files after retrieving them. |
void PutFile ( char * localFile ) ;
Store a file on the remote server, give it the same name as it has locally.
| localFile | The name of the local file to store. |
void PutFile ( char * localFile ,
char * remoteFile ) ;
Store a file on the remote server.
| localFile | The name of the local file to store. |
| remoteFile | The name to give the file remotely. |
void PutFiles ( char * localFileRegexp ,
BOOL del = FALSE ) ;
Store multiple files on the remote server.
| localFileRegexp | The pattern for files to be stored. This is a wildcard pattern. |
char * GetCurrentDir ( ) ;
Get the current directory.
void SetCurrentDir ( char * dirName ) ;
Change directory on the remote server.
| dirName | The name of the directory to change to. |
void DeleteFile ( char * fileName ) ;
Delete a remote file.
| fileName | The name of the file to delete. |
void DeleteLocalFile ( char * fileName ) ;
Delete a LOCAL file.
| fileName | The name of the local file to delete. |
void RenameFile ( char * oldName ,
char * newName ) ;
Rename a remote file.
| oldName | The name of the file to rename. |
| newName | The new name to call this file. |
void RemoveDirectory ( char * dirName ) ;
Remove a remote directory [MUST by empty]
| dirName | The name of the remote directory to delete. |
void CreateDirectory ( char * dirName ) ;
Create a remote directory.
| dirName | The name of the remote directory to create. |
void PurgeDirectory ( ) ;
Delete all files in the current directory. This does NOT include any subdirectories.