OFTPClient Class

Properties   Methods   Events   Configuration Settings   Errors  

The OFTPClient class implements the Odette File Transfer Protocol.

Syntax

ipworksedi.Oftpclient

Remarks

The OFTPClient component may be used to send and receive OFTP files to and from an OFTP server.

Receiving Files

The OFTPClient ReceiveFiles function requires certain server properties be set. You must set the RemoteHost property to the remote location of the desired OFTP server. You may also set a RemotePort if the server is not set to the default protocol port. For client authorization, you must set the ClientSSIDCode, ClientSFIDCode, and ClientPassword properties. And, for server authentication, you must set the ServerSSIDCode, ServerSFIDCode, and ServerPassword properties.

The class will connect to the OFTP server and download all files in the server's outgoing queue, and write these files to the directory specified by DownloadDirectory. The class creates a default location on the local machine based on the values of the DownloadDirectory and the Virtual Filename as received from the server. If a different location is preferred, you may set the LocalFile parameter of the StartTransfer event.

Sending Files

The OFTPClient SendFile function requires the same server and authentication properties to be set as the ReceiveFiles function.

The class will connect to the OFTP server and upload the file contained by the LocalFile parameter. It uses the name specified by VirtualFileName when sending to the server. If this is not specified, the filename of the local file is parsed and used as the virtual filename.

Property List


The following is the full list of the properties of the class with short descriptions. Click on the links for further details.

CertificateThe current selected certificate.
ClientPasswordThe client's password.
ClientSFIDCodeClient's SFID code.
ClientSSIDCodeThe client's SSID code.
CompressWhether or not to compress the outgoing file.
ConnectedShows whether the class is connected.
DownloadDirectoryDownload directory.
EncryptionAlgorithmThe encryption algorithm.
FirewallA set of properties related to firewall access.
LocalHostThe name of the local host or user-assigned IP interface through which connections are initiated or accepted.
MaxRecordSizeThe maximum length of a given record.
OverwriteWhether or not the class should overwrite files during transfer.
RecipientCertThe recipient certificate of the message.
RemoteHostThe domain name or IP address of the OFTP server.
RemotePortThe port for the OFTP service (default is 3305).
SecureAuthenticationWhether or not the class should perform secure Odette authentication.
ServerPasswordThe server's password.
ServerSFIDCodeServer's SFID code.
ServerSSIDCodeThe server's SSID code.
SignedReceiptWhether or not to require signed receipts.
SSLAcceptServerCertInstructs the class to unconditionally accept the server certificate that matches the supplied certificate.
SSLCertThe certificate to be used during SSL negotiation.
TimeoutA timeout for the class.
TrustedCertsA collection of trusted CA certificates.
UseSSLUse SSL to access the RemoteHost .
VersionWhich version of the OFTP protocol the class is using.
VirtualFileDateThe date/time stamp for the virtual file.
VirtualFileFormatThe structure of the outgoing file.
VirtualFileSecurityLevelThe level of security for the file.

Method List


The following is the full list of the methods of the class with short descriptions. Click on the links for further details.

ChangeDirectionSends a Change Direction (CD) command.
ConfigSets or retrieves a configuration setting.
DoEventsProcesses events from the internal message queue.
ExchangeCertificateExchange a certificate with the remote host.
ImportTrustedCertsImports a list of trusted CA certificates.
InterruptInterrupts the current action.
LogoffLogoff from the OFTP server.
LogonLogon to the OFTP RemoteHost using the current client credentials.
ReceiveFilesReceive any files queued to be sent from the server.
ResetResets the state of the control.
SendEndResponseSends an EERP/NERP asynchronously.
SendFileSend the specified file to the server.
SetDownloadStreamSets the stream to which the downloaded file is written.
SetUploadStreamSets the stream to be uploaded to the server.

Event List


The following is the full list of the events fired by the class with short descriptions. Click on the links for further details.

AcceptFileFired when the client receives a file.
CertificateReceivedFired when a certificate is received from the remote host.
EndResponseFired every time an end response is received from the server.
EndTransferFired when a file finishes transferring.
ErrorInformation about errors during data delivery.
PITrailFired when any protocol level communication occurs.
SSLServerAuthenticationFired after the server presents its certificate to the client.
SSLStatusShows the progress of the secure connection.
StartTransferFired when a document starts transferring.
TransferFired while a document transfers (delivers document).

Configuration Settings


The following is a list of configuration settings for the class with short descriptions. Click on the links for further details.

AcceptAnySFIDCodeIndicates that all SFID codes are acceptable.
AllowRetryWhether to send a retry indicator when rejecting a file.
CertificateTypeSpecifies the type of certificate being supplied.
ConnectionTypeSpecifies the type of connection that will be created.
CreditCountSpecifies the credit value.
DeleteOnErrorWhether received files are deleted when there is an error during processing.
DisconnectAfterEndSessionDetermines if the connection is closed immediately after ending the session.
EnforceProtocolVersionRequires the server to support the same OFTP version.
ExchangeBufferSizeSpecifies the data exchange buffer size in bytes.
ExchangeCertStoreTypeSpecifies the store type when loading a certificate to be exchanged.
ExchangeCertSubjectThe subject of the certificate being exchanged.
FailOnUntrustedCertWhether or not to throw an exception when untrusted certificates are used.
FileDescriptionAdditional description information sent with the file.
FileHashAlgorithmThe hash algorithm to use when sending a file.
FireEndResponseOnSendDetermines if the EndResponse event is fired for outgoing EERP and NERPs.
FollowRedirectsDetermines behavior when importing trusted certificates and a HTTP redirect is returned.
FriendlyLogFormatDetermines if a more friendly format is applied to PITrail event out.
MaskSensitiveMasks passwords in logs.
ReceiptHashAlgorithmThe receipt hash algorithm to request when sending a file.
ReceivedFileDateTimeThe datetime of the file being received.
ReceivedFileDescriptionAdditional description information received with the file.
ReceivedFileEncryptionAlgThe encryption algorithm used for the file being received.
ReceivedFileNameReturns the name of the received file.
ReceivedFileNameFormatThe name format of received files.
ReceivedFileNameFormatThe name format of received files.
RecipientCertificateTypeSpecifies the type of recipient certificate being supplied.
RetryIndicates whether the recipient allows the send to be retried.
SendCDAfterEFPASpecifies whether a CD is always sent after receiving an EFPA.
TempPathThe path of a directory where temporary files will be created.
TrustedCertsDataSpecifies the source to be used when importing trusted certificates.
VirtualFileDateFormatThe DateTime format of received files.
BuildInfoInformation about the product's build.
GUIAvailableTells the class whether or not a message loop is available for processing events.
LicenseInfoInformation about the current license.
UseDaemonThreadsWhether threads created by the class are daemon threads.
UseInternalSecurityAPITells the class whether or not to use the system security libraries or an internal implementation.

Copyright (c) 2022 /n software inc. - All rights reserved.
IPWorks EDI 2020 Java Edition - Version 20.0 [Build 8203]