mirror of
https://github.com/arsenetar/dupeguru.git
synced 2026-01-22 06:37:17 +00:00
Update site to include help
- Add sphinx documentation generated from build to help - Add link to help (in english) in header - Add link to github in header
This commit is contained in:
147
help/en/developer/hscommon/jobprogress/job.html
Normal file
147
help/en/developer/hscommon/jobprogress/job.html
Normal file
@@ -0,0 +1,147 @@
|
||||
|
||||
<!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" lang="en">
|
||||
<head>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>hscommon.jobprogress.job — dupeGuru 4.0.3 documentation</title>
|
||||
<link rel="stylesheet" href="../../../_static/haiku.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
<script type="text/javascript" src="../../../_static/documentation_options.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/translations.js"></script>
|
||||
<link rel="index" title="Index" href="../../../genindex.html" />
|
||||
<link rel="search" title="Search" href="../../../search.html" />
|
||||
<link rel="next" title="hscommon.jobprogress.performer" href="performer.html" />
|
||||
<link rel="prev" title="hscommon.util" href="../util.html" />
|
||||
</head><body>
|
||||
<div class="header" role="banner"><h1 class="heading"><a href="../../../index.html">
|
||||
<span>dupeGuru 4.0.3 documentation</span></a></h1>
|
||||
<h2 class="heading"><span>hscommon.jobprogress.job</span></h2>
|
||||
</div>
|
||||
<div class="topnav" role="navigation" aria-label="top navigation">
|
||||
|
||||
<p>
|
||||
«  <a href="../util.html">hscommon.util</a>
|
||||
  ::  
|
||||
<a class="uplink" href="../../../index.html">Contents</a>
|
||||
  ::  
