/usr/share/gtk-doc/html/pygobject/class-gioseekable.html is in python-gobject-2-dev 2.28.6-13.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
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 | <html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><title>gio.Seekable</title><link rel="stylesheet" type="text/css" href="style.css"><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="PyGObject Reference Manual"><link rel="up" href="gio-class-reference.html" title="PyGio Class Reference"><link rel="prev" href="class-giooutputstream.html" title="gio.OutputStream"><link rel="next" href="class-giosimpleasyncresult.html" title="gio.SimpleAsyncResult"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">gio.Seekable</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="class-giooutputstream.html">Prev</a> </td><th width="60%" align="center">PyGio Class Reference</th><td width="20%" align="right"> <a accesskey="n" href="class-giosimpleasyncresult.html">Next</a></td></tr></table><hr></div><div class="refentry" title="gio.Seekable"><a name="class-gioseekable"></a><div class="titlepage"></div><div class="refnamediv"><h2>gio.Seekable</h2><p>gio.Seekable — Stream seeking interface.</p></div><div class="refsect1" title="Synopsis"><a name="id526116"></a><h2>Synopsis</h2><table bgcolor="#D0E0F0" width="100%"><tr><td><pre class="classsynopsis">class <span class="ooclass"><span class="classname">gio.Seekable</span></span>(<span class="ooclass"><span class="classname"><a class="link" href="class-gobjectginterface.html" title="gobject.GInterface">gobject.GInterface</a></span></span>):
<code class="methodsynopsis"> def <span class="methodname"><a class="link" href="class-gioseekable.html#method-gioseekable--tell" title="gio.Seekable.tell">tell</a></span>()</code><br><code class="methodsynopsis"> def <span class="methodname"><a class="link" href="class-gioseekable.html#method-gioseekable--can_seek" title="gio.Seekable.can_seek">can_seek</a></span>()</code><br><code class="methodsynopsis"> def <span class="methodname"><a class="link" href="class-gioseekable.html#method-gioseekable--seek" title="gio.Seekable.seek">seek</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>offset</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>type</code></strong></span><span class="initializer">=0</span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>cancellable</code></strong></span><span class="initializer">=None</span></span>)</code><br><code class="methodsynopsis"> def <span class="methodname"><a class="link" href="class-gioseekable.html#method-gioseekable--can_truncate" title="gio.Seekable.can_truncate">can_truncate</a></span>()</code><br><code class="methodsynopsis"> def <span class="methodname"><a class="link" href="class-gioseekable.html#method-gioseekable--truncate" title="gio.Seekable.truncate">truncate</a></span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>offset</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>cancellable</code></strong></span><span class="initializer">=None</span></span>)</code><br></pre></td></tr></table></div><div class="refsect1" title="Ancestry"><a name="id526294"></a><h2>Ancestry</h2><pre class="synopsis">+-- <a class="link" href="class-gobjectginterface.html" title="gobject.GInterface">gobject.GInterface</a>
+-- <a class="link" href="class-gioseekable.html" title="gio.Seekable">gio.Seekable</a>
</pre></div><div class="refsect1" title="Known Implementation"><a name="id526320"></a><h2>Known Implementation</h2><p>
<a class="link" href="class-gioseekable.html" title="gio.Seekable"><code class="classname">gio.Seekable</code></a> is implemented by
<a class="link" href="class-giofileoutputstream.html" title="gio.FileOutputStream"><code class="classname">gio.FileOutputStream</code></a>,
<a class="link" href="class-giomemoryinputstream.html" title="gio.MemoryInputStream"><code class="classname">gio.MemoryInputStream</code></a>,
<a class="link" href="class-giofileinputstream.html" title="gio.FileInputStream"><code class="classname">gio.FileInputStream</code></a> and
<a class="link" href="class-giomemoryoutputstream.html" title="gio.MemoryOutputStream"><code class="classname">gio.MemoryOutputStream</code></a>.
</p></div><div class="refsect1" title="Description"><a name="id526367"></a><h2>Description</h2><p>
<a class="link" href="class-gioseekable.html" title="gio.Seekable"><code class="classname">gio.Seekable</code></a>
is implemented by streams (implementations of
<a class="link" href="class-gioinputstream.html" title="gio.InputStream"><code class="classname">gio.InputStream</code></a> or
<a class="link" href="class-giooutputstream.html" title="gio.OutputStream"><code class="classname">gio.OutputStream</code></a>)
that support seeking.
</p></div><div class="refsect1" title="Methods"><a name="id526400"></a><h2>Methods</h2><div class="refsect2" title="gio.Seekable.tell"><a name="method-gioseekable--tell"></a><h3>gio.Seekable.tell</h3><pre class="programlisting"><code class="methodsynopsis"> def <span class="methodname">tell</span>()</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>
the offset from the beginning of the buffer
</td></tr></tbody></table><p>
Tells the current position within the stream.
</p></div><div class="refsect2" title="gio.Seekable.can_seek"><a name="method-gioseekable--can_seek"></a><h3>gio.Seekable.can_seek</h3><pre class="programlisting"><code class="methodsynopsis"> def <span class="methodname">can_seek</span>()</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td><code class="literal">True</code> if this
<code class="classname">gio.Seekable</code> can be seeked with
the <code class="methodname">seek</code>() method, <code class="literal">False</code>
if not. </td></tr></tbody></table><p>
The <code class="methodname">can_seek</code>() method checks if the
<a class="link" href="class-gioseekable.html#method-gioseekable--seek" title="gio.Seekable.seek"><code class="methodname">seek</code>()</a>
can be used on this <code class="classname">gio.Seekable</code>.
</p></div><div class="refsect2" title="gio.Seekable.seek"><a name="method-gioseekable--seek"></a><h3>gio.Seekable.seek</h3><pre class="programlisting"><code class="methodsynopsis"> def <span class="methodname">seek</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>offset</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>type</code></strong></span><span class="initializer">=0</span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>cancellable</code></strong></span><span class="initializer">=None</span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><em class="parameter"><code>offset</code></em> :</span></p></td><td>the offset that is added to the position determined by the <code class="literal">type</code> parameter.
</td></tr><tr><td><p><span class="term"><em class="parameter"><code>type</code></em> :</span></p></td><td>0=current position, 1=start of the file, 2=end of the file.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>cancellable</code></em> :</span></p></td><td>a <a class="link" href="class-giocancellable.html" title="gio.Cancellable"><code class="classname">gio.Cancellable</code></a>
or <code class="literal">None</code>.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td><code class="literal">True</code> on successful seek,
<code class="literal">False</code> otherwise.
</td></tr></tbody></table><p>
Seeks in the stream by the given <code class="literal">offset</code>, modified by <code class="literal">type</code>.
</p><p>
If <code class="literal">cancellable</code> is not <code class="literal">None</code>, then the
operation can be cancelled by triggering the cancellable object from another thread.
</p></div><div class="refsect2" title="gio.Seekable.can_truncate"><a name="method-gioseekable--can_truncate"></a><h3>gio.Seekable.can_truncate</h3><pre class="programlisting"><code class="methodsynopsis"> def <span class="methodname">can_truncate</span>()</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td><code class="literal">True</code> if this
<code class="classname">gio.Seekable</code> can be truncated with
the <code class="methodname">truncate</code>() method, <code class="literal">False</code>
if not. </td></tr></tbody></table><p>
The <code class="methodname">can_truncate</code>() method checks if the
<a class="link" href="class-gioseekable.html#method-gioseekable--truncate" title="gio.Seekable.truncate"><code class="methodname">truncate</code>()</a>
can be used on this <code class="classname">gio.Seekable</code>.
</p></div><div class="refsect2" title="gio.Seekable.truncate"><a name="method-gioseekable--truncate"></a><h3>gio.Seekable.truncate</h3><pre class="programlisting"><code class="methodsynopsis"> def <span class="methodname">truncate</span>(<span class="methodparam"><span class="parameter"><strong class="parameter"><code>offset</code></strong></span></span>, <span class="methodparam"><span class="parameter"><strong class="parameter"><code>cancellable</code></strong></span><span class="initializer">=None</span></span>)</code></pre><table border="0" width="100%" bgcolor="#FFECCE"><col align="left" valign="top" width="0*"><tbody><tr><td><p><span class="term"><em class="parameter"><code>offset</code></em> :</span></p></td><td>the offset at which the stream should be truncated
</td></tr><tr><td><p><span class="term"><em class="parameter"><code>cancellable</code></em> :</span></p></td><td>a <a class="link" href="class-giocancellable.html" title="gio.Cancellable"><code class="classname">gio.Cancellable</code></a>
or <code class="literal">None</code>.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td><code class="literal">True</code> if successful,
<code class="literal">False</code> otherwise.
</td></tr></tbody></table><p>
Truncates a stream with a given <code class="literal">offset</code>.
</p><p>
If <code class="literal">cancellable</code> is not <code class="literal">None</code>, then the
operation can be cancelled by triggering the cancellable object from another thread.
</p><p>
If an operation was partially finished when the operation was cancelled the
partial result will be returned, without an error.
</p></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="class-giooutputstream.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="gio-class-reference.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="class-giosimpleasyncresult.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">gio.OutputStream </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> gio.SimpleAsyncResult</td></tr></table></div></body></html>
|