Executes a commando that result in a communication over the data port. @param[in] crDatachannelCmd Command to be executeted. @param[in] Observer Object for observing the execution of the command. @param[in] sckDataConnection Socket which is used for sending/receiving data.
| 925 | /// @param[in] Observer Object for observing the execution of the command. |
| 926 | /// @param[in] sckDataConnection Socket which is used for sending/receiving data. |
| 927 | bool CFTPClient::TransferData(const CCommand& crDatachannelCmd, ITransferNotification& Observer, IBlockingSocket& sckDataConnection) const |
| 928 | { |
| 929 | if( crDatachannelCmd.IsDatachannelWriteCommand() ) |
| 930 | { |
| 931 | if( !SendData(Observer, sckDataConnection) ) |
| 932 | return false; |
| 933 | } |
| 934 | else if( crDatachannelCmd.IsDatachannelReadCommand() ) |
| 935 | { |
| 936 | if( !ReceiveData(Observer, sckDataConnection) ) |
| 937 | return false; |
| 938 | } |
| 939 | else |
| 940 | { |
| 941 | ASSERT( false ); |
| 942 | return false; |
| 943 | } |
| 944 | return true; |
| 945 | } |
| 946 | |
| 947 | /// Opens an active data connection. |
| 948 | /// @param[out] sckDataConnection |
nothing calls this directly
no test coverage detected