|
||||
<a href="performer.html">hscommon.jobprogress.performer</a>  »
|
||||
</p>
|
||||
|
||||
</div>
|
||||
<div class="content">
|
||||
|
||||
|
||||
<div class="section" id="module-hscommon.jobprogress.job">
|
||||
<span id="hscommon-jobprogress-job"></span><h1>hscommon.jobprogress.job<a class="headerlink" href="#module-hscommon.jobprogress.job" title="Permalink to this headline">¶</a></h1>
|
||||
<table border="1" class="longtable docutils">
|
||||
<colgroup>
|
||||
<col width="10%" />
|
||||
<col width="90%" />
|
||||
</colgroup>
|
||||
<tbody valign="top">
|
||||
<tr class="row-odd"><td><a class="reference internal" href="#hscommon.jobprogress.job.Job" title="hscommon.jobprogress.job.Job"><code class="xref py py-obj docutils literal notranslate"><span class="pre">Job</span></code></a>(job_proportions, callback)</td>
|
||||
<td>Manages a job’s progression and return it’s progression through a callback.</td>
|
||||
</tr>
|
||||
<tr class="row-even"><td><a class="reference internal" href="#hscommon.jobprogress.job.NullJob" title="hscommon.jobprogress.job.NullJob"><code class="xref py py-obj docutils literal notranslate"><span class="pre">NullJob</span></code></a>(*args, **kwargs)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<dl class="class">
|
||||
<dt id="hscommon.jobprogress.job.Job">
|
||||
<em class="property">class </em><code class="descclassname">hscommon.jobprogress.job.</code><code class="descname">Job</code><span class="sig-paren">(</span><em>job_proportions</em>, <em>callback</em><span class="sig-paren">)</span><a class="headerlink" href="#hscommon.jobprogress.job.Job" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Manages a job’s progression and return it’s progression through a callback.</p>
|
||||
<p>Note that this class is not foolproof. For example, you could call
|
||||
start_subjob, and then call add_progress from the parent job, and nothing
|
||||
would stop you from doing it. However, it would mess your progression
|
||||
because it is the sub job that is supposed to drive the progression.
|
||||
Another example would be to start a subjob, then start another, and call
|
||||
add_progress from the old subjob. Once again, it would mess your progression.
|
||||
There are no stops because it would remove the lightweight aspect of the
|
||||
class (A Job would need to have a Parent instead of just a callback,
|
||||
and the parent could be None. A lot of checks for nothing.).
|
||||
Another one is that nothing stops you from calling add_progress right after
|
||||
SkipJob.</p>
|
||||
<dl class="method">
|
||||
<dt id="hscommon.jobprogress.job.Job._do_update">
|
||||
<code class="descname">_do_update</code><span class="sig-paren">(</span><em>desc</em><span class="sig-paren">)</span><a class="headerlink" href="#hscommon.jobprogress.job.Job._do_update" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Calls the callback function with a % progress as a parameter.</p>
|
||||
<p>The parameter is a int in the 0-100 range.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="hscommon.jobprogress.job.Job._subjob_callback">
|
||||
<code class="descname">_subjob_callback</code><span class="sig-paren">(</span><em>progress</em>, <em>desc=''</em><span class="sig-paren">)</span><a class="headerlink" href="#hscommon.jobprogress.job.Job._subjob_callback" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>This is the callback passed to children jobs.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="hscommon.jobprogress.job.Job.iter_with_progress">
|
||||
<code class="descname">iter_with_progress</code><span class="sig-paren">(</span><em>iterable</em>, <em>desc_format=None</em>, <em>every=1</em>, <em>count=None</em><span class="sig-paren">)</span><a class="headerlink" href="#hscommon.jobprogress.job.Job.iter_with_progress" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Iterate through <code class="docutils literal notranslate"><span class="pre">iterable</span></code> while automatically adding progress.</p>
|
||||
<p>WARNING: We need our iterable’s length. If <code class="docutils literal notranslate"><span class="pre">iterable</span></code> is not a sequence (that is,
|
||||
something we can call <code class="docutils literal notranslate"><span class="pre">len()</span></code> on), you <em>have</em> to specify a count through the <code class="docutils literal notranslate"><span class="pre">count</span></code>
|
||||
argument. If <code class="docutils literal notranslate"><span class="pre">count</span></code> is <code class="docutils literal notranslate"><span class="pre">None</span></code>, <code class="docutils literal notranslate"><span class="pre">len(iterable)</span></code> is used.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="hscommon.jobprogress.job.Job.set_progress">
|
||||
<code class="descname">set_progress</code><span class="sig-paren">(</span><em>progress</em>, <em>desc=''</em><span class="sig-paren">)</span><a class="headerlink" href="#hscommon.jobprogress.job.Job.set_progress" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Sets the progress of the current job to ‘progress’, and call the
|
||||
callback</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="hscommon.jobprogress.job.Job.start_job">
|
||||
<code class="descname">start_job</code><span class="sig-paren">(</span><em>max_progress=100</em>, <em>desc=''</em><span class="sig-paren">)</span><a class="headerlink" href="#hscommon.jobprogress.job.Job.start_job" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Begin work on the next job. You must not call start_job more than
|
||||
‘jobcount’ (in __init__) times.
|
||||
‘max’ is the job units you are to perform.
|
||||
‘desc’ is the description of the job.</p>
|
||||
</dd></dl>
|
||||
|
||||
<dl class="method">
|
||||
<dt id="hscommon.jobprogress.job.Job.start_subjob">
|
||||
<code class="descname">start_subjob</code><span class="sig-paren">(</span><em>job_proportions</em>, <em>desc=''</em><span class="sig-paren">)</span><a class="headerlink" href="#hscommon.jobprogress.job.Job.start_subjob" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Starts a sub job. Use this when you want to split a job into
|
||||
multiple smaller jobs. Pretty handy when starting a process where you
|
||||
know how many subjobs you will have, but don’t know the work unit count
|
||||
for every of them.
|
||||
returns the Job object</p>
|
||||
</dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
||||
<dl class="class">
|
||||
<dt id="hscommon.jobprogress.job.NullJob">
|
||||
<em class="property">class </em><code class="descclassname">hscommon.jobprogress.job.</code><code class="descname">NullJob</code><span class="sig-paren">(</span><em>*args</em>, <em>**kwargs</em><span class="sig-paren">)</span><a class="headerlink" href="#hscommon.jobprogress.job.NullJob" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
<div class="bottomnav" role="navigation" aria-label="bottom navigation">
|
||||
|
||||
<p>
|
||||
«  <a href="../util.html">hscommon.util</a>
|
||||
  ::  
