Skip to main content

FTP Adaptor

Spanish

Introduction

This Adaptor is used to do connections with FTP or SFTP servers and this adaptor is used as a client in a TAST diagram.

Setup

In the initialization process, it's necessary to provide the information to connect with the server.

Initialization Parameters

  • Host: Namename or IP address of the FTP server we want to connect.
  • Port: Portport number on which the FTP server listens.
  • User: Usernameusername we want to use to make the connection.
  • Password: Passwordpassword of the user we want to use to make the connection.
  • Secure: Checkboxcheckbox that indicates whether the connection will be secure or not.

Functions

  • connect(): Itit allows the connection with a new server that is not the same server as the one settled in the adaptor. In case that the old connection is still open, this function closes it. This function uses the following parameters:

    • Host: IP address or name of the FTP server we want to connect.
    • Port: Portport number on which the FTP server listens, if this parameter is not set the adaptor will use the default port to the protocol.
    • User: Usernameusername used to stablish the connection.
    • Password: Passwordpassword of the user used to stablish the connection.
    • Secure: Indicatesindicates if the connection is secure (SFTP) or not (FTP).
  • deleteFile(): Allowsallows to delete a File on the server, it gets a parameter RemoteFilePath to indicate the path and the name of the file that the user wants to delete.

  • disconnect(): Allowsallows the disconnection from the server. This function requires no input parameters.

  • getFile(): Allowsallows to transfer a file from the server to the PC in which the diagram is executed. The parameters used are:

    • RemoteFilePath: Indicatesindicates the path and the name of the remote file we want to recover on the server.
    • LocalFilePath: Indicatesindicates the path and the name of the local file we want to create on the local computer.
    • BinaryFile: Indicatesindicates the type of transfer, Binary if the checkbox is clicked or text if not.

  • putFile(): Allowsallows to transfer a file from the PC to the server in which the diagram is executed. The parameters used are:

    • RemoteFilePath: Indicatesindicates the path and the name of the remote file we want to create on the server.
    • LocalFilePath: Indicatesindicates the path and the name of the local file we want to transfer.
    • BinaryFile: Indicatesindicates the type of transfer, Binary if the checkbox is clicked or text if not.