File: Poco.Net.FTPClientSession.html

package info (click to toggle)
poco-doc 1.3.6-1
  • links: PTS
  • area: main
  • in suites: buster, jessie, jessie-kfreebsd, squeeze, stretch, wheezy
  • size: 10,076 kB
  • ctags: 9,611
  • sloc: makefile: 31
file content (357 lines) | stat: -rw-r--r-- 32,396 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
<!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>Class Poco::Net::FTPClientSession</title>
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<meta name="author" content="Applied Informatics Software Engineering GmbH and Contributors"/>
<meta name="publisher" content="Applied Informatics Software Engineering GmbH and Contributors"/>
<meta name="copyright" content="Copyright (c) 2009, Applied Informatics Software Engineering GmbH and Contributors"/>
<meta name="language" content="en"/>
<meta name="date" content="2009-11-24"/>
<meta name="generator" content="PocoDoc"/>
<link rel="stylesheet" href="css/styles.css" type="text/css"/>
</head>
<body bgcolor="#ffffff" leftmargin="0" topmargin="0">
<div class="header">
<h1 class="namespace"><a href="Poco.Net.html" class="namespace">Poco::Net</a></h1>
<h1 class="symbol">class FTPClientSession</h1>
</div>
<div class="body">
<p>
<b>Library:</b> Net<br />
<b>Package:</b> FTP<br />
<b>Header:</b> Poco/Net/FTPClientSession.h</p>
<h2>Description</h2>
<div class="description">
<p>This class implements an <a href="Poco.File.html" title="class Poco::File">File</a> Transfer Protocol (FTP, <a href="http://www.ietf.org/rfc/rfc959.txt" target="_blank">RFC 959</a>) client. </p>
<p>Most of the features of the FTP protocol, as specified in <a href="http://www.ietf.org/rfc/rfc959.txt" target="_blank">RFC 959</a>, are supported. Not supported are EBCDIC and LOCAL data types and format control and structured files. </p>
<p>Also supported are the EPRT and EPSV commands from <a href="http://www.ietf.org/rfc/rfc1738.txt" target="_blank">RFC 1738</a> (FTP Extensions for IPv6 and NAT). The client will first attempt to use the EPRT and EPSV commands. If the server does not supports these commands, the client will fall back to PORT and PASV. </p>
</div>
<h2>Member Summary</h2>
<p><b>Member Functions: </b><a href="Poco.Net.FTPClientSession.html#12302" title="Poco::Net::FTPClientSession::abort()">abort</a>, <a href="Poco.Net.FTPClientSession.html#12333" title="Poco::Net::FTPClientSession::activeDataConnection()">activeDataConnection</a>, <a href="Poco.Net.FTPClientSession.html#12292" title="Poco::Net::FTPClientSession::beginDownload()">beginDownload</a>, <a href="Poco.Net.FTPClientSession.html#12298" title="Poco::Net::FTPClientSession::beginList()">beginList</a>, <a href="Poco.Net.FTPClientSession.html#12295" title="Poco::Net::FTPClientSession::beginUpload()">beginUpload</a>, <a href="Poco.Net.FTPClientSession.html#12282" title="Poco::Net::FTPClientSession::cdup()">cdup</a>, <a href="Poco.Net.FTPClientSession.html#12274" title="Poco::Net::FTPClientSession::close()">close</a>, <a href="Poco.Net.FTPClientSession.html#12288" title="Poco::Net::FTPClientSession::createDirectory()">createDirectory</a>, <a href="Poco.Net.FTPClientSession.html#12294" title="Poco::Net::FTPClientSession::endDownload()">endDownload</a>, <a href="Poco.Net.FTPClientSession.html#12301" title="Poco::Net::FTPClientSession::endList()">endList</a>, <a href="Poco.Net.FTPClientSession.html#12356" title="Poco::Net::FTPClientSession::endTransfer()">endTransfer</a>, <a href="Poco.Net.FTPClientSession.html#12297" title="Poco::Net::FTPClientSession::endUpload()">endUpload</a>, <a href="Poco.Net.FTPClientSession.html#12330" title="Poco::Net::FTPClientSession::establishDataConnection()">establishDataConnection</a>, <a href="Poco.Net.FTPClientSession.html#12328" title="Poco::Net::FTPClientSession::extractPath()">extractPath</a>, <a href="Poco.Net.FTPClientSession.html#12278" title="Poco::Net::FTPClientSession::getFileType()">getFileType</a>, <a href="Poco.Net.FTPClientSession.html#12270" title="Poco::Net::FTPClientSession::getPassive()">getPassive</a>, <a href="Poco.Net.FTPClientSession.html#12266" title="Poco::Net::FTPClientSession::getTimeout()">getTimeout</a>, <a href="Poco.Net.FTPClientSession.html#12281" title="Poco::Net::FTPClientSession::getWorkingDirectory()">getWorkingDirectory</a>, <a href="Poco.Net.FTPClientSession.html#12326" title="Poco::Net::FTPClientSession::isPermanentNegative()">isPermanentNegative</a>, <a href="Poco.Net.FTPClientSession.html#12320" title="Poco::Net::FTPClientSession::isPositiveCompletion()">isPositiveCompletion</a>, <a href="Poco.Net.FTPClientSession.html#12322" title="Poco::Net::FTPClientSession::isPositiveIntermediate()">isPositiveIntermediate</a>, <a href="Poco.Net.FTPClientSession.html#12318" title="Poco::Net::FTPClientSession::isPositivePreliminary()">isPositivePreliminary</a>, <a href="Poco.Net.FTPClientSession.html#12324" title="Poco::Net::FTPClientSession::isTransientNegative()">isTransientNegative</a>, <a href="Poco.Net.FTPClientSession.html#12271" title="Poco::Net::FTPClientSession::login()">login</a>, <a href="Poco.Net.FTPClientSession.html#12350" title="Poco::Net::FTPClientSession::parseAddress()">parseAddress</a>, <a href="Poco.Net.FTPClientSession.html#12353" title="Poco::Net::FTPClientSession::parseExtAddress()">parseExtAddress</a>, <a href="Poco.Net.FTPClientSession.html#12336" title="Poco::Net::FTPClientSession::passiveDataConnection()">passiveDataConnection</a>, <a href="Poco.Net.FTPClientSession.html#12286" title="Poco::Net::FTPClientSession::remove()">remove</a>, <a href="Poco.Net.FTPClientSession.html#12290" title="Poco::Net::FTPClientSession::removeDirectory()">removeDirectory</a>, <a href="Poco.Net.FTPClientSession.html#12283" title="Poco::Net::FTPClientSession::rename()">rename</a>, <a href="Poco.Net.FTPClientSession.html#12303" title="Poco::Net::FTPClientSession::sendCommand()">sendCommand</a>, <a href="Poco.Net.FTPClientSession.html#12342" title="Poco::Net::FTPClientSession::sendEPRT()">sendEPRT</a>, <a href="Poco.Net.FTPClientSession.html#12346" title="Poco::Net::FTPClientSession::sendEPSV()">sendEPSV</a>, <a href="Poco.Net.FTPClientSession.html#12348" title="Poco::Net::FTPClientSession::sendPASV()">sendPASV</a>, <a href="Poco.Net.FTPClientSession.html#12344" title="Poco::Net::FTPClientSession::sendPORT()">sendPORT</a>, <a href="Poco.Net.FTPClientSession.html#12341" title="Poco::Net::FTPClientSession::sendPassiveCommand()">sendPassiveCommand</a>, <a href="Poco.Net.FTPClientSession.html#12339" title="Poco::Net::FTPClientSession::sendPortCommand()">sendPortCommand</a>, <a href="Poco.Net.FTPClientSession.html#12276" title="Poco::Net::FTPClientSession::setFileType()">setFileType</a>, <a href="Poco.Net.FTPClientSession.html#12267" title="Poco::Net::FTPClientSession::setPassive()">setPassive</a>, <a href="Poco.Net.FTPClientSession.html#12264" title="Poco::Net::FTPClientSession::setTimeout()">setTimeout</a>, <a href="Poco.Net.FTPClientSession.html#12279" title="Poco::Net::FTPClientSession::setWorkingDirectory()">setWorkingDirectory</a>, <a href="Poco.Net.FTPClientSession.html#12275" title="Poco::Net::FTPClientSession::systemType()">systemType</a></p>
<h2>Enumerations</h2>
<h3><i>Anonymous</i></h3>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="12254">FTP_PORT</a> = 21</p>
<div class="description">
<p></p>
</div>
<h3><i>Anonymous</i> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="12317">DEFAULT_TIMEOUT</a> = 30000000</p>
<div class="description">
<p></p>
</div>
<h3><a name="12255">FileType</a></h3>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="12256">TYPE_TEXT</a></p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="12257">TYPE_BINARY</a></p>
<div class="description">
<p></p>
</div>
<h3><a name="12310">StatusClass</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="12311">FTP_POSITIVE_PRELIMINARY</a> = 1</p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="12312">FTP_POSITIVE_COMPLETION</a> = 2</p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="12313">FTP_POSITIVE_INTERMEDIATE</a> = 3</p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="12314">FTP_TRANSIENT_NEGATIVE</a> = 4</p>
<div class="description">
<p></p>
</div>
<p class="decl"><a name="12315">FTP_PERMANENT_NEGATIVE</a> = 5</p>
<div class="description">
<p></p>
</div>
<h2>Constructors</h2>
<h3><a name="12258">FTPClientSession</a></h3>
<p class="decl">explicit <a href="Poco.Net.FTPClientSession.html" title="class Poco::Net::FTPClientSession">FTPClientSession</a>(<br />&nbsp;&nbsp;&nbsp;&nbsp;const <a href="Poco.Net.StreamSocket.html" title="class Poco::Net::StreamSocket">StreamSocket</a> &amp; socket<br />);</p>
<div class="description">
<p>Creates an <a href="Poco.Net.FTPClientSession.html" title="class Poco::Net::FTPClientSession">FTPClientSession</a> using the given connected socket for the control connection. </p>
<p>Passive mode will be used for data transfers. </p>
</div>
<h3><a name="12260">FTPClientSession</a></h3>
<p class="decl"><a href="Poco.Net.FTPClientSession.html" title="class Poco::Net::FTPClientSession">FTPClientSession</a>(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; host,<br />&nbsp;&nbsp;&nbsp;&nbsp;<a href="Poco.html#11352" title="Poco::UInt16">Poco::UInt16</a> port = FTP_PORT<br />);</p>
<div class="description">
<p>Creates an <a href="Poco.Net.FTPClientSession.html" title="class Poco::Net::FTPClientSession">FTPClientSession</a> using a socket connected to the given host and port. </p>
<p>Passive mode will be used for data transfers. </p>
</div>
<h2>Destructor</h2>
<h3><a name="12263">~FTPClientSession</a> <img src="images/virtual.gif" alt="virtual" title="virtual" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">virtual ~<a href="Poco.Net.FTPClientSession.html" title="class Poco::Net::FTPClientSession">FTPClientSession</a>();</p>
<div class="description">
<p>Destroys the <a href="Poco.Net.FTPClientSession.html" title="class Poco::Net::FTPClientSession">FTPClientSession</a>. </p>
</div>
<h2>Member Functions</h2>
<h3><a name="12302">abort</a></h3>
<p class="decl">void abort();</p>
<div class="description">
<p>Aborts the download or upload currently in progress. </p>
<p>Sends a TELNET IP/SYNCH sequence, followed by an ABOR command to the server. </p>
<p>A separate call to <a href="Poco.Net.FTPClientSession.html#12294" title="Poco::Net::FTPClientSession::endDownload()">endDownload</a>() or <a href="Poco.Net.FTPClientSession.html#12297" title="Poco::Net::FTPClientSession::endUpload()">endUpload</a>() is not necessary. </p>
</div>
<h3><a name="12292">beginDownload</a></h3>
<p class="decl">std::istream &amp; beginDownload(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; path<br />);</p>
<div class="description">
<p>Starts downloading the file with the given name. After all data has been read from the returned stream, <a href="Poco.Net.FTPClientSession.html#12294" title="Poco::Net::FTPClientSession::endDownload()">endDownload</a>() must be called to finish the download. </p>
<p>A stream for reading the file's content is returned. The stream is valid until <a href="Poco.Net.FTPClientSession.html#12294" title="Poco::Net::FTPClientSession::endDownload()">endDownload</a>() is called. </p>
<p>Creates a data connection between the client and the server. If passive mode is on, then the server waits for a connection request from the client. Otherwise, the client waits for a connection request from the server. After establishing the data connection, a <a href="Poco.Net.SocketStream.html" title="class Poco::Net::SocketStream">SocketStream</a> for transferring the data is created. </p>
<p>If ASCII transfer mode is selected, the caller is responsible for converting the received data to the native text file format. The <a href="Poco.InputLineEndingConverter.html" title="class Poco::InputLineEndingConverter">InputLineEndingConverter</a> class from the Foundation library can be used for that purpose. </p>
</div>
<h3><a name="12298">beginList</a></h3>
<p class="decl">std::istream &amp; beginList(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; path = "",<br />&nbsp;&nbsp;&nbsp;&nbsp;bool extended = false<br />);</p>
<div class="description">
<p>Starts downloading a directory listing. After all data has been read from the returned stream, <a href="Poco.Net.FTPClientSession.html#12301" title="Poco::Net::FTPClientSession::endList()">endList</a>() must be called to finish the download. </p>
<p>A stream for reading the directory data is returned. The stream is valid until <a href="Poco.Net.FTPClientSession.html#12301" title="Poco::Net::FTPClientSession::endList()">endList</a>() is called. </p>
<p>Optionally, a path to a directory or file can be specified. According to the FTP prototol, if a path to a filename is given, only information for the specific file is returned. If a path to a directory is given, a listing of that directory is returned. If no path is given, a listing of the current working directory is returned. </p>
<p>If extended is false, only a filenames (one per line) are returned. Otherwise, a full directory listing including file attributes is returned. The format of this listing depends on the FTP server. No attempt is made to interpret this data. </p>
<p>Creates a data connection between the client and the server. If passive mode is on, then the server waits for a connection request from the client. Otherwise, the client waits for a connection request from the server. After establishing the data connection, a <a href="Poco.Net.SocketStream.html" title="class Poco::Net::SocketStream">SocketStream</a> for transferring the data is created. </p>
</div>
<h3><a name="12295">beginUpload</a></h3>
<p class="decl">std::ostream &amp; beginUpload(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; path<br />);</p>
<div class="description">
<p>Starts uploading the file with the given name. After all data has been written to the returned stream, <a href="Poco.Net.FTPClientSession.html#12297" title="Poco::Net::FTPClientSession::endUpload()">endUpload</a>() must be called to finish the download. </p>
<p>A stream for reading the file's content is returned. The stream is valid until <a href="Poco.Net.FTPClientSession.html#12297" title="Poco::Net::FTPClientSession::endUpload()">endUpload</a>() is called. </p>
<p>Creates a data connection between the client and the server. If passive mode is on, then the server waits for a connection request from the client. Otherwise, the client waits for a connection request from the server. After establishing the data connection, a <a href="Poco.Net.SocketStream.html" title="class Poco::Net::SocketStream">SocketStream</a> for transferring the data is created. </p>
<p>If ASCII transfer mode is selected, the caller is responsible for converting the data to be sent into network (CR-LF line endings) format. The <a href="Poco.OutputLineEndingConverter.html" title="class Poco::OutputLineEndingConverter">OutputLineEndingConverter</a> class from the Foundation library can be used for that purpose. </p>
</div>
<h3><a name="12282">cdup</a></h3>
<p class="decl">void cdup();</p>
<div class="description">
<p>Moves one directory up from the current working directory on teh server. </p>
<p>Sends a CDUP command to the server. </p>
<p>Throws a <a href="Poco.Net.FTPException.html" title="class Poco::Net::FTPException">FTPException</a> in case of a FTP-specific error, or a <a href="Poco.Net.NetException.html" title="class Poco::Net::NetException">NetException</a> in case of a general network communication failure. </p>
</div>
<h3><a name="12274">close</a></h3>
<p class="decl">void close();</p>
<div class="description">
<p>Sends a QUIT command and closes the connection to the server.	 </p>
<p>Throws a <a href="Poco.Net.FTPException.html" title="class Poco::Net::FTPException">FTPException</a> in case of a FTP-specific error, or a <a href="Poco.Net.NetException.html" title="class Poco::Net::NetException">NetException</a> in case of a general network communication failure. </p>
</div>
<h3><a name="12288">createDirectory</a></h3>
<p class="decl">void createDirectory(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; path<br />);</p>
<div class="description">
<p>Creates a new directory with the given path on the server. </p>
<p>Sends a MKD command with path as argument to the server. </p>
<p>Throws a <a href="Poco.Net.FTPException.html" title="class Poco::Net::FTPException">FTPException</a> in case of a FTP-specific error, or a <a href="Poco.Net.NetException.html" title="class Poco::Net::NetException">NetException</a> in case of a general network communication failure. </p>
</div>
<h3><a name="12294">endDownload</a></h3>
<p class="decl">void endDownload();</p>
<div class="description">
<p>Must be called to complete a download initiated with <a href="Poco.Net.FTPClientSession.html#12292" title="Poco::Net::FTPClientSession::beginDownload()">beginDownload</a>(). </p>
</div>
<h3><a name="12301">endList</a></h3>
<p class="decl">void endList();</p>
<div class="description">
<p>Must be called to complete a directory listing download  initiated with <a href="Poco.Net.FTPClientSession.html#12298" title="Poco::Net::FTPClientSession::beginList()">beginList</a>(). </p>
</div>
<h3><a name="12297">endUpload</a></h3>
<p class="decl">void endUpload();</p>
<div class="description">
<p>Must be called to complete an upload initiated with <a href="Poco.Net.FTPClientSession.html#12295" title="Poco::Net::FTPClientSession::beginUpload()">beginUpload</a>(). </p>
</div>
<h3><a name="12278">getFileType</a></h3>
<p class="decl"><a href="Poco.Net.FTPClientSession.html#12255" title="enum  Poco::Net::FTPClientSession::FileType">FileType</a> getFileType() const;</p>
<div class="description">
<p>Returns the file type for transferring files. </p>
</div>
<h3><a name="12270">getPassive</a></h3>
<p class="decl">bool getPassive() const;</p>
<div class="description">
<p>Returns true if and only if passive mode is enabled for this connection. </p>
</div>
<h3><a name="12266">getTimeout</a></h3>
<p class="decl"><a href="Poco.Timespan.html" title="class Poco::Timespan">Poco::Timespan</a> getTimeout() const;</p>
<div class="description">
<p>Returns the timeout for socket operations. </p>
</div>
<h3><a name="12281">getWorkingDirectory</a></h3>
<p class="decl">std::string getWorkingDirectory();</p>
<div class="description">
<p>Returns the current working directory on the server. </p>
<p>Throws a <a href="Poco.Net.FTPException.html" title="class Poco::Net::FTPException">FTPException</a> in case of a FTP-specific error, or a <a href="Poco.Net.NetException.html" title="class Poco::Net::NetException">NetException</a> in case of a general network communication failure. </p>
</div>
<h3><a name="12271">login</a></h3>
<p class="decl">void login(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; username,<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; password<br />);</p>
<div class="description">
<p>Authenticates the user against the FTP server. Must be called before any other commands (except QUIT) can be sent. </p>
<p>Sends a USER command followed by a PASS command with the respective arguments to the server. </p>
<p>Throws a <a href="Poco.Net.FTPException.html" title="class Poco::Net::FTPException">FTPException</a> in case of a FTP-specific error, or a <a href="Poco.Net.NetException.html" title="class Poco::Net::NetException">NetException</a> in case of a general network communication failure. </p>
</div>
<h3><a name="12286">remove</a></h3>
<p class="decl">void remove(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; path<br />);</p>
<div class="description">
<p>Deletes the file specified by path on the server. </p>
<p>Sends a DELE command with path as argument to the server. </p>
<p>Throws a <a href="Poco.Net.FTPException.html" title="class Poco::Net::FTPException">FTPException</a> in case of a FTP-specific error, or a <a href="Poco.Net.NetException.html" title="class Poco::Net::NetException">NetException</a> in case of a general network communication failure. </p>
</div>
<h3><a name="12290">removeDirectory</a></h3>
<p class="decl">void removeDirectory(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; path<br />);</p>
<div class="description">
<p>Removes the directory specified by path from the server. </p>
<p>Sends a RMD command with path as argument to the server. </p>
<p>Throws a <a href="Poco.Net.FTPException.html" title="class Poco::Net::FTPException">FTPException</a> in case of a FTP-specific error, or a <a href="Poco.Net.NetException.html" title="class Poco::Net::NetException">NetException</a> in case of a general network communication failure. </p>
</div>
<h3><a name="12283">rename</a></h3>
<p class="decl">void rename(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; oldName,<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; newName<br />);</p>
<div class="description">
<p>Renames the file on the server given by oldName to newName. </p>
<p>Sends a RNFR command, followed by a RNTO command to the server. </p>
<p>Throws a <a href="Poco.Net.FTPException.html" title="class Poco::Net::FTPException">FTPException</a> in case of a FTP-specific error, or a <a href="Poco.Net.NetException.html" title="class Poco::Net::NetException">NetException</a> in case of a general network communication failure. </p>
</div>
<h3><a name="12303">sendCommand</a></h3>
<p class="decl">int sendCommand(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; command,<br />&nbsp;&nbsp;&nbsp;&nbsp;std::string &amp; response<br />);</p>
<div class="description">
<p>Sends the given command verbatim to the server and waits for a response. </p>
</div>
<h3><a name="12306">sendCommand</a></h3>
<p class="decl">int sendCommand(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; command,<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; arg,<br />&nbsp;&nbsp;&nbsp;&nbsp;std::string &amp; response<br />);</p>
<div class="description">
<p>Sends the given command verbatim to the server and waits for a response. </p>
</div>
<h3><a name="12276">setFileType</a></h3>
<p class="decl">void setFileType(<br />&nbsp;&nbsp;&nbsp;&nbsp;<a href="Poco.Net.FTPClientSession.html#12255" title="enum  Poco::Net::FTPClientSession::FileType">FileType</a> type<br />);</p>
<div class="description">
<p>Sets the file type for transferring files. </p>
<p>Sends a TYPE command with a corresponsing argument to the server. </p>
<p>Throws a <a href="Poco.Net.FTPException.html" title="class Poco::Net::FTPException">FTPException</a> in case of a FTP-specific error, or a <a href="Poco.Net.NetException.html" title="class Poco::Net::NetException">NetException</a> in case of a general network communication failure. </p>
</div>
<h3><a name="12267">setPassive</a></h3>
<p class="decl">void setPassive(<br />&nbsp;&nbsp;&nbsp;&nbsp;bool flag,<br />&nbsp;&nbsp;&nbsp;&nbsp;bool useRFC1738 = true<br />);</p>
<div class="description">
<p>Enables (default) or disables FTP passive mode for this session. </p>
<p>If useRFC1738 is true (the default), the <a href="http://www.ietf.org/rfc/rfc1738.txt" target="_blank">RFC 1738</a> EPSV command is used (with a fallback to PASV if EPSV fails) for switching to passive mode. The same applies to EPRT and PORT for active connections. </p>
</div>
<h3><a name="12264">setTimeout</a></h3>
<p class="decl">void setTimeout(<br />&nbsp;&nbsp;&nbsp;&nbsp;const <a href="Poco.Timespan.html" title="class Poco::Timespan">Poco::Timespan</a> &amp; timeout<br />);</p>
<div class="description">
<p>Sets the timeout for socket operations. </p>
</div>
<h3><a name="12279">setWorkingDirectory</a></h3>
<p class="decl">void setWorkingDirectory(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; path<br />);</p>
<div class="description">
<p>Changes the current working directory on the server. </p>
<p>Sends a CWD command with the given path as argument to the  server. </p>
<p>Throws a <a href="Poco.Net.FTPException.html" title="class Poco::Net::FTPException">FTPException</a> in case of a FTP-specific error, or a <a href="Poco.Net.NetException.html" title="class Poco::Net::NetException">NetException</a> in case of a general network communication failure. </p>
</div>
<h3><a name="12275">systemType</a></h3>
<p class="decl">std::string systemType();</p>
<div class="description">
<p>Returns the system type of the FTP server. </p>
<p>Sends a SYST command to the server and returns the result. </p>
</div>
<h3><a name="12333">activeDataConnection</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl"><a href="Poco.Net.StreamSocket.html" title="class Poco::Net::StreamSocket">StreamSocket</a> activeDataConnection(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; command,<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; arg<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12356">endTransfer</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">void endTransfer();</p>
<div class="description">
<p></p>
</div>
<h3><a name="12330">establishDataConnection</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl"><a href="Poco.Net.StreamSocket.html" title="class Poco::Net::StreamSocket">StreamSocket</a> establishDataConnection(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; command,<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; arg<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12328">extractPath</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">std::string extractPath(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; response<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12326">isPermanentNegative</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" />  <img src="images/static.gif" alt="static" title="static" style="vertical-align:baseline;" border="0" />  <img src="images/inline.gif" alt="inline" title="inline" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">static bool isPermanentNegative(<br />&nbsp;&nbsp;&nbsp;&nbsp;int status<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12320">isPositiveCompletion</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" />  <img src="images/static.gif" alt="static" title="static" style="vertical-align:baseline;" border="0" />  <img src="images/inline.gif" alt="inline" title="inline" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">static bool isPositiveCompletion(<br />&nbsp;&nbsp;&nbsp;&nbsp;int status<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12322">isPositiveIntermediate</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" />  <img src="images/static.gif" alt="static" title="static" style="vertical-align:baseline;" border="0" />  <img src="images/inline.gif" alt="inline" title="inline" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">static bool isPositiveIntermediate(<br />&nbsp;&nbsp;&nbsp;&nbsp;int status<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12318">isPositivePreliminary</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" />  <img src="images/static.gif" alt="static" title="static" style="vertical-align:baseline;" border="0" />  <img src="images/inline.gif" alt="inline" title="inline" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">static bool isPositivePreliminary(<br />&nbsp;&nbsp;&nbsp;&nbsp;int status<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12324">isTransientNegative</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" />  <img src="images/static.gif" alt="static" title="static" style="vertical-align:baseline;" border="0" />  <img src="images/inline.gif" alt="inline" title="inline" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">static bool isTransientNegative(<br />&nbsp;&nbsp;&nbsp;&nbsp;int status<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12350">parseAddress</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">void parseAddress(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; str,<br />&nbsp;&nbsp;&nbsp;&nbsp;<a href="Poco.Net.SocketAddress.html" title="class Poco::Net::SocketAddress">SocketAddress</a> &amp; addr<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12353">parseExtAddress</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">void parseExtAddress(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; str,<br />&nbsp;&nbsp;&nbsp;&nbsp;<a href="Poco.Net.SocketAddress.html" title="class Poco::Net::SocketAddress">SocketAddress</a> &amp; addr<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12336">passiveDataConnection</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl"><a href="Poco.Net.StreamSocket.html" title="class Poco::Net::StreamSocket">StreamSocket</a> passiveDataConnection(<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; command,<br />&nbsp;&nbsp;&nbsp;&nbsp;const std::string &amp; arg<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12342">sendEPRT</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">bool sendEPRT(<br />&nbsp;&nbsp;&nbsp;&nbsp;const <a href="Poco.Net.SocketAddress.html" title="class Poco::Net::SocketAddress">SocketAddress</a> &amp; addr<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12346">sendEPSV</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">bool sendEPSV(<br />&nbsp;&nbsp;&nbsp;&nbsp;<a href="Poco.Net.SocketAddress.html" title="class Poco::Net::SocketAddress">SocketAddress</a> &amp; addr<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12348">sendPASV</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">void sendPASV(<br />&nbsp;&nbsp;&nbsp;&nbsp;<a href="Poco.Net.SocketAddress.html" title="class Poco::Net::SocketAddress">SocketAddress</a> &amp; addr<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12344">sendPORT</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">void sendPORT(<br />&nbsp;&nbsp;&nbsp;&nbsp;const <a href="Poco.Net.SocketAddress.html" title="class Poco::Net::SocketAddress">SocketAddress</a> &amp; addr<br />);</p>
<div class="description">
<p></p>
</div>
<h3><a name="12341">sendPassiveCommand</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl"><a href="Poco.Net.SocketAddress.html" title="class Poco::Net::SocketAddress">SocketAddress</a> sendPassiveCommand();</p>
<div class="description">
<p></p>
</div>
<h3><a name="12339">sendPortCommand</a> <img src="images/protected.gif" alt="protected" title="protected" style="vertical-align:baseline;" border="0" /> </h3>
<p class="decl">void sendPortCommand(<br />&nbsp;&nbsp;&nbsp;&nbsp;const <a href="Poco.Net.SocketAddress.html" title="class Poco::Net::SocketAddress">SocketAddress</a> &amp; addr<br />);</p>
<div class="description">
<p></p>
</div>
<p class="footer">POCO C++ Libraries 1.3.6-all<br />
Copyright &copy; 2009, <a href="http://pocoproject.org/" target="_blank">Applied Informatics Software Engineering GmbH and Contributors</a></p>

</div>
</body>
</html>