summaryrefslogtreecommitdiff
path: root/docs/paramiko.file-pysrc.html
diff options
context:
space:
mode:
Diffstat (limited to 'docs/paramiko.file-pysrc.html')
-rw-r--r--docs/paramiko.file-pysrc.html106
1 files changed, 53 insertions, 53 deletions
diff --git a/docs/paramiko.file-pysrc.html b/docs/paramiko.file-pysrc.html
index 0679425..2faa07f 100644
--- a/docs/paramiko.file-pysrc.html
+++ b/docs/paramiko.file-pysrc.html
@@ -54,24 +54,24 @@
</table>
<h1 class="epydoc">Source Code for <a href="paramiko.file-module.html" onclick="show_private();">Module paramiko.file</a></h1>
<pre class="py-src">
-<a name="L1"></a><tt class="py-lineno"> 1</tt> <tt class="py-line"><tt class="py-comment"># Copyright (C) 2003-2007 Robey Pointer &lt;robey@lag.net&gt;</tt> </tt>
-<a name="L2"></a><tt class="py-lineno"> 2</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment">#</tt> </tt>
-<a name="L3"></a><tt class="py-lineno"> 3</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># This file is part of paramiko.</tt> </tt>
-<a name="L4"></a><tt class="py-lineno"> 4</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment">#</tt> </tt>
-<a name="L5"></a><tt class="py-lineno"> 5</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># Paramiko is free software; you can redistribute it and/or modify it under the</tt> </tt>
-<a name="L6"></a><tt class="py-lineno"> 6</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># terms of the GNU Lesser General Public License as published by the Free</tt> </tt>
-<a name="L7"></a><tt class="py-lineno"> 7</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># Software Foundation; either version 2.1 of the License, or (at your option)</tt> </tt>
-<a name="L8"></a><tt class="py-lineno"> 8</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># any later version.</tt> </tt>
-<a name="L9"></a><tt class="py-lineno"> 9</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment">#</tt> </tt>
-<a name="L10"></a><tt class="py-lineno"> 10</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># Paramiko is distrubuted in the hope that it will be useful, but WITHOUT ANY</tt> </tt>
-<a name="L11"></a><tt class="py-lineno"> 11</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR</tt> </tt>
-<a name="L12"></a><tt class="py-lineno"> 12</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more</tt> </tt>
-<a name="L13"></a><tt class="py-lineno"> 13</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># details.</tt> </tt>
-<a name="L14"></a><tt class="py-lineno"> 14</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment">#</tt> </tt>
-<a name="L15"></a><tt class="py-lineno"> 15</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># You should have received a copy of the GNU Lesser General Public License</tt> </tt>
-<a name="L16"></a><tt class="py-lineno"> 16</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># along with Paramiko; if not, write to the Free Software Foundation, Inc.,</tt> </tt>
-<a name="L17"></a><tt class="py-lineno"> 17</tt> <tt class="py-line"><tt class="py-comment"></tt><tt class="py-comment"># 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.</tt> </tt>
-<a name="L18"></a><tt class="py-lineno"> 18</tt> <tt class="py-line"><tt class="py-comment"></tt> </tt>
+<a name="L1"></a><tt class="py-lineno"> 1</tt> <tt class="py-line"><tt class="py-comment"># Copyright (C) 2003-2007 Robey Pointer &lt;robeypointer@gmail.com&gt;</tt> </tt>
+<a name="L2"></a><tt class="py-lineno"> 2</tt> <tt class="py-line"><tt class="py-comment">#</tt> </tt>
+<a name="L3"></a><tt class="py-lineno"> 3</tt> <tt class="py-line"><tt class="py-comment"># This file is part of paramiko.</tt> </tt>
+<a name="L4"></a><tt class="py-lineno"> 4</tt> <tt class="py-line"><tt class="py-comment">#</tt> </tt>
+<a name="L5"></a><tt class="py-lineno"> 5</tt> <tt class="py-line"><tt class="py-comment"># Paramiko is free software; you can redistribute it and/or modify it under the</tt> </tt>
+<a name="L6"></a><tt class="py-lineno"> 6</tt> <tt class="py-line"><tt class="py-comment"># terms of the GNU Lesser General Public License as published by the Free</tt> </tt>
+<a name="L7"></a><tt class="py-lineno"> 7</tt> <tt class="py-line"><tt class="py-comment"># Software Foundation; either version 2.1 of the License, or (at your option)</tt> </tt>
+<a name="L8"></a><tt class="py-lineno"> 8</tt> <tt class="py-line"><tt class="py-comment"># any later version.</tt> </tt>
+<a name="L9"></a><tt class="py-lineno"> 9</tt> <tt class="py-line"><tt class="py-comment">#</tt> </tt>
+<a name="L10"></a><tt class="py-lineno"> 10</tt> <tt class="py-line"><tt class="py-comment"># Paramiko is distrubuted in the hope that it will be useful, but WITHOUT ANY</tt> </tt>
+<a name="L11"></a><tt class="py-lineno"> 11</tt> <tt class="py-line"><tt class="py-comment"># WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR</tt> </tt>
+<a name="L12"></a><tt class="py-lineno"> 12</tt> <tt class="py-line"><tt class="py-comment"># A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more</tt> </tt>
+<a name="L13"></a><tt class="py-lineno"> 13</tt> <tt class="py-line"><tt class="py-comment"># details.</tt> </tt>
+<a name="L14"></a><tt class="py-lineno"> 14</tt> <tt class="py-line"><tt class="py-comment">#</tt> </tt>
+<a name="L15"></a><tt class="py-lineno"> 15</tt> <tt class="py-line"><tt class="py-comment"># You should have received a copy of the GNU Lesser General Public License</tt> </tt>
+<a name="L16"></a><tt class="py-lineno"> 16</tt> <tt class="py-line"><tt class="py-comment"># along with Paramiko; if not, write to the Free Software Foundation, Inc.,</tt> </tt>
+<a name="L17"></a><tt class="py-lineno"> 17</tt> <tt class="py-line"><tt class="py-comment"># 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.</tt> </tt>
+<a name="L18"></a><tt class="py-lineno"> 18</tt> <tt class="py-line"> </tt>
<a name="L19"></a><tt class="py-lineno"> 19</tt> <tt class="py-line"><tt class="py-docstring">"""</tt> </tt>
<a name="L20"></a><tt class="py-lineno"> 20</tt> <tt class="py-line"><tt class="py-docstring">BufferedFile.</tt> </tt>
<a name="L21"></a><tt class="py-lineno"> 21</tt> <tt class="py-line"><tt class="py-docstring">"""</tt> </tt>
@@ -108,11 +108,11 @@
<a name="L52"></a><tt class="py-lineno"> 52</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_at_trailing_cr</tt> <tt class="py-op">=</tt> <tt class="py-name">False</tt> </tt>
<a name="L53"></a><tt class="py-lineno"> 53</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_closed</tt> <tt class="py-op">=</tt> <tt class="py-name">False</tt> </tt>
<a name="L54"></a><tt class="py-lineno"> 54</tt> <tt class="py-line"> <tt class="py-comment"># pos - position within the file, according to the user</tt> </tt>
-<a name="L55"></a><tt class="py-lineno"> 55</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># realpos - position according the OS</tt> </tt>
-<a name="L56"></a><tt class="py-lineno"> 56</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># (these may be different because we buffer for line reading)</tt> </tt>
-<a name="L57"></a><tt class="py-lineno"> 57</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_pos</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_realpos</tt> <tt class="py-op">=</tt> <tt class="py-number">0</tt> </tt>
+<a name="L55"></a><tt class="py-lineno"> 55</tt> <tt class="py-line"> <tt class="py-comment"># realpos - position according the OS</tt> </tt>
+<a name="L56"></a><tt class="py-lineno"> 56</tt> <tt class="py-line"> <tt class="py-comment"># (these may be different because we buffer for line reading)</tt> </tt>
+<a name="L57"></a><tt class="py-lineno"> 57</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_pos</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_realpos</tt> <tt class="py-op">=</tt> <tt class="py-number">0</tt> </tt>
<a name="L58"></a><tt class="py-lineno"> 58</tt> <tt class="py-line"> <tt class="py-comment"># size only matters for seekable files</tt> </tt>
-<a name="L59"></a><tt class="py-lineno"> 59</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_size</tt> <tt class="py-op">=</tt> <tt class="py-number">0</tt> </tt>
+<a name="L59"></a><tt class="py-lineno"> 59</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_size</tt> <tt class="py-op">=</tt> <tt class="py-number">0</tt> </tt>
</div><a name="L60"></a><tt class="py-lineno"> 60</tt> <tt class="py-line"> </tt>
<a name="BufferedFile.__del__"></a><div id="BufferedFile.__del__-def"><a name="L61"></a><tt class="py-lineno"> 61</tt> <a class="py-toggle" href="#" id="BufferedFile.__del__-toggle" onclick="return toggle('BufferedFile.__del__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="paramiko.file.BufferedFile-class.html#__del__">__del__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="BufferedFile.__del__-collapsed" style="display:none;" pad="+++" indent="++++++++"></div><div id="BufferedFile.__del__-expanded"><a name="L62"></a><tt class="py-lineno"> 62</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-12" class="py-name" targets="Method paramiko.Agent.close()=paramiko.Agent-class.html#close,Method paramiko.BufferedFile.close()=paramiko.BufferedFile-class.html#close,Method paramiko.Channel.close()=paramiko.Channel-class.html#close,Method paramiko.SFTPClient.close()=paramiko.SFTPClient-class.html#close,Method paramiko.SFTPFile.close()=paramiko.SFTPFile-class.html#close,Method paramiko.SFTPHandle.close()=paramiko.SFTPHandle-class.html#close,Method paramiko.SSHClient.close()=paramiko.SSHClient-class.html#close,Method paramiko.Transport.close()=paramiko.Transport-class.html#close,Method paramiko.buffered_pipe.BufferedPipe.close()=paramiko.buffered_pipe.BufferedPipe-class.html#close,Method paramiko.pipe.PosixPipe.close()=paramiko.pipe.PosixPipe-class.html#close,Method paramiko.pipe.WindowsPipe.close()=paramiko.pipe.WindowsPipe-class.html#close,Method paramiko.win_pageant.PageantConnection.close()=paramiko.win_pageant.PageantConnection-class.html#close"><a title="paramiko.Agent.close
@@ -193,7 +193,7 @@ paramiko.win_pageant.PageantConnection.close" class="py-name" href="#" onclick="
<a name="L126"></a><tt class="py-lineno">126</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">IOError</tt><tt class="py-op">(</tt><tt class="py-string">'File is not open for reading'</tt><tt class="py-op">)</tt> </tt>
<a name="L127"></a><tt class="py-lineno">127</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-op">(</tt><tt class="py-name">size</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">)</tt> <tt class="py-keyword">or</tt> <tt class="py-op">(</tt><tt class="py-name">size</tt> <tt class="py-op">&lt;</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L128"></a><tt class="py-lineno">128</tt> <tt class="py-line"> <tt class="py-comment"># go for broke</tt> </tt>
-<a name="L129"></a><tt class="py-lineno">129</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">result</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_rbuffer</tt> </tt>
+<a name="L129"></a><tt class="py-lineno">129</tt> <tt class="py-line"> <tt class="py-name">result</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_rbuffer</tt> </tt>
<a name="L130"></a><tt class="py-lineno">130</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_rbuffer</tt> <tt class="py-op">=</tt> <tt class="py-string">''</tt> </tt>
<a name="L131"></a><tt class="py-lineno">131</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_pos</tt> <tt class="py-op">+=</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">result</tt><tt class="py-op">)</tt> </tt>
<a name="L132"></a><tt class="py-lineno">132</tt> <tt class="py-line"> <tt class="py-keyword">while</tt> <tt class="py-name">True</tt><tt class="py-op">:</tt> </tt>
@@ -248,7 +248,7 @@ paramiko.win_pageant.PageantConnection.close" class="py-name" href="#" onclick="
<a name="L181"></a><tt class="py-lineno">181</tt> <tt class="py-line"><tt class="py-docstring"> @rtype: str</tt> </tt>
<a name="L182"></a><tt class="py-lineno">182</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
<a name="L183"></a><tt class="py-lineno">183</tt> <tt class="py-line"> <tt class="py-comment"># it's almost silly how complex this function is.</tt> </tt>
-<a name="L184"></a><tt class="py-lineno">184</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_closed</tt><tt class="py-op">:</tt> </tt>
+<a name="L184"></a><tt class="py-lineno">184</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_closed</tt><tt class="py-op">:</tt> </tt>
<a name="L185"></a><tt class="py-lineno">185</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">IOError</tt><tt class="py-op">(</tt><tt class="py-string">'File is closed'</tt><tt class="py-op">)</tt> </tt>
<a name="L186"></a><tt class="py-lineno">186</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">&amp;</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-18" class="py-name"><a title="paramiko.BufferedFile.FLAG_READ" class="py-name" href="#" onclick="return doclink('link-18', 'FLAG_READ', 'link-4');">FLAG_READ</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L187"></a><tt class="py-lineno">187</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">IOError</tt><tt class="py-op">(</tt><tt class="py-string">'File not open for reading'</tt><tt class="py-op">)</tt> </tt>
@@ -256,19 +256,19 @@ paramiko.win_pageant.PageantConnection.close" class="py-name" href="#" onclick="
<a name="L189"></a><tt class="py-lineno">189</tt> <tt class="py-line"> <tt class="py-keyword">while</tt> <tt class="py-name">True</tt><tt class="py-op">:</tt> </tt>
<a name="L190"></a><tt class="py-lineno">190</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_at_trailing_cr</tt> <tt class="py-keyword">and</tt> <tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">&amp;</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-19" class="py-name"><a title="paramiko.BufferedFile.FLAG_UNIVERSAL_NEWLINE" class="py-name" href="#" onclick="return doclink('link-19', 'FLAG_UNIVERSAL_NEWLINE', 'link-10');">FLAG_UNIVERSAL_NEWLINE</a></tt><tt class="py-op">)</tt> <tt class="py-keyword">and</tt> <tt class="py-op">(</tt><tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">line</tt><tt class="py-op">)</tt> <tt class="py-op">&gt;</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L191"></a><tt class="py-lineno">191</tt> <tt class="py-line"> <tt class="py-comment"># edge case: the newline may be '\r\n' and we may have read</tt> </tt>
-<a name="L192"></a><tt class="py-lineno">192</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># only the first '\r' last time.</tt> </tt>
-<a name="L193"></a><tt class="py-lineno">193</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">if</tt> <tt class="py-name">line</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">'\n'</tt><tt class="py-op">:</tt> </tt>
+<a name="L192"></a><tt class="py-lineno">192</tt> <tt class="py-line"> <tt class="py-comment"># only the first '\r' last time.</tt> </tt>
+<a name="L193"></a><tt class="py-lineno">193</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">line</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">'\n'</tt><tt class="py-op">:</tt> </tt>
<a name="L194"></a><tt class="py-lineno">194</tt> <tt class="py-line"> <tt class="py-name">line</tt> <tt class="py-op">=</tt> <tt class="py-name">line</tt><tt class="py-op">[</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
<a name="L195"></a><tt class="py-lineno">195</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_record_newline</tt><tt class="py-op">(</tt><tt class="py-string">'\r\n'</tt><tt class="py-op">)</tt> </tt>
<a name="L196"></a><tt class="py-lineno">196</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
<a name="L197"></a><tt class="py-lineno">197</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_record_newline</tt><tt class="py-op">(</tt><tt class="py-string">'\r'</tt><tt class="py-op">)</tt> </tt>
<a name="L198"></a><tt class="py-lineno">198</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_at_trailing_cr</tt> <tt class="py-op">=</tt> <tt class="py-name">False</tt> </tt>
<a name="L199"></a><tt class="py-lineno">199</tt> <tt class="py-line"> <tt class="py-comment"># check size before looking for a linefeed, in case we already have</tt> </tt>
-<a name="L200"></a><tt class="py-lineno">200</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># enough.</tt> </tt>
-<a name="L201"></a><tt class="py-lineno">201</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">if</tt> <tt class="py-op">(</tt><tt class="py-name">size</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">)</tt> <tt class="py-keyword">and</tt> <tt class="py-op">(</tt><tt class="py-name">size</tt> <tt class="py-op">&gt;=</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L200"></a><tt class="py-lineno">200</tt> <tt class="py-line"> <tt class="py-comment"># enough.</tt> </tt>
+<a name="L201"></a><tt class="py-lineno">201</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-op">(</tt><tt class="py-name">size</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">)</tt> <tt class="py-keyword">and</tt> <tt class="py-op">(</tt><tt class="py-name">size</tt> <tt class="py-op">&gt;=</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L202"></a><tt class="py-lineno">202</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">line</tt><tt class="py-op">)</tt> <tt class="py-op">&gt;=</tt> <tt class="py-name">size</tt><tt class="py-op">:</tt> </tt>
<a name="L203"></a><tt class="py-lineno">203</tt> <tt class="py-line"> <tt class="py-comment"># truncate line and return</tt> </tt>
-<a name="L204"></a><tt class="py-lineno">204</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_rbuffer</tt> <tt class="py-op">=</tt> <tt class="py-name">line</tt><tt class="py-op">[</tt><tt class="py-name">size</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
+<a name="L204"></a><tt class="py-lineno">204</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_rbuffer</tt> <tt class="py-op">=</tt> <tt class="py-name">line</tt><tt class="py-op">[</tt><tt class="py-name">size</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
<a name="L205"></a><tt class="py-lineno">205</tt> <tt class="py-line"> <tt class="py-name">line</tt> <tt class="py-op">=</tt> <tt class="py-name">line</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-name">size</tt><tt class="py-op">]</tt> </tt>
<a name="L206"></a><tt class="py-lineno">206</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_pos</tt> <tt class="py-op">+=</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">line</tt><tt class="py-op">)</tt> </tt>
<a name="L207"></a><tt class="py-lineno">207</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">line</tt> </tt>
@@ -288,7 +288,7 @@ paramiko.win_pageant.PageantConnection.close" class="py-name" href="#" onclick="
<a name="L221"></a><tt class="py-lineno">221</tt> <tt class="py-line"> <tt class="py-name">line</tt> <tt class="py-op">+=</tt> <tt class="py-name">new_data</tt> </tt>
<a name="L222"></a><tt class="py-lineno">222</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_realpos</tt> <tt class="py-op">+=</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">new_data</tt><tt class="py-op">)</tt> </tt>
<a name="L223"></a><tt class="py-lineno">223</tt> <tt class="py-line"> <tt class="py-comment"># find the newline</tt> </tt>
-<a name="L224"></a><tt class="py-lineno">224</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">pos</tt> <tt class="py-op">=</tt> <tt class="py-name">line</tt><tt class="py-op">.</tt><tt class="py-name">find</tt><tt class="py-op">(</tt><tt class="py-string">'\n'</tt><tt class="py-op">)</tt> </tt>
+<a name="L224"></a><tt class="py-lineno">224</tt> <tt class="py-line"> <tt class="py-name">pos</tt> <tt class="py-op">=</tt> <tt class="py-name">line</tt><tt class="py-op">.</tt><tt class="py-name">find</tt><tt class="py-op">(</tt><tt class="py-string">'\n'</tt><tt class="py-op">)</tt> </tt>
<a name="L225"></a><tt class="py-lineno">225</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">&amp;</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-21" class="py-name"><a title="paramiko.BufferedFile.FLAG_UNIVERSAL_NEWLINE" class="py-name" href="#" onclick="return doclink('link-21', 'FLAG_UNIVERSAL_NEWLINE', 'link-10');">FLAG_UNIVERSAL_NEWLINE</a></tt><tt class="py-op">:</tt> </tt>
<a name="L226"></a><tt class="py-lineno">226</tt> <tt class="py-line"> <tt class="py-name">rpos</tt> <tt class="py-op">=</tt> <tt class="py-name">line</tt><tt class="py-op">.</tt><tt class="py-name">find</tt><tt class="py-op">(</tt><tt class="py-string">'\r'</tt><tt class="py-op">)</tt> </tt>
<a name="L227"></a><tt class="py-lineno">227</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-op">(</tt><tt class="py-name">rpos</tt> <tt class="py-op">&gt;=</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt> <tt class="py-keyword">and</tt> <tt class="py-op">(</tt><tt class="py-op">(</tt><tt class="py-name">rpos</tt> <tt class="py-op">&lt;</tt> <tt class="py-name">pos</tt><tt class="py-op">)</tt> <tt class="py-keyword">or</tt> <tt class="py-op">(</tt><tt class="py-name">pos</tt> <tt class="py-op">&lt;</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
@@ -301,8 +301,8 @@ paramiko.win_pageant.PageantConnection.close" class="py-name" href="#" onclick="
<a name="L234"></a><tt class="py-lineno">234</tt> <tt class="py-line"> <tt class="py-name">line</tt> <tt class="py-op">=</tt> <tt class="py-name">line</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-name">pos</tt><tt class="py-op">]</tt> <tt class="py-op">+</tt> <tt class="py-string">'\n'</tt> </tt>
<a name="L235"></a><tt class="py-lineno">235</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-op">(</tt><tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_rbuffer</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt> <tt class="py-keyword">and</tt> <tt class="py-op">(</tt><tt class="py-name">lf</tt> <tt class="py-op">==</tt> <tt class="py-string">'\r'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L236"></a><tt class="py-lineno">236</tt> <tt class="py-line"> <tt class="py-comment"># we could read the line up to a '\r' and there could still be a</tt> </tt>
-<a name="L237"></a><tt class="py-lineno">237</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># '\n' following that we read next time. note that and eat it.</tt> </tt>
-<a name="L238"></a><tt class="py-lineno">238</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_at_trailing_cr</tt> <tt class="py-op">=</tt> <tt class="py-name">True</tt> </tt>
+<a name="L237"></a><tt class="py-lineno">237</tt> <tt class="py-line"> <tt class="py-comment"># '\n' following that we read next time. note that and eat it.</tt> </tt>
+<a name="L238"></a><tt class="py-lineno">238</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_at_trailing_cr</tt> <tt class="py-op">=</tt> <tt class="py-name">True</tt> </tt>
<a name="L239"></a><tt class="py-lineno">239</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
<a name="L240"></a><tt class="py-lineno">240</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_record_newline</tt><tt class="py-op">(</tt><tt class="py-name">lf</tt><tt class="py-op">)</tt> </tt>
<a name="L241"></a><tt class="py-lineno">241</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_pos</tt> <tt class="py-op">+=</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">line</tt><tt class="py-op">)</tt> </tt>
@@ -384,7 +384,7 @@ paramiko.win_pageant.PageantConnection.close" class="py-name" href="#" onclick="
paramiko.SFTPHandle.write" class="py-name" href="#" onclick="return doclink('link-25', 'write', 'link-25');">write</a></tt><tt class="py-op">(</tt><tt class="py-name">data</tt><tt class="py-op">)</tt> </tt>
<a name="L317"></a><tt class="py-lineno">317</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">&amp;</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-26" class="py-name"><a title="paramiko.BufferedFile.FLAG_LINE_BUFFERED" class="py-name" href="#" onclick="return doclink('link-26', 'FLAG_LINE_BUFFERED', 'link-9');">FLAG_LINE_BUFFERED</a></tt><tt class="py-op">:</tt> </tt>
<a name="L318"></a><tt class="py-lineno">318</tt> <tt class="py-line"> <tt class="py-comment"># only scan the new data for linefeed, to avoid wasting time.</tt> </tt>
-<a name="L319"></a><tt class="py-lineno">319</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">last_newline_pos</tt> <tt class="py-op">=</tt> <tt class="py-name">data</tt><tt class="py-op">.</tt><tt class="py-name">rfind</tt><tt class="py-op">(</tt><tt class="py-string">'\n'</tt><tt class="py-op">)</tt> </tt>
+<a name="L319"></a><tt class="py-lineno">319</tt> <tt class="py-line"> <tt class="py-name">last_newline_pos</tt> <tt class="py-op">=</tt> <tt class="py-name">data</tt><tt class="py-op">.</tt><tt class="py-name">rfind</tt><tt class="py-op">(</tt><tt class="py-string">'\n'</tt><tt class="py-op">)</tt> </tt>
<a name="L320"></a><tt class="py-lineno">320</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">last_newline_pos</tt> <tt class="py-op">&gt;=</tt> <tt class="py-number">0</tt><tt class="py-op">:</tt> </tt>
<a name="L321"></a><tt class="py-lineno">321</tt> <tt class="py-line"> <tt class="py-name">wbuf</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_wbuffer</tt><tt class="py-op">.</tt><tt class="py-name">getvalue</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L322"></a><tt class="py-lineno">322</tt> <tt class="py-line"> <tt class="py-name">last_newline_pos</tt> <tt class="py-op">+=</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">wbuf</tt><tt class="py-op">)</tt> <tt class="py-op">-</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">data</tt><tt class="py-op">)</tt> </tt>
@@ -394,8 +394,8 @@ paramiko.SFTPHandle.write" class="py-name" href="#" onclick="return doclink('lin
paramiko.SFTPHandle.write" class="py-name" href="#" onclick="return doclink('link-27', 'write', 'link-25');">write</a></tt><tt class="py-op">(</tt><tt class="py-name">wbuf</tt><tt class="py-op">[</tt><tt class="py-name">last_newline_pos</tt> <tt class="py-op">+</tt> <tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">]</tt><tt class="py-op">)</tt> </tt>
<a name="L326"></a><tt class="py-lineno">326</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> </tt>
<a name="L327"></a><tt class="py-lineno">327</tt> <tt class="py-line"> <tt class="py-comment"># even if we're line buffering, if the buffer has grown past the</tt> </tt>
-<a name="L328"></a><tt class="py-lineno">328</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># buffer size, force a flush.</tt> </tt>
-<a name="L329"></a><tt class="py-lineno">329</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_wbuffer</tt><tt class="py-op">.</tt><tt id="link-28" class="py-name" targets="Method paramiko.BufferedFile.tell()=paramiko.BufferedFile-class.html#tell"><a title="paramiko.BufferedFile.tell" class="py-name" href="#" onclick="return doclink('link-28', 'tell', 'link-28');">tell</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">&gt;=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_bufsize</tt><tt class="py-op">:</tt> </tt>
+<a name="L328"></a><tt class="py-lineno">328</tt> <tt class="py-line"> <tt class="py-comment"># buffer size, force a flush.</tt> </tt>
+<a name="L329"></a><tt class="py-lineno">329</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_wbuffer</tt><tt class="py-op">.</tt><tt id="link-28" class="py-name" targets="Method paramiko.BufferedFile.tell()=paramiko.BufferedFile-class.html#tell"><a title="paramiko.BufferedFile.tell" class="py-name" href="#" onclick="return doclink('link-28', 'tell', 'link-28');">tell</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">&gt;=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_bufsize</tt><tt class="py-op">:</tt> </tt>
<a name="L330"></a><tt class="py-lineno">330</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-29" class="py-name"><a title="paramiko.BufferedFile.flush" class="py-name" href="#" onclick="return doclink('link-29', 'flush', 'link-13');">flush</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
<a name="L331"></a><tt class="py-lineno">331</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> </tt>
</div><a name="L332"></a><tt class="py-lineno">332</tt> <tt class="py-line"> </tt>
@@ -426,7 +426,7 @@ paramiko.SFTPHandle.write" class="py-name" href="#" onclick="return doclink('lin
</div><a name="L356"></a><tt class="py-lineno">356</tt> <tt class="py-line"> </tt>
<a name="L357"></a><tt class="py-lineno">357</tt> <tt class="py-line"> </tt>
<a name="L358"></a><tt class="py-lineno">358</tt> <tt class="py-line"> <tt class="py-comment">### overrides...</tt> </tt>
-<a name="L359"></a><tt class="py-lineno">359</tt> <tt class="py-line"><tt class="py-comment"></tt> </tt>
+<a name="L359"></a><tt class="py-lineno">359</tt> <tt class="py-line"> </tt>
<a name="L360"></a><tt class="py-lineno">360</tt> <tt class="py-line"> </tt>
<a name="BufferedFile._read"></a><div id="BufferedFile._read-def"><a name="L361"></a><tt class="py-lineno">361</tt> <a class="py-toggle" href="#" id="BufferedFile._read-toggle" onclick="return toggle('BufferedFile._read');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="paramiko.file.BufferedFile-class.html#_read">_read</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">size</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="BufferedFile._read-collapsed" style="display:none;" pad="+++" indent="++++++++"></div><div id="BufferedFile._read-expanded"><a name="L362"></a><tt class="py-lineno">362</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
@@ -456,30 +456,30 @@ paramiko.SFTPHandle.write" class="py-name" href="#" onclick="return doclink('lin
</div><a name="L386"></a><tt class="py-lineno">386</tt> <tt class="py-line"> </tt>
<a name="L387"></a><tt class="py-lineno">387</tt> <tt class="py-line"> </tt>
<a name="L388"></a><tt class="py-lineno">388</tt> <tt class="py-line"> <tt class="py-comment">### internals...</tt> </tt>
-<a name="L389"></a><tt class="py-lineno">389</tt> <tt class="py-line"><tt class="py-comment"></tt> </tt>
+<a name="L389"></a><tt class="py-lineno">389</tt> <tt class="py-line"> </tt>
<a name="L390"></a><tt class="py-lineno">390</tt> <tt class="py-line"> </tt>
<a name="BufferedFile._set_mode"></a><div id="BufferedFile._set_mode-def"><a name="L391"></a><tt class="py-lineno">391</tt> <a class="py-toggle" href="#" id="BufferedFile._set_mode-toggle" onclick="return toggle('BufferedFile._set_mode');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="paramiko.file.BufferedFile-class.html#_set_mode">_set_mode</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">mode</tt><tt class="py-op">=</tt><tt class="py-string">'r'</tt><tt class="py-op">,</tt> <tt class="py-param">bufsize</tt><tt class="py-op">=</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="BufferedFile._set_mode-collapsed" style="display:none;" pad="+++" indent="++++++++"></div><div id="BufferedFile._set_mode-expanded"><a name="L392"></a><tt class="py-lineno">392</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
<a name="L393"></a><tt class="py-lineno">393</tt> <tt class="py-line"><tt class="py-docstring"> Subclasses call this method to initialize the BufferedFile.</tt> </tt>
<a name="L394"></a><tt class="py-lineno">394</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
<a name="L395"></a><tt class="py-lineno">395</tt> <tt class="py-line"> <tt class="py-comment"># set bufsize in any event, because it's used for readline().</tt> </tt>
-<a name="L396"></a><tt class="py-lineno">396</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_bufsize</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-31" class="py-name"><a title="paramiko.BufferedFile._DEFAULT_BUFSIZE" class="py-name" href="#" onclick="return doclink('link-31', '_DEFAULT_BUFSIZE', 'link-0');">_DEFAULT_BUFSIZE</a></tt> </tt>
+<a name="L396"></a><tt class="py-lineno">396</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_bufsize</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-31" class="py-name"><a title="paramiko.BufferedFile._DEFAULT_BUFSIZE" class="py-name" href="#" onclick="return doclink('link-31', '_DEFAULT_BUFSIZE', 'link-0');">_DEFAULT_BUFSIZE</a></tt> </tt>
<a name="L397"></a><tt class="py-lineno">397</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">bufsize</tt> <tt class="py-op">&lt;</tt> <tt class="py-number">0</tt><tt class="py-op">:</tt> </tt>
<a name="L398"></a><tt class="py-lineno">398</tt> <tt class="py-line"> <tt class="py-comment"># do no buffering by default, because otherwise writes will get</tt> </tt>
-<a name="L399"></a><tt class="py-lineno">399</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># buffered in a way that will probably confuse people.</tt> </tt>
-<a name="L400"></a><tt class="py-lineno">400</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">bufsize</tt> <tt class="py-op">=</tt> <tt class="py-number">0</tt> </tt>
+<a name="L399"></a><tt class="py-lineno">399</tt> <tt class="py-line"> <tt class="py-comment"># buffered in a way that will probably confuse people.</tt> </tt>
+<a name="L400"></a><tt class="py-lineno">400</tt> <tt class="py-line"> <tt class="py-name">bufsize</tt> <tt class="py-op">=</tt> <tt class="py-number">0</tt> </tt>
<a name="L401"></a><tt class="py-lineno">401</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">bufsize</tt> <tt class="py-op">==</tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
<a name="L402"></a><tt class="py-lineno">402</tt> <tt class="py-line"> <tt class="py-comment"># apparently, line buffering only affects writes. reads are only</tt> </tt>
-<a name="L403"></a><tt class="py-lineno">403</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># buffered if you call readline (directly or indirectly: iterating</tt> </tt>
-<a name="L404"></a><tt class="py-lineno">404</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># over a file will indirectly call readline).</tt> </tt>
-<a name="L405"></a><tt class="py-lineno">405</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">|=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-32" class="py-name"><a title="paramiko.BufferedFile.FLAG_BUFFERED" class="py-name" href="#" onclick="return doclink('link-32', 'FLAG_BUFFERED', 'link-8');">FLAG_BUFFERED</a></tt> <tt class="py-op">|</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-33" class="py-name"><a title="paramiko.BufferedFile.FLAG_LINE_BUFFERED" class="py-name" href="#" onclick="return doclink('link-33', 'FLAG_LINE_BUFFERED', 'link-9');">FLAG_LINE_BUFFERED</a></tt> </tt>
+<a name="L403"></a><tt class="py-lineno">403</tt> <tt class="py-line"> <tt class="py-comment"># buffered if you call readline (directly or indirectly: iterating</tt> </tt>
+<a name="L404"></a><tt class="py-lineno">404</tt> <tt class="py-line"> <tt class="py-comment"># over a file will indirectly call readline).</tt> </tt>
+<a name="L405"></a><tt class="py-lineno">405</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">|=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-32" class="py-name"><a title="paramiko.BufferedFile.FLAG_BUFFERED" class="py-name" href="#" onclick="return doclink('link-32', 'FLAG_BUFFERED', 'link-8');">FLAG_BUFFERED</a></tt> <tt class="py-op">|</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-33" class="py-name"><a title="paramiko.BufferedFile.FLAG_LINE_BUFFERED" class="py-name" href="#" onclick="return doclink('link-33', 'FLAG_LINE_BUFFERED', 'link-9');">FLAG_LINE_BUFFERED</a></tt> </tt>
<a name="L406"></a><tt class="py-lineno">406</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">bufsize</tt> <tt class="py-op">&gt;</tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
<a name="L407"></a><tt class="py-lineno">407</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_bufsize</tt> <tt class="py-op">=</tt> <tt class="py-name">bufsize</tt> </tt>
<a name="L408"></a><tt class="py-lineno">408</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">|=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-34" class="py-name"><a title="paramiko.BufferedFile.FLAG_BUFFERED" class="py-name" href="#" onclick="return doclink('link-34', 'FLAG_BUFFERED', 'link-8');">FLAG_BUFFERED</a></tt> </tt>
<a name="L409"></a><tt class="py-lineno">409</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">&amp;=</tt> <tt class="py-op">~</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-35" class="py-name"><a title="paramiko.BufferedFile.FLAG_LINE_BUFFERED" class="py-name" href="#" onclick="return doclink('link-35', 'FLAG_LINE_BUFFERED', 'link-9');">FLAG_LINE_BUFFERED</a></tt> </tt>
<a name="L410"></a><tt class="py-lineno">410</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">bufsize</tt> <tt class="py-op">==</tt> <tt class="py-number">0</tt><tt class="py-op">:</tt> </tt>
<a name="L411"></a><tt class="py-lineno">411</tt> <tt class="py-line"> <tt class="py-comment"># unbuffered</tt> </tt>
-<a name="L412"></a><tt class="py-lineno">412</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">&amp;=</tt> <tt class="py-op">~</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-36" class="py-name"><a title="paramiko.BufferedFile.FLAG_BUFFERED" class="py-name" href="#" onclick="return doclink('link-36', 'FLAG_BUFFERED', 'link-8');">FLAG_BUFFERED</a></tt> <tt class="py-op">|</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-37" class="py-name"><a title="paramiko.BufferedFile.FLAG_LINE_BUFFERED" class="py-name" href="#" onclick="return doclink('link-37', 'FLAG_LINE_BUFFERED', 'link-9');">FLAG_LINE_BUFFERED</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L412"></a><tt class="py-lineno">412</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">&amp;=</tt> <tt class="py-op">~</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-36" class="py-name"><a title="paramiko.BufferedFile.FLAG_BUFFERED" class="py-name" href="#" onclick="return doclink('link-36', 'FLAG_BUFFERED', 'link-8');">FLAG_BUFFERED</a></tt> <tt class="py-op">|</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-37" class="py-name"><a title="paramiko.BufferedFile.FLAG_LINE_BUFFERED" class="py-name" href="#" onclick="return doclink('link-37', 'FLAG_LINE_BUFFERED', 'link-9');">FLAG_LINE_BUFFERED</a></tt><tt class="py-op">)</tt> </tt>
<a name="L413"></a><tt class="py-lineno">413</tt> <tt class="py-line"> </tt>
<a name="L414"></a><tt class="py-lineno">414</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-op">(</tt><tt class="py-string">'r'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">mode</tt><tt class="py-op">)</tt> <tt class="py-keyword">or</tt> <tt class="py-op">(</tt><tt class="py-string">'+'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">mode</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L415"></a><tt class="py-lineno">415</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">|=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-38" class="py-name"><a title="paramiko.BufferedFile.FLAG_READ" class="py-name" href="#" onclick="return doclink('link-38', 'FLAG_READ', 'link-4');">FLAG_READ</a></tt> </tt>
@@ -494,14 +494,14 @@ paramiko.SFTPHandle.write" class="py-name" href="#" onclick="return doclink('lin
<a name="L424"></a><tt class="py-lineno">424</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-op">(</tt><tt class="py-string">'U'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">mode</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L425"></a><tt class="py-lineno">425</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">|=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-43" class="py-name"><a title="paramiko.BufferedFile.FLAG_UNIVERSAL_NEWLINE" class="py-name" href="#" onclick="return doclink('link-43', 'FLAG_UNIVERSAL_NEWLINE', 'link-10');">FLAG_UNIVERSAL_NEWLINE</a></tt> </tt>
<a name="L426"></a><tt class="py-lineno">426</tt> <tt class="py-line"> <tt class="py-comment"># built-in file objects have this attribute to store which kinds of</tt> </tt>
-<a name="L427"></a><tt class="py-lineno">427</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># line terminations they've seen:</tt> </tt>
-<a name="L428"></a><tt class="py-lineno">428</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># &lt;http://www.python.org/doc/current/lib/built-in-funcs.html&gt;</tt> </tt>
-<a name="L429"></a><tt class="py-lineno">429</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">newlines</tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
+<a name="L427"></a><tt class="py-lineno">427</tt> <tt class="py-line"> <tt class="py-comment"># line terminations they've seen:</tt> </tt>
+<a name="L428"></a><tt class="py-lineno">428</tt> <tt class="py-line"> <tt class="py-comment"># &lt;http://www.python.org/doc/current/lib/built-in-funcs.html&gt;</tt> </tt>
+<a name="L429"></a><tt class="py-lineno">429</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">newlines</tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
</div><a name="L430"></a><tt class="py-lineno">430</tt> <tt class="py-line"> </tt>
<a name="BufferedFile._write_all"></a><div id="BufferedFile._write_all-def"><a name="L431"></a><tt class="py-lineno">431</tt> <a class="py-toggle" href="#" id="BufferedFile._write_all-toggle" onclick="return toggle('BufferedFile._write_all');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="paramiko.file.BufferedFile-class.html#_write_all">_write_all</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">data</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="BufferedFile._write_all-collapsed" style="display:none;" pad="+++" indent="++++++++"></div><div id="BufferedFile._write_all-expanded"><a name="L432"></a><tt class="py-lineno">432</tt> <tt class="py-line"> <tt class="py-comment"># the underlying stream may be something that does partial writes (like</tt> </tt>
-<a name="L433"></a><tt class="py-lineno">433</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># a socket).</tt> </tt>
-<a name="L434"></a><tt class="py-lineno">434</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">while</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">data</tt><tt class="py-op">)</tt> <tt class="py-op">&gt;</tt> <tt class="py-number">0</tt><tt class="py-op">:</tt> </tt>
+<a name="L433"></a><tt class="py-lineno">433</tt> <tt class="py-line"> <tt class="py-comment"># a socket).</tt> </tt>
+<a name="L434"></a><tt class="py-lineno">434</tt> <tt class="py-line"> <tt class="py-keyword">while</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">data</tt><tt class="py-op">)</tt> <tt class="py-op">&gt;</tt> <tt class="py-number">0</tt><tt class="py-op">:</tt> </tt>
<a name="L435"></a><tt class="py-lineno">435</tt> <tt class="py-line"> <tt class="py-name">count</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_write</tt><tt class="py-op">(</tt><tt class="py-name">data</tt><tt class="py-op">)</tt> </tt>
<a name="L436"></a><tt class="py-lineno">436</tt> <tt class="py-line"> <tt class="py-name">data</tt> <tt class="py-op">=</tt> <tt class="py-name">data</tt><tt class="py-op">[</tt><tt class="py-name">count</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
<a name="L437"></a><tt class="py-lineno">437</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">&amp;</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-44" class="py-name"><a title="paramiko.BufferedFile.FLAG_APPEND" class="py-name" href="#" onclick="return doclink('link-44', 'FLAG_APPEND', 'link-6');">FLAG_APPEND</a></tt><tt class="py-op">:</tt> </tt>
@@ -514,9 +514,9 @@ paramiko.SFTPHandle.write" class="py-name" href="#" onclick="return doclink('lin
</div><a name="L444"></a><tt class="py-lineno">444</tt> <tt class="py-line"> </tt>
<a name="BufferedFile._record_newline"></a><div id="BufferedFile._record_newline-def"><a name="L445"></a><tt class="py-lineno">445</tt> <a class="py-toggle" href="#" id="BufferedFile._record_newline-toggle" onclick="return toggle('BufferedFile._record_newline');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="paramiko.file.BufferedFile-class.html#_record_newline">_record_newline</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">newline</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="BufferedFile._record_newline-collapsed" style="display:none;" pad="+++" indent="++++++++"></div><div id="BufferedFile._record_newline-expanded"><a name="L446"></a><tt class="py-lineno">446</tt> <tt class="py-line"> <tt class="py-comment"># silliness about tracking what kinds of newlines we've seen.</tt> </tt>
-<a name="L447"></a><tt class="py-lineno">447</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># i don't understand why it can be None, a string, or a tuple, instead</tt> </tt>
-<a name="L448"></a><tt class="py-lineno">448</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-comment"># of just always being a tuple, but we'll emulate that behavior anyway.</tt> </tt>
-<a name="L449"></a><tt class="py-lineno">449</tt> <tt class="py-line"><tt class="py-comment"></tt> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">&amp;</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-45" class="py-name"><a title="paramiko.BufferedFile.FLAG_UNIVERSAL_NEWLINE" class="py-name" href="#" onclick="return doclink('link-45', 'FLAG_UNIVERSAL_NEWLINE', 'link-10');">FLAG_UNIVERSAL_NEWLINE</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L447"></a><tt class="py-lineno">447</tt> <tt class="py-line"> <tt class="py-comment"># i don't understand why it can be None, a string, or a tuple, instead</tt> </tt>
+<a name="L448"></a><tt class="py-lineno">448</tt> <tt class="py-line"> <tt class="py-comment"># of just always being a tuple, but we'll emulate that behavior anyway.</tt> </tt>
+<a name="L449"></a><tt class="py-lineno">449</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_flags</tt> <tt class="py-op">&amp;</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-45" class="py-name"><a title="paramiko.BufferedFile.FLAG_UNIVERSAL_NEWLINE" class="py-name" href="#" onclick="return doclink('link-45', 'FLAG_UNIVERSAL_NEWLINE', 'link-10');">FLAG_UNIVERSAL_NEWLINE</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L450"></a><tt class="py-lineno">450</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> </tt>
<a name="L451"></a><tt class="py-lineno">451</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">newlines</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
<a name="L452"></a><tt class="py-lineno">452</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">newlines</tt> <tt class="py-op">=</tt> <tt class="py-name">newline</tt> </tt>
@@ -557,7 +557,7 @@ expandto(location.href);
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
<tr>
<td align="left" class="footer">
- Generated by Epydoc 3.0.1 on Sun Jul 6 18:30:32 2008
+ Generated by Epydoc 3.0.1 on Sun Nov 1 22:14:19 2009
</td>
<td align="right" class="footer">
<a target="mainFrame" href="http://epydoc.sourceforge.net"