MCPcopy Create free account
hub / github.com/ashkulz/NppFTP / GetFileTransferMode

Method GetFileTransferMode

src/FTPProfile.cpp:531–549  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

529}
530
531Transfer_Mode FTPProfile::GetFileTransferMode(const TCHAR* file) const {
532 LPCTSTR suffix = NULL;
533
534 if (m_asciiTypes.size()) {
535 suffix = PathFindSuffixArray(file, (const TCHAR**)(&m_asciiTypes[0]), static_cast<int>(m_asciiTypes.size()) );
536 if (suffix) {
537 return Mode_ASCII;
538 }
539 }
540
541 if (m_binTypes.size()) {
542 suffix = PathFindSuffixArray(file, (const TCHAR**)(&m_binTypes[0]), static_cast<int>(m_binTypes.size()) );
543 if (suffix) {
544 return Mode_Binary;
545 }
546 }
547
548 return m_transferMode;
549}
550
551int FTPProfile::GetCacheExternal(const TCHAR* localfile, char* extbuffer, int extbuffersize) const {
552 if (!extbuffer || extbuffersize == 0)

Callers 4

DownloadFileMethod · 0.80
DownloadFileHandleMethod · 0.80
UploadFileMethod · 0.80
CopyFileMethod · 0.80

Calls 1

sizeMethod · 0.80

Tested by

no test coverage detected