|
||||
<a class="uplink" href="../../../index.html">Contents</a>
|
||||
  ::  
|
||||
<a href="performer.html">hscommon.jobprogress.performer</a>  »
|
||||
</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="footer" role="contentinfo">
|
||||
© Copyright 2016, Hardcoded Software.
|
||||
Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.7.1.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
92
help/en/developer/hscommon/jobprogress/performer.html
Normal file
92
help/en/developer/hscommon/jobprogress/performer.html
Normal file
@@ -0,0 +1,92 @@
|
||||
|
||||
<!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" lang="en">
|
||||
<head>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>hscommon.jobprogress.performer — dupeGuru 4.0.3 documentation</title>
|
||||
<link rel="stylesheet" href="../../../_static/haiku.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
<script type="text/javascript" src="../../../_static/documentation_options.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/translations.js"></script>
|
||||
<link rel="index" title="Index" href="../../../genindex.html" />
|
||||
<link rel="search" title="Search" href="../../../search.html" />
|
||||
<link rel="next" title="hscommon.jobprogress.qt" href="qt.html" />
|
||||
<link rel="prev" title="hscommon.jobprogress.job" href="job.html" />
|
||||
</head><body>
|
||||
<div class="header" role="banner"><h1 class="heading"><a href="../../../index.html">
|
||||
<span>dupeGuru 4.0.3 documentation</span></a></h1>
|
||||
<h2 class="heading"><span>hscommon.jobprogress.performer</span></h2>
|
||||
</div>
|
||||
<div class="topnav" role="navigation" aria-label="top navigation">
|
||||
|
||||
<p>
|
||||
«  <a href="job.html">hscommon.jobprogress.job</a>
|
||||
  ::  
|
||||
<a class="uplink" href="../../../index.html">Contents</a>
|
||||
  ::  
|
||||
<a href="qt.html">hscommon.jobprogress.qt</a>  »
|
||||
</p>
|
||||
|
||||
</div>
|
||||
<div class="content">
|
||||
|
||||
|
||||
<div class="section" id="module-hscommon.jobprogress.performer">
|
||||
<span id="hscommon-jobprogress-performer"></span><h1>hscommon.jobprogress.performer<a class="headerlink" href="#module-hscommon.jobprogress.performer" title="Permalink to this headline">¶</a></h1>
|
||||
<table border="1" class="longtable docutils">
|
||||
<colgroup>
|
||||
<col width="10%" />
|
||||
<col width="90%" />
|
||||
</colgroup>
|
||||
<tbody valign="top">
|
||||
<tr class="row-odd"><td><a class="reference internal" href="#hscommon.jobprogress.performer.ThreadedJobPerformer" title="hscommon.jobprogress.performer.ThreadedJobPerformer"><code class="xref py py-obj docutils literal notranslate"><span class="pre">ThreadedJobPerformer</span></code></a></td>
|
||||
<td>Run threaded jobs and track progress.</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<dl class="class">
|
||||
<dt id="hscommon.jobprogress.performer.ThreadedJobPerformer">
|
||||
<em class="property">class </em><code class="descclassname">hscommon.jobprogress.performer.</code><code class="descname">ThreadedJobPerformer</code><a class="headerlink" href="#hscommon.jobprogress.performer.ThreadedJobPerformer" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Run threaded jobs and track progress.</p>
|
||||
<p>To run a threaded job, first create a job with _create_job(), then call _run_threaded(), with
|
||||
your work function as a parameter.</p>
|
||||
<p>Example:</p>
|
||||
<p>j = self._create_job()
|
||||
self._run_threaded(self.some_work_func, (arg1, arg2, j))</p>
|
||||
<dl class="method">
|
||||
<dt id="hscommon.jobprogress.performer.ThreadedJobPerformer.reraise_if_error">
|
||||
<code class="descname">reraise_if_error</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#hscommon.jobprogress.performer.ThreadedJobPerformer.reraise_if_error" title="Permalink to this definition">¶</a></dt>
|
||||
<dd><p>Reraises the error that happened in the thread if any.</p>
|
||||
<p>Call this after the caller of run_threaded detected that self._job_running returned to False</p>
|
||||
</dd></dl>
|
||||
|
||||
</dd></dl>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
<div class="bottomnav" role="navigation" aria-label="bottom navigation">
|
||||
|
||||
<p>
|
||||
«  <a href="job.html">hscommon.jobprogress.job</a>
|
||||
  ::  
