2d-platformer/vendor/SFML-3.0.0/doc/html/classsf_1_1Ftp.html

1043 lines
68 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>SFML - Simple and Fast Multimedia Library</title>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
<link rel="stylesheet" type="text/css" href="doxygen.css" title="default" media="screen,print" />
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<script type="text/javascript" src="clipboard.js"></script>
<script type="text/javascript" src="cookie.js"></script>
<link rel="stylesheet" type="text/css" href="search/search.css" />
<link rel="stylesheet" type="text/css" href="searchOverrides.css" />
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(document).ready(function() { init_search(); });
/* @license-end */
</script>
</head>
<body>
<div id="banner-container">
<div id="banner">
<span id="sfml">SFML 3.0.0</span>
</div>
</div>
<div id="content">
<div>
<!-- Generated by Doxygen 1.12.0 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search/",'.html');
/* @license-end */
</script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() { codefold.init(0); });
/* @license-end */
</script>
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="index.html"><span>Main&#160;Page</span></a></li>
<li><a href="topics.html"><span>Topics</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
<li>
<div id="MSearchBox" class="MSearchBoxInactive">
<span class="left">
<span id="MSearchSelect" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()">&#160;</span>
<input type="text" id="MSearchField" value="" placeholder="Search" accesskey="S"
onfocus="searchBox.OnSearchFieldFocus(true)"
onblur="searchBox.OnSearchFieldFocus(false)"
onkeyup="searchBox.OnSearchFieldChange(event)"/>
</span><span class="right">
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.svg" alt=""/></a>
</span>
</div>
</li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="annotated.html"><span>Class&#160;List</span></a></li>
<li><a href="classes.html"><span>Class&#160;Index</span></a></li>
<li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
<li><a href="functions.html"><span>Class&#160;Members</span></a></li>
</ul>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function(){ initResizable(false); });
/* @license-end */
</script>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">Loading...</div>
<div class="SRStatus" id="Searching">Searching...</div>
<div class="SRStatus" id="NoMatches">No Matches</div>
</div>
</div>
</div>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="namespacesf.html">sf</a></li><li class="navelem"><a class="el" href="classsf_1_1Ftp.html">Ftp</a></li> </ul>
</div>
</div><!-- top -->
<div id="doc-content">
<div class="header">
<div class="summary">
<a href="#nested-classes">Classes</a> &#124;
<a href="#pub-types">Public Types</a> &#124;
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#friends">Friends</a> &#124;
<a href="classsf_1_1Ftp-members.html">List of all members</a> </div>
<div class="headertitle"><div class="title">sf::Ftp Class Reference<div class="ingroups"><a class="el" href="group__network.html">Network module</a></div></div></div>
</div><!--header-->
<div class="contents">
<p>A FTP client.
<a href="#details">More...</a></p>
<p><code>#include &lt;<a class="el" href="Ftp_8hpp_source.html">SFML/Network/Ftp.hpp</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="nested-classes" name="nested-classes"></a>
Classes</h2></td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1Ftp_1_1DirectoryResponse.html">DirectoryResponse</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Specialization of FTP response returning a directory. <a href="classsf_1_1Ftp_1_1DirectoryResponse.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1Ftp_1_1ListingResponse.html">ListingResponse</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Specialization of FTP response returning a file name listing. <a href="classsf_1_1Ftp_1_1ListingResponse.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">FTP response. <a href="classsf_1_1Ftp_1_1Response.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-types" name="pub-types"></a>
Public Types</h2></td></tr>
<tr class="memitem:a1cd6b89ad23253f6d97e6d4ca4d558cb" id="r_a1cd6b89ad23253f6d97e6d4ca4d558cb"><td class="memItemLeft" align="right" valign="top">enum class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cb">TransferMode</a> { <a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cba6ce976e8f061b2b5cfe4d0c50c3405dd">Binary</a>
, <a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cba76b8d0dcd02ccaf203c167ced6d7ef31">Ascii</a>
, <a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cbae9cd99e58c6a9a4c44b4b8694af338f0">Ebcdic</a>
}</td></tr>
<tr class="memdesc:a1cd6b89ad23253f6d97e6d4ca4d558cb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enumeration of transfer modes. <a href="#a1cd6b89ad23253f6d97e6d4ca4d558cb">More...</a><br /></td></tr>
<tr class="separator:a1cd6b89ad23253f6d97e6d4ca4d558cb"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-methods" name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:ac3fc00b6b4719459d5f5e21c83d58684" id="r_ac3fc00b6b4719459d5f5e21c83d58684"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ac3fc00b6b4719459d5f5e21c83d58684">Ftp</a> ()=default</td></tr>
<tr class="memdesc:ac3fc00b6b4719459d5f5e21c83d58684"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default constructor. <br /></td></tr>
<tr class="separator:ac3fc00b6b4719459d5f5e21c83d58684"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2edfa8e9009caf27bce74459ae76dc52" id="r_a2edfa8e9009caf27bce74459ae76dc52"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a2edfa8e9009caf27bce74459ae76dc52">~Ftp</a> ()</td></tr>
<tr class="memdesc:a2edfa8e9009caf27bce74459ae76dc52"><td class="mdescLeft">&#160;</td><td class="mdescRight">Destructor. <br /></td></tr>
<tr class="separator:a2edfa8e9009caf27bce74459ae76dc52"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aadb86adf5c7b495dfb88382d2608252c" id="r_aadb86adf5c7b495dfb88382d2608252c"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aadb86adf5c7b495dfb88382d2608252c">Ftp</a> (const <a class="el" href="classsf_1_1Ftp.html">Ftp</a> &amp;)=delete</td></tr>
<tr class="memdesc:aadb86adf5c7b495dfb88382d2608252c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Deleted copy constructor. <br /></td></tr>
<tr class="separator:aadb86adf5c7b495dfb88382d2608252c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:add953d6d8524b3914f984c0c5eef1492" id="r_add953d6d8524b3914f984c0c5eef1492"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp.html">Ftp</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#add953d6d8524b3914f984c0c5eef1492">operator=</a> (const <a class="el" href="classsf_1_1Ftp.html">Ftp</a> &amp;)=delete</td></tr>
<tr class="memdesc:add953d6d8524b3914f984c0c5eef1492"><td class="mdescLeft">&#160;</td><td class="mdescRight">Deleted copy assignment. <br /></td></tr>
<tr class="separator:add953d6d8524b3914f984c0c5eef1492"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4bf67543024815d11717ffe02cb8e1ef" id="r_a4bf67543024815d11717ffe02cb8e1ef"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a4bf67543024815d11717ffe02cb8e1ef">connect</a> (<a class="el" href="classsf_1_1IpAddress.html">IpAddress</a> server, unsigned short port=21, <a class="el" href="classsf_1_1Time.html">Time</a> timeout=<a class="el" href="classsf_1_1Time.html#a8db127b632fa8da21550e7282af11fa0">Time::Zero</a>)</td></tr>
<tr class="memdesc:a4bf67543024815d11717ffe02cb8e1ef"><td class="mdescLeft">&#160;</td><td class="mdescRight">Connect to the specified FTP server. <br /></td></tr>
<tr class="separator:a4bf67543024815d11717ffe02cb8e1ef"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acf7459926f3391cd06bf84337ed6a0f4" id="r_acf7459926f3391cd06bf84337ed6a0f4"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#acf7459926f3391cd06bf84337ed6a0f4">disconnect</a> ()</td></tr>
<tr class="memdesc:acf7459926f3391cd06bf84337ed6a0f4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Close the connection with the server. <br /></td></tr>
<tr class="separator:acf7459926f3391cd06bf84337ed6a0f4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a686262bc377584cd50e52e1576aa3a9b" id="r_a686262bc377584cd50e52e1576aa3a9b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a686262bc377584cd50e52e1576aa3a9b">login</a> ()</td></tr>
<tr class="memdesc:a686262bc377584cd50e52e1576aa3a9b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Log in using an anonymous account. <br /></td></tr>
<tr class="separator:a686262bc377584cd50e52e1576aa3a9b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a99d8114793c1659e9d51d45cecdcd965" id="r_a99d8114793c1659e9d51d45cecdcd965"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a99d8114793c1659e9d51d45cecdcd965">login</a> (const std::string &amp;name, const std::string &amp;password)</td></tr>
<tr class="memdesc:a99d8114793c1659e9d51d45cecdcd965"><td class="mdescLeft">&#160;</td><td class="mdescRight">Log in using a username and a password. <br /></td></tr>
<tr class="separator:a99d8114793c1659e9d51d45cecdcd965"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa1127d442b4acb2105aa8060a39d04fc" id="r_aa1127d442b4acb2105aa8060a39d04fc"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aa1127d442b4acb2105aa8060a39d04fc">keepAlive</a> ()</td></tr>
<tr class="memdesc:aa1127d442b4acb2105aa8060a39d04fc"><td class="mdescLeft">&#160;</td><td class="mdescRight">Send a null command to keep the connection alive. <br /></td></tr>
<tr class="separator:aa1127d442b4acb2105aa8060a39d04fc"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a79c654fcdd0c81e68c4fa29af3b45e0c" id="r_a79c654fcdd0c81e68c4fa29af3b45e0c"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1DirectoryResponse.html">DirectoryResponse</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a79c654fcdd0c81e68c4fa29af3b45e0c">getWorkingDirectory</a> ()</td></tr>
<tr class="memdesc:a79c654fcdd0c81e68c4fa29af3b45e0c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the current working directory. <br /></td></tr>
<tr class="separator:a79c654fcdd0c81e68c4fa29af3b45e0c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8f37258e461fcb9e2a0655e9df0be4a0" id="r_a8f37258e461fcb9e2a0655e9df0be4a0"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1ListingResponse.html">ListingResponse</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a8f37258e461fcb9e2a0655e9df0be4a0">getDirectoryListing</a> (const std::string &amp;directory=&quot;&quot;)</td></tr>
<tr class="memdesc:a8f37258e461fcb9e2a0655e9df0be4a0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the contents of the given directory. <br /></td></tr>
<tr class="separator:a8f37258e461fcb9e2a0655e9df0be4a0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7e93488ea6330dd4dd76e428da9bb6d3" id="r_a7e93488ea6330dd4dd76e428da9bb6d3"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a7e93488ea6330dd4dd76e428da9bb6d3">changeDirectory</a> (const std::string &amp;directory)</td></tr>
<tr class="memdesc:a7e93488ea6330dd4dd76e428da9bb6d3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Change the current working directory. <br /></td></tr>
<tr class="separator:a7e93488ea6330dd4dd76e428da9bb6d3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad295cf77f30f9ad07b5c401fd9849189" id="r_ad295cf77f30f9ad07b5c401fd9849189"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ad295cf77f30f9ad07b5c401fd9849189">parentDirectory</a> ()</td></tr>
<tr class="memdesc:ad295cf77f30f9ad07b5c401fd9849189"><td class="mdescLeft">&#160;</td><td class="mdescRight">Go to the parent directory of the current one. <br /></td></tr>
<tr class="separator:ad295cf77f30f9ad07b5c401fd9849189"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a247b84c4b25da37804218c2b748c4787" id="r_a247b84c4b25da37804218c2b748c4787"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a247b84c4b25da37804218c2b748c4787">createDirectory</a> (const std::string &amp;name)</td></tr>
<tr class="memdesc:a247b84c4b25da37804218c2b748c4787"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create a new directory. <br /></td></tr>
<tr class="separator:a247b84c4b25da37804218c2b748c4787"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2a8a7ef9144204b5b319c9a4be8806c2" id="r_a2a8a7ef9144204b5b319c9a4be8806c2"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a2a8a7ef9144204b5b319c9a4be8806c2">deleteDirectory</a> (const std::string &amp;name)</td></tr>
<tr class="memdesc:a2a8a7ef9144204b5b319c9a4be8806c2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Remove an existing directory. <br /></td></tr>
<tr class="separator:a2a8a7ef9144204b5b319c9a4be8806c2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a96cff0afc5d03e60452f7356f1cac7f2" id="r_a96cff0afc5d03e60452f7356f1cac7f2"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a96cff0afc5d03e60452f7356f1cac7f2">renameFile</a> (const std::filesystem::path &amp;file, const std::filesystem::path &amp;newName)</td></tr>
<tr class="memdesc:a96cff0afc5d03e60452f7356f1cac7f2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Rename an existing file. <br /></td></tr>
<tr class="separator:a96cff0afc5d03e60452f7356f1cac7f2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1dad32d3fe649b9f60a91ace18f440e7" id="r_a1dad32d3fe649b9f60a91ace18f440e7"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a1dad32d3fe649b9f60a91ace18f440e7">deleteFile</a> (const std::filesystem::path &amp;name)</td></tr>
<tr class="memdesc:a1dad32d3fe649b9f60a91ace18f440e7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Remove an existing file. <br /></td></tr>
<tr class="separator:a1dad32d3fe649b9f60a91ace18f440e7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a960cae5522a9b90585536abf20b17543" id="r_a960cae5522a9b90585536abf20b17543"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a960cae5522a9b90585536abf20b17543">download</a> (const std::filesystem::path &amp;remoteFile, const std::filesystem::path &amp;localPath, <a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cb">TransferMode</a> mode=<a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cba6ce976e8f061b2b5cfe4d0c50c3405dd">TransferMode::Binary</a>)</td></tr>
<tr class="memdesc:a960cae5522a9b90585536abf20b17543"><td class="mdescLeft">&#160;</td><td class="mdescRight">Download a file from the server. <br /></td></tr>
<tr class="separator:a960cae5522a9b90585536abf20b17543"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adcc40761d3061e5b0d9d208eb5420f9b" id="r_adcc40761d3061e5b0d9d208eb5420f9b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#adcc40761d3061e5b0d9d208eb5420f9b">upload</a> (const std::filesystem::path &amp;localFile, const std::filesystem::path &amp;remotePath, <a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cb">TransferMode</a> mode=<a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cba6ce976e8f061b2b5cfe4d0c50c3405dd">TransferMode::Binary</a>, bool append=false)</td></tr>
<tr class="memdesc:adcc40761d3061e5b0d9d208eb5420f9b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Upload a file to the server. <br /></td></tr>
<tr class="separator:adcc40761d3061e5b0d9d208eb5420f9b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a44e095103ecbce175a33eaf0820440ff" id="r_a44e095103ecbce175a33eaf0820440ff"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a44e095103ecbce175a33eaf0820440ff">sendCommand</a> (const std::string &amp;command, const std::string &amp;parameter=&quot;&quot;)</td></tr>
<tr class="memdesc:a44e095103ecbce175a33eaf0820440ff"><td class="mdescLeft">&#160;</td><td class="mdescRight">Send a command to the FTP server. <br /></td></tr>
<tr class="separator:a44e095103ecbce175a33eaf0820440ff"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="friends" name="friends"></a>
Friends</h2></td></tr>
<tr class="memitem:a8dee57337b6a7e183bfe21d178757b0c" id="r_a8dee57337b6a7e183bfe21d178757b0c"><td class="memItemLeft" align="right" valign="top">class&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a8dee57337b6a7e183bfe21d178757b0c">DataChannel</a></td></tr>
<tr class="separator:a8dee57337b6a7e183bfe21d178757b0c"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>A FTP client. </p>
<p><code><a class="el" href="classsf_1_1Ftp.html" title="A FTP client.">sf::Ftp</a></code> is a very simple FTP client that allows you to communicate with a FTP server.</p>
<p>The FTP protocol allows you to manipulate a remote file system (list files, upload, download, create, remove, ...).</p>
<p>Using the FTP client consists of 4 parts: </p><ul>
<li>Connecting to the FTP server </li>
<li>Logging in (either as a registered user or anonymously) </li>
<li>Sending commands to the server </li>
<li>Disconnecting (this part can be done implicitly by the destructor)</li>
</ul>
<p>Every command returns a FTP response, which contains the status code as well as a message from the server. Some commands such as <code><a class="el" href="#a79c654fcdd0c81e68c4fa29af3b45e0c" title="Get the current working directory.">getWorkingDirectory()</a></code> and <code><a class="el" href="#a8f37258e461fcb9e2a0655e9df0be4a0" title="Get the contents of the given directory.">getDirectoryListing()</a></code> return additional data, and use a class derived from <code><a class="el" href="classsf_1_1Ftp_1_1Response.html" title="FTP response.">sf::Ftp::Response</a></code> to provide this data. The most often used commands are directly provided as member functions, but it is also possible to use specific commands with the <code><a class="el" href="#a44e095103ecbce175a33eaf0820440ff" title="Send a command to the FTP server.">sendCommand()</a></code> function.</p>
<p>Note that response statuses &gt;= 1000 are not part of the FTP standard, they are generated by SFML when an internal error occurs.</p>
<p>All commands, especially upload and download, may take some time to complete. This is important to know if you don't want to block your application while the server is completing the task.</p>
<p>Usage example: </p><div class="fragment"><div class="line"><span class="comment">// Create a new FTP client</span></div>
<div class="line"><a class="code hl_class" href="classsf_1_1Ftp.html">sf::Ftp</a> ftp;</div>
<div class="line"> </div>
<div class="line"><span class="comment">// Connect to the server</span></div>
<div class="line"><a class="code hl_class" href="classsf_1_1Ftp_1_1Response.html">sf::Ftp::Response</a> response = ftp.<a class="code hl_function" href="#a4bf67543024815d11717ffe02cb8e1ef">connect</a>(<span class="stringliteral">&quot;ftp://ftp.myserver.com&quot;</span>);</div>
<div class="line"><span class="keywordflow">if</span> (response.<a class="code hl_function" href="classsf_1_1Ftp_1_1Response.html#a5102552955a2652c1a39e9046e617b36">isOk</a>())</div>
<div class="line"> std::cout &lt;&lt; <span class="stringliteral">&quot;Connected&quot;</span> &lt;&lt; std::endl;</div>
<div class="line"> </div>
<div class="line"><span class="comment">// Log in</span></div>
<div class="line">response = ftp.<a class="code hl_function" href="#a686262bc377584cd50e52e1576aa3a9b">login</a>(<span class="stringliteral">&quot;laurent&quot;</span>, <span class="stringliteral">&quot;dF6Zm89D&quot;</span>);</div>
<div class="line"><span class="keywordflow">if</span> (response.<a class="code hl_function" href="classsf_1_1Ftp_1_1Response.html#a5102552955a2652c1a39e9046e617b36">isOk</a>())</div>
<div class="line"> std::cout &lt;&lt; <span class="stringliteral">&quot;Logged in&quot;</span> &lt;&lt; std::endl;</div>
<div class="line"> </div>
<div class="line"><span class="comment">// Print the working directory</span></div>
<div class="line"><a class="code hl_class" href="classsf_1_1Ftp_1_1DirectoryResponse.html">sf::Ftp::DirectoryResponse</a> directory = ftp.<a class="code hl_function" href="#a79c654fcdd0c81e68c4fa29af3b45e0c">getWorkingDirectory</a>();</div>
<div class="line"><span class="keywordflow">if</span> (directory.<a class="code hl_function" href="classsf_1_1Ftp_1_1Response.html#a5102552955a2652c1a39e9046e617b36">isOk</a>())</div>
<div class="line"> std::cout &lt;&lt; <span class="stringliteral">&quot;Working directory: &quot;</span> &lt;&lt; directory.<a class="code hl_function" href="classsf_1_1Ftp_1_1DirectoryResponse.html#a407f96f0a473f52d9b12b5bf2505a5d5">getDirectory</a>() &lt;&lt; std::endl;</div>
<div class="line"> </div>
<div class="line"><span class="comment">// Create a new directory</span></div>
<div class="line">response = ftp.<a class="code hl_function" href="#a247b84c4b25da37804218c2b748c4787">createDirectory</a>(<span class="stringliteral">&quot;files&quot;</span>);</div>
<div class="line"><span class="keywordflow">if</span> (response.<a class="code hl_function" href="classsf_1_1Ftp_1_1Response.html#a5102552955a2652c1a39e9046e617b36">isOk</a>())</div>
<div class="line"> std::cout &lt;&lt; <span class="stringliteral">&quot;Created new directory&quot;</span> &lt;&lt; std::endl;</div>
<div class="line"> </div>
<div class="line"><span class="comment">// Upload a file to this new directory</span></div>
<div class="line">response = ftp.<a class="code hl_function" href="#adcc40761d3061e5b0d9d208eb5420f9b">upload</a>(<span class="stringliteral">&quot;local-path/file.txt&quot;</span>, <span class="stringliteral">&quot;files&quot;</span>, <a class="code hl_enumvalue" href="#a1cd6b89ad23253f6d97e6d4ca4d558cba76b8d0dcd02ccaf203c167ced6d7ef31">sf::Ftp::TransferMode::Ascii</a>);</div>
<div class="line"><span class="keywordflow">if</span> (response.<a class="code hl_function" href="classsf_1_1Ftp_1_1Response.html#a5102552955a2652c1a39e9046e617b36">isOk</a>())</div>
<div class="line"> std::cout &lt;&lt; <span class="stringliteral">&quot;File uploaded&quot;</span> &lt;&lt; std::endl;</div>
<div class="line"> </div>
<div class="line"><span class="comment">// Send specific commands (here: FEAT to list supported FTP features)</span></div>
<div class="line">response = ftp.<a class="code hl_function" href="#a44e095103ecbce175a33eaf0820440ff">sendCommand</a>(<span class="stringliteral">&quot;FEAT&quot;</span>);</div>
<div class="line"><span class="keywordflow">if</span> (response.<a class="code hl_function" href="classsf_1_1Ftp_1_1Response.html#a5102552955a2652c1a39e9046e617b36">isOk</a>())</div>
<div class="line"> std::cout &lt;&lt; <span class="stringliteral">&quot;Feature list:\n&quot;</span> &lt;&lt; response.<a class="code hl_function" href="classsf_1_1Ftp_1_1Response.html#adc2890c93c9f8ee997b828fcbef82c97">getMessage</a>() &lt;&lt; std::endl;</div>
<div class="line"> </div>
<div class="line"><span class="comment">// Disconnect from the server (optional)</span></div>
<div class="line">ftp.<a class="code hl_function" href="#acf7459926f3391cd06bf84337ed6a0f4">disconnect</a>();</div>
<div class="ttc" id="aclasssf_1_1Ftp_1_1DirectoryResponse_html"><div class="ttname"><a href="classsf_1_1Ftp_1_1DirectoryResponse.html">sf::Ftp::DirectoryResponse</a></div><div class="ttdoc">Specialization of FTP response returning a directory.</div><div class="ttdef"><b>Definition</b> <a href="Ftp_8hpp_source.html#l00187">Ftp.hpp:188</a></div></div>
<div class="ttc" id="aclasssf_1_1Ftp_1_1DirectoryResponse_html_a407f96f0a473f52d9b12b5bf2505a5d5"><div class="ttname"><a href="classsf_1_1Ftp_1_1DirectoryResponse.html#a407f96f0a473f52d9b12b5bf2505a5d5">sf::Ftp::DirectoryResponse::getDirectory</a></div><div class="ttdeci">const std::filesystem::path &amp; getDirectory() const</div><div class="ttdoc">Get the directory returned in the response.</div></div>
<div class="ttc" id="aclasssf_1_1Ftp_1_1Response_html"><div class="ttname"><a href="classsf_1_1Ftp_1_1Response.html">sf::Ftp::Response</a></div><div class="ttdoc">FTP response.</div><div class="ttdef"><b>Definition</b> <a href="Ftp_8hpp_source.html#l00067">Ftp.hpp:68</a></div></div>
<div class="ttc" id="aclasssf_1_1Ftp_1_1Response_html_a5102552955a2652c1a39e9046e617b36"><div class="ttname"><a href="classsf_1_1Ftp_1_1Response.html#a5102552955a2652c1a39e9046e617b36">sf::Ftp::Response::isOk</a></div><div class="ttdeci">bool isOk() const</div><div class="ttdoc">Check if the status code means a success.</div></div>
<div class="ttc" id="aclasssf_1_1Ftp_1_1Response_html_adc2890c93c9f8ee997b828fcbef82c97"><div class="ttname"><a href="classsf_1_1Ftp_1_1Response.html#adc2890c93c9f8ee997b828fcbef82c97">sf::Ftp::Response::getMessage</a></div><div class="ttdeci">const std::string &amp; getMessage() const</div><div class="ttdoc">Get the full message contained in the response.</div></div>
<div class="ttc" id="aclasssf_1_1Ftp_html"><div class="ttname"><a href="classsf_1_1Ftp.html">sf::Ftp</a></div><div class="ttdoc">A FTP client.</div><div class="ttdef"><b>Definition</b> <a href="Ftp_8hpp_source.html#l00049">Ftp.hpp:50</a></div></div>
<div class="ttc" id="aclasssf_1_1Ftp_html_a1cd6b89ad23253f6d97e6d4ca4d558cba76b8d0dcd02ccaf203c167ced6d7ef31"><div class="ttname"><a href="#a1cd6b89ad23253f6d97e6d4ca4d558cba76b8d0dcd02ccaf203c167ced6d7ef31">sf::Ftp::TransferMode::Ascii</a></div><div class="ttdeci">@ Ascii</div><div class="ttdoc">Text mode using ASCII encoding.</div></div>
<div class="ttc" id="aclasssf_1_1Ftp_html_a247b84c4b25da37804218c2b748c4787"><div class="ttname"><a href="#a247b84c4b25da37804218c2b748c4787">sf::Ftp::createDirectory</a></div><div class="ttdeci">Response createDirectory(const std::string &amp;name)</div><div class="ttdoc">Create a new directory.</div></div>
<div class="ttc" id="aclasssf_1_1Ftp_html_a44e095103ecbce175a33eaf0820440ff"><div class="ttname"><a href="#a44e095103ecbce175a33eaf0820440ff">sf::Ftp::sendCommand</a></div><div class="ttdeci">Response sendCommand(const std::string &amp;command, const std::string &amp;parameter=&quot;&quot;)</div><div class="ttdoc">Send a command to the FTP server.</div></div>
<div class="ttc" id="aclasssf_1_1Ftp_html_a4bf67543024815d11717ffe02cb8e1ef"><div class="ttname"><a href="#a4bf67543024815d11717ffe02cb8e1ef">sf::Ftp::connect</a></div><div class="ttdeci">Response connect(IpAddress server, unsigned short port=21, Time timeout=Time::Zero)</div><div class="ttdoc">Connect to the specified FTP server.</div></div>
<div class="ttc" id="aclasssf_1_1Ftp_html_a686262bc377584cd50e52e1576aa3a9b"><div class="ttname"><a href="#a686262bc377584cd50e52e1576aa3a9b">sf::Ftp::login</a></div><div class="ttdeci">Response login()</div><div class="ttdoc">Log in using an anonymous account.</div></div>
<div class="ttc" id="aclasssf_1_1Ftp_html_a79c654fcdd0c81e68c4fa29af3b45e0c"><div class="ttname"><a href="#a79c654fcdd0c81e68c4fa29af3b45e0c">sf::Ftp::getWorkingDirectory</a></div><div class="ttdeci">DirectoryResponse getWorkingDirectory()</div><div class="ttdoc">Get the current working directory.</div></div>
<div class="ttc" id="aclasssf_1_1Ftp_html_acf7459926f3391cd06bf84337ed6a0f4"><div class="ttname"><a href="#acf7459926f3391cd06bf84337ed6a0f4">sf::Ftp::disconnect</a></div><div class="ttdeci">Response disconnect()</div><div class="ttdoc">Close the connection with the server.</div></div>
<div class="ttc" id="aclasssf_1_1Ftp_html_adcc40761d3061e5b0d9d208eb5420f9b"><div class="ttname"><a href="#adcc40761d3061e5b0d9d208eb5420f9b">sf::Ftp::upload</a></div><div class="ttdeci">Response upload(const std::filesystem::path &amp;localFile, const std::filesystem::path &amp;remotePath, TransferMode mode=TransferMode::Binary, bool append=false)</div><div class="ttdoc">Upload a file to the server.</div></div>
</div><!-- fragment -->
<p class="definition">Definition at line <a class="el" href="Ftp_8hpp_source.html#l00049">49</a> of file <a class="el" href="Ftp_8hpp_source.html">Ftp.hpp</a>.</p>
</div><h2 class="groupheader">Member Enumeration Documentation</h2>
<a id="a1cd6b89ad23253f6d97e6d4ca4d558cb" name="a1cd6b89ad23253f6d97e6d4ca4d558cb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1cd6b89ad23253f6d97e6d4ca4d558cb">&#9670;&#160;</a></span>TransferMode</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">enum class <a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cb">sf::Ftp::TransferMode</a></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">strong</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Enumeration of transfer modes. </p>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><a id="a1cd6b89ad23253f6d97e6d4ca4d558cba6ce976e8f061b2b5cfe4d0c50c3405dd" name="a1cd6b89ad23253f6d97e6d4ca4d558cba6ce976e8f061b2b5cfe4d0c50c3405dd"></a>Binary&#160;</td><td class="fielddoc"><p>Binary mode (file is transferred as a sequence of bytes) </p>
</td></tr>
<tr><td class="fieldname"><a id="a1cd6b89ad23253f6d97e6d4ca4d558cba76b8d0dcd02ccaf203c167ced6d7ef31" name="a1cd6b89ad23253f6d97e6d4ca4d558cba76b8d0dcd02ccaf203c167ced6d7ef31"></a>Ascii&#160;</td><td class="fielddoc"><p><a class="el" href="classsf_1_1Text.html" title="Graphical text that can be drawn to a render target.">Text</a> mode using ASCII encoding. </p>
</td></tr>
<tr><td class="fieldname"><a id="a1cd6b89ad23253f6d97e6d4ca4d558cbae9cd99e58c6a9a4c44b4b8694af338f0" name="a1cd6b89ad23253f6d97e6d4ca4d558cbae9cd99e58c6a9a4c44b4b8694af338f0"></a>Ebcdic&#160;</td><td class="fielddoc"><p><a class="el" href="classsf_1_1Text.html" title="Graphical text that can be drawn to a render target.">Text</a> mode using EBCDIC encoding. </p>
</td></tr>
</table>
<p class="definition">Definition at line <a class="el" href="Ftp_8hpp_source.html#l00056">56</a> of file <a class="el" href="Ftp_8hpp_source.html">Ftp.hpp</a>.</p>
</div>
</div>
<h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="ac3fc00b6b4719459d5f5e21c83d58684" name="ac3fc00b6b4719459d5f5e21c83d58684"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac3fc00b6b4719459d5f5e21c83d58684">&#9670;&#160;</a></span>Ftp() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">sf::Ftp::Ftp </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">default</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Default constructor. </p>
</div>
</div>
<a id="a2edfa8e9009caf27bce74459ae76dc52" name="a2edfa8e9009caf27bce74459ae76dc52"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2edfa8e9009caf27bce74459ae76dc52">&#9670;&#160;</a></span>~Ftp()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">sf::Ftp::~Ftp </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Destructor. </p>
<p>Automatically closes the connection with the server if it is still opened. </p>
</div>
</div>
<a id="aadb86adf5c7b495dfb88382d2608252c" name="aadb86adf5c7b495dfb88382d2608252c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aadb86adf5c7b495dfb88382d2608252c">&#9670;&#160;</a></span>Ftp() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">sf::Ftp::Ftp </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classsf_1_1Ftp.html">Ftp</a> &amp;</td> <td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">delete</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Deleted copy constructor. </p>
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="a7e93488ea6330dd4dd76e428da9bb6d3" name="a7e93488ea6330dd4dd76e428da9bb6d3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7e93488ea6330dd4dd76e428da9bb6d3">&#9670;&#160;</a></span>changeDirectory()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::changeDirectory </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>directory</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Change the current working directory. </p>
<p>The new directory must be relative to the current one.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">directory</td><td>New working directory</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a79c654fcdd0c81e68c4fa29af3b45e0c" title="Get the current working directory.">getWorkingDirectory</a></code>, <code><a class="el" href="#a8f37258e461fcb9e2a0655e9df0be4a0" title="Get the contents of the given directory.">getDirectoryListing</a></code>, <code><a class="el" href="#ad295cf77f30f9ad07b5c401fd9849189" title="Go to the parent directory of the current one.">parentDirectory</a></code> </dd></dl>
</div>
</div>
<a id="a4bf67543024815d11717ffe02cb8e1ef" name="a4bf67543024815d11717ffe02cb8e1ef"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4bf67543024815d11717ffe02cb8e1ef">&#9670;&#160;</a></span>connect()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::connect </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classsf_1_1IpAddress.html">IpAddress</a></td> <td class="paramname"><span class="paramname"><em>server</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">unsigned short</td> <td class="paramname"><span class="paramname"><em>port</em></span><span class="paramdefsep"> = </span><span class="paramdefval">21</span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="classsf_1_1Time.html">Time</a></td> <td class="paramname"><span class="paramname"><em>timeout</em></span><span class="paramdefsep"> = </span><span class="paramdefval"><a class="el" href="classsf_1_1Time.html#a8db127b632fa8da21550e7282af11fa0">Time::Zero</a></span>&#160;)</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Connect to the specified FTP server. </p>
<p>The port has a default value of 21, which is the standard port used by the FTP protocol. You shouldn't use a different value, unless you really know what you do. This function tries to connect to the server so it may take a while to complete, especially if the server is not reachable. To avoid blocking your application for too long, you can use a timeout. The default value, <code><a class="el" href="classsf_1_1Time.html#a8db127b632fa8da21550e7282af11fa0" title="Predefined &quot;zero&quot; time value.">Time::Zero</a></code>, means that the system timeout will be used (which is usually pretty long).</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">server</td><td>Name or address of the FTP server to connect to </td></tr>
<tr><td class="paramname">port</td><td>Port used for the connection </td></tr>
<tr><td class="paramname">timeout</td><td>Maximum time to wait</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#acf7459926f3391cd06bf84337ed6a0f4" title="Close the connection with the server.">disconnect</a></code> </dd></dl>
</div>
</div>
<a id="a247b84c4b25da37804218c2b748c4787" name="a247b84c4b25da37804218c2b748c4787"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a247b84c4b25da37804218c2b748c4787">&#9670;&#160;</a></span>createDirectory()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::createDirectory </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>name</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Create a new directory. </p>
<p>The new directory is created as a child of the current working directory.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">name</td><td>Name of the directory to create</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a2a8a7ef9144204b5b319c9a4be8806c2" title="Remove an existing directory.">deleteDirectory</a></code> </dd></dl>
</div>
</div>
<a id="a2a8a7ef9144204b5b319c9a4be8806c2" name="a2a8a7ef9144204b5b319c9a4be8806c2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2a8a7ef9144204b5b319c9a4be8806c2">&#9670;&#160;</a></span>deleteDirectory()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::deleteDirectory </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>name</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Remove an existing directory. </p>
<p>The directory to remove must be relative to the current working directory. Use this function with caution, the directory will be removed permanently!</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">name</td><td>Name of the directory to remove</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a247b84c4b25da37804218c2b748c4787" title="Create a new directory.">createDirectory</a></code> </dd></dl>
</div>
</div>
<a id="a1dad32d3fe649b9f60a91ace18f440e7" name="a1dad32d3fe649b9f60a91ace18f440e7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1dad32d3fe649b9f60a91ace18f440e7">&#9670;&#160;</a></span>deleteFile()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::deleteFile </td>
<td>(</td>
<td class="paramtype">const std::filesystem::path &amp;</td> <td class="paramname"><span class="paramname"><em>name</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Remove an existing file. </p>
<p>The file name must be relative to the current working directory. Use this function with caution, the file will be removed permanently!</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">name</td><td>File to remove</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a96cff0afc5d03e60452f7356f1cac7f2" title="Rename an existing file.">renameFile</a></code> </dd></dl>
</div>
</div>
<a id="acf7459926f3391cd06bf84337ed6a0f4" name="acf7459926f3391cd06bf84337ed6a0f4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#acf7459926f3391cd06bf84337ed6a0f4">&#9670;&#160;</a></span>disconnect()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::disconnect </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Close the connection with the server. </p>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a4bf67543024815d11717ffe02cb8e1ef" title="Connect to the specified FTP server.">connect</a></code> </dd></dl>
</div>
</div>
<a id="a960cae5522a9b90585536abf20b17543" name="a960cae5522a9b90585536abf20b17543"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a960cae5522a9b90585536abf20b17543">&#9670;&#160;</a></span>download()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::download </td>
<td>(</td>
<td class="paramtype">const std::filesystem::path &amp;</td> <td class="paramname"><span class="paramname"><em>remoteFile</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::filesystem::path &amp;</td> <td class="paramname"><span class="paramname"><em>localPath</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cb">TransferMode</a></td> <td class="paramname"><span class="paramname"><em>mode</em></span><span class="paramdefsep"> = </span><span class="paramdefval"><a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cba6ce976e8f061b2b5cfe4d0c50c3405dd">TransferMode::Binary</a></span>&#160;)</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Download a file from the server. </p>
<p>The file name of the distant file is relative to the current working directory of the server, and the local destination path is relative to the current directory of your application. If a file with the same file name as the distant file already exists in the local destination path, it will be overwritten.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">remoteFile</td><td>File name of the distant file to download </td></tr>
<tr><td class="paramname">localPath</td><td>The directory in which to put the file on the local computer </td></tr>
<tr><td class="paramname">mode</td><td>Transfer mode</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#adcc40761d3061e5b0d9d208eb5420f9b" title="Upload a file to the server.">upload</a></code> </dd></dl>
</div>
</div>
<a id="a8f37258e461fcb9e2a0655e9df0be4a0" name="a8f37258e461fcb9e2a0655e9df0be4a0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8f37258e461fcb9e2a0655e9df0be4a0">&#9670;&#160;</a></span>getDirectoryListing()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1ListingResponse.html">ListingResponse</a> sf::Ftp::getDirectoryListing </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>directory</em></span><span class="paramdefsep"> = </span><span class="paramdefval">&quot;&quot;</span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the contents of the given directory. </p>
<p>This function retrieves the sub-directories and files contained in the given directory. It is not recursive. The <code>directory</code> parameter is relative to the current working directory.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">directory</td><td>Directory to list</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a79c654fcdd0c81e68c4fa29af3b45e0c" title="Get the current working directory.">getWorkingDirectory</a></code>, <code><a class="el" href="#a7e93488ea6330dd4dd76e428da9bb6d3" title="Change the current working directory.">changeDirectory</a></code>, <code><a class="el" href="#ad295cf77f30f9ad07b5c401fd9849189" title="Go to the parent directory of the current one.">parentDirectory</a></code> </dd></dl>
</div>
</div>
<a id="a79c654fcdd0c81e68c4fa29af3b45e0c" name="a79c654fcdd0c81e68c4fa29af3b45e0c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a79c654fcdd0c81e68c4fa29af3b45e0c">&#9670;&#160;</a></span>getWorkingDirectory()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1DirectoryResponse.html">DirectoryResponse</a> sf::Ftp::getWorkingDirectory </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the current working directory. </p>
<p>The working directory is the root path for subsequent operations involving directories and/or filenames.</p>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a8f37258e461fcb9e2a0655e9df0be4a0" title="Get the contents of the given directory.">getDirectoryListing</a></code>, <code><a class="el" href="#a7e93488ea6330dd4dd76e428da9bb6d3" title="Change the current working directory.">changeDirectory</a></code>, <code><a class="el" href="#ad295cf77f30f9ad07b5c401fd9849189" title="Go to the parent directory of the current one.">parentDirectory</a></code> </dd></dl>
</div>
</div>
<a id="aa1127d442b4acb2105aa8060a39d04fc" name="aa1127d442b4acb2105aa8060a39d04fc"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa1127d442b4acb2105aa8060a39d04fc">&#9670;&#160;</a></span>keepAlive()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::keepAlive </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Send a null command to keep the connection alive. </p>
<p>This command is useful because the server may close the connection automatically if no command is sent.</p>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request </dd></dl>
</div>
</div>
<a id="a686262bc377584cd50e52e1576aa3a9b" name="a686262bc377584cd50e52e1576aa3a9b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a686262bc377584cd50e52e1576aa3a9b">&#9670;&#160;</a></span>login() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::login </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Log in using an anonymous account. </p>
<p>Logging in is mandatory after connecting to the server. Users that are not logged in cannot perform any operation.</p>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request </dd></dl>
</div>
</div>
<a id="a99d8114793c1659e9d51d45cecdcd965" name="a99d8114793c1659e9d51d45cecdcd965"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a99d8114793c1659e9d51d45cecdcd965">&#9670;&#160;</a></span>login() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::login </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>name</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>password</em></span>&#160;)</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Log in using a username and a password. </p>
<p>Logging in is mandatory after connecting to the server. Users that are not logged in cannot perform any operation.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">name</td><td>User name </td></tr>
<tr><td class="paramname">password</td><td>Password</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request </dd></dl>
</div>
</div>
<a id="add953d6d8524b3914f984c0c5eef1492" name="add953d6d8524b3914f984c0c5eef1492"></a>
<h2 class="memtitle"><span class="permalink"><a href="#add953d6d8524b3914f984c0c5eef1492">&#9670;&#160;</a></span>operator=()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp.html">Ftp</a> &amp; sf::Ftp::operator= </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classsf_1_1Ftp.html">Ftp</a> &amp;</td> <td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">delete</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Deleted copy assignment. </p>
</div>
</div>
<a id="ad295cf77f30f9ad07b5c401fd9849189" name="ad295cf77f30f9ad07b5c401fd9849189"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad295cf77f30f9ad07b5c401fd9849189">&#9670;&#160;</a></span>parentDirectory()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::parentDirectory </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Go to the parent directory of the current one. </p>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a79c654fcdd0c81e68c4fa29af3b45e0c" title="Get the current working directory.">getWorkingDirectory</a></code>, <code><a class="el" href="#a8f37258e461fcb9e2a0655e9df0be4a0" title="Get the contents of the given directory.">getDirectoryListing</a></code>, <code><a class="el" href="#a7e93488ea6330dd4dd76e428da9bb6d3" title="Change the current working directory.">changeDirectory</a></code> </dd></dl>
</div>
</div>
<a id="a96cff0afc5d03e60452f7356f1cac7f2" name="a96cff0afc5d03e60452f7356f1cac7f2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a96cff0afc5d03e60452f7356f1cac7f2">&#9670;&#160;</a></span>renameFile()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::renameFile </td>
<td>(</td>
<td class="paramtype">const std::filesystem::path &amp;</td> <td class="paramname"><span class="paramname"><em>file</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::filesystem::path &amp;</td> <td class="paramname"><span class="paramname"><em>newName</em></span>&#160;)</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Rename an existing file. </p>
<p>The file names must be relative to the current working directory.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">file</td><td>File to rename </td></tr>
<tr><td class="paramname">newName</td><td>New name of the file</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a1dad32d3fe649b9f60a91ace18f440e7" title="Remove an existing file.">deleteFile</a></code> </dd></dl>
</div>
</div>
<a id="a44e095103ecbce175a33eaf0820440ff" name="a44e095103ecbce175a33eaf0820440ff"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a44e095103ecbce175a33eaf0820440ff">&#9670;&#160;</a></span>sendCommand()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::sendCommand </td>
<td>(</td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>command</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::string &amp;</td> <td class="paramname"><span class="paramname"><em>parameter</em></span><span class="paramdefsep"> = </span><span class="paramdefval">&quot;&quot;</span>&#160;)</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Send a command to the FTP server. </p>
<p>While the most often used commands are provided as member functions in the <code><a class="el" href="classsf_1_1Ftp.html" title="A FTP client.">sf::Ftp</a></code> class, this method can be used to send any FTP command to the server. If the command requires one or more parameters, they can be specified in <code>parameter</code>. If the server returns information, you can extract it from the response using <code><a class="el" href="classsf_1_1Ftp_1_1Response.html#adc2890c93c9f8ee997b828fcbef82c97" title="Get the full message contained in the response.">Response::getMessage()</a></code>.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">command</td><td>Command to send </td></tr>
<tr><td class="paramname">parameter</td><td>Command parameter</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request </dd></dl>
</div>
</div>
<a id="adcc40761d3061e5b0d9d208eb5420f9b" name="adcc40761d3061e5b0d9d208eb5420f9b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#adcc40761d3061e5b0d9d208eb5420f9b">&#9670;&#160;</a></span>upload()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Ftp_1_1Response.html">Response</a> sf::Ftp::upload </td>
<td>(</td>
<td class="paramtype">const std::filesystem::path &amp;</td> <td class="paramname"><span class="paramname"><em>localFile</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::filesystem::path &amp;</td> <td class="paramname"><span class="paramname"><em>remotePath</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cb">TransferMode</a></td> <td class="paramname"><span class="paramname"><em>mode</em></span><span class="paramdefsep"> = </span><span class="paramdefval"><a class="el" href="#a1cd6b89ad23253f6d97e6d4ca4d558cba6ce976e8f061b2b5cfe4d0c50c3405dd">TransferMode::Binary</a></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>append</em></span><span class="paramdefsep"> = </span><span class="paramdefval">false</span>&#160;)</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Upload a file to the server. </p>
<p>The name of the local file is relative to the current working directory of your application, and the remote path is relative to the current directory of the FTP server.</p>
<p>The append parameter controls whether the remote file is appended to or overwritten if it already exists.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">localFile</td><td>Path of the local file to upload </td></tr>
<tr><td class="paramname">remotePath</td><td>The directory in which to put the file on the server </td></tr>
<tr><td class="paramname">mode</td><td>Transfer mode </td></tr>
<tr><td class="paramname">append</td><td>Pass <code>true</code> to append to or <code>false</code> to overwrite the remote file if it already exists</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Server response to the request</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a960cae5522a9b90585536abf20b17543" title="Download a file from the server.">download</a></code> </dd></dl>
</div>
</div>
<h2 class="groupheader">Friends And Related Symbol Documentation</h2>
<a id="a8dee57337b6a7e183bfe21d178757b0c" name="a8dee57337b6a7e183bfe21d178757b0c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8dee57337b6a7e183bfe21d178757b0c">&#9670;&#160;</a></span>DataChannel</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">friend class DataChannel</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">friend</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p class="definition">Definition at line <a class="el" href="Ftp_8hpp_source.html#l00547">547</a> of file <a class="el" href="Ftp_8hpp_source.html">Ftp.hpp</a>.</p>
</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="Ftp_8hpp_source.html">Ftp.hpp</a></li>
</ul>
</div><!-- contents -->
</div>
<div id="footer-container">
<div id="footer">
SFML is licensed under the terms and conditions of the <a href="https://www.sfml-dev.org/license.php">zlib/png license</a>.<br />
Copyright &copy; Laurent Gomila &nbsp;::&nbsp;
Documentation generated by <a href="http://www.doxygen.org/" title="doxygen website">doxygen</a> &nbsp;::&nbsp;
</div>
</div>
</body>
</html>