|
||||
<a class="uplink" href="../../../index.html">Contents</a>
|
||||
  ::  
|
||||
<a href="qt.html">hscommon.jobprogress.qt</a>  »
|
||||
</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="footer" role="contentinfo">
|
||||
© Copyright 2016, Hardcoded Software.
|
||||
Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.7.1.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
79
help/en/developer/hscommon/jobprogress/qt.html
Normal file
79
help/en/developer/hscommon/jobprogress/qt.html
Normal file
@@ -0,0 +1,79 @@
|
||||
|
||||
<!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" lang="en">
|
||||
<head>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>hscommon.jobprogress.qt — dupeGuru 4.0.3 documentation</title>
|
||||
<link rel="stylesheet" href="../../../_static/haiku.css" type="text/css" />
|
||||
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
|
||||
<script type="text/javascript" src="../../../_static/documentation_options.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/jquery.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/underscore.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/doctools.js"></script>
|
||||
<script type="text/javascript" src="../../../_static/translations.js"></script>
|
||||
<link rel="index" title="Index" href="../../../genindex.html" />
|
||||
<link rel="search" title="Search" href="../../../search.html" />
|
||||
<link rel="next" title="hscommon.gui.base" href="../gui/base.html" />
|
||||
<link rel="prev" title="hscommon.jobprogress.performer" href="performer.html" />
|
||||
</head><body>
|
||||
<div class="header" role="banner"><h1 class="heading"><a href="../../../index.html">
|
||||
<span>dupeGuru 4.0.3 documentation</span></a></h1>
|
||||
<h2 class="heading"><span>hscommon.jobprogress.qt</span></h2>
|
||||
</div>
|
||||
<div class="topnav" role="navigation" aria-label="top navigation">
|
||||
|
||||
<p>
|
||||
«  <a href="performer.html">hscommon.jobprogress.performer</a>
|
||||
  ::  
|
||||
<a class="uplink" href="../../../index.html">Contents</a>
|
||||
  ::  
|
||||
<a href="../gui/base.html">hscommon.gui.base</a>  »
|
||||
</p>
|
||||
|
||||
</div>
|
||||
<div class="content">
|
||||
|
||||
|
||||
<div class="section" id="module-hscommon.jobprogress.qt">
|
||||
<span id="hscommon-jobprogress-qt"></span><h1>hscommon.jobprogress.qt<a class="headerlink" href="#module-hscommon.jobprogress.qt" title="Permalink to this headline">¶</a></h1>
|
||||
<table border="1" class="longtable docutils">
|
||||
<colgroup>
|
||||
<col width="10%" />
|
||||
<col width="90%" />
|
||||
</colgroup>
|
||||
<tbody valign="top">
|
||||
<tr class="row-odd"><td><a class="reference internal" href="#hscommon.jobprogress.qt.Progress" title="hscommon.jobprogress.qt.Progress"><code class="xref py py-obj docutils literal notranslate"><span class="pre">Progress</span></code></a>(parent)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<dl class="class">
|
||||
<dt id="hscommon.jobprogress.qt.Progress">
|
||||
<em class="property">class </em><code class="descclassname">hscommon.jobprogress.qt.</code><code class="descname">Progress</code><span class="sig-paren">(</span><em>parent</em><span class="sig-paren">)</span><a class="headerlink" href="#hscommon.jobprogress.qt.Progress" title="Permalink to this definition">¶</a></dt>
|
||||
<dd></dd></dl>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
<div class="bottomnav" role="navigation" aria-label="bottom navigation">
|
||||
|
||||
<p>
|
||||
«  <a href="performer.html">hscommon.jobprogress.performer</a>
|
||||
  ::  
|
||||
<a class="uplink" href="../../../index.html">Contents</a>
|
||||
  ::  
|
||||
<a href="../gui/base.html">hscommon.gui.base</a>  »
|
||||
</p>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="footer" role="contentinfo">
|
||||
© Copyright 2016, Hardcoded Software.
|
||||
Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.7.1.
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user