Skip to content

Commit

Permalink
Refactor: Make removeOldFiles method public
Browse files Browse the repository at this point in the history
  • Loading branch information
jy95 committed Sep 2, 2017
1 parent ffdf72a commit 8887d71
Show file tree
Hide file tree
Showing 7 changed files with 414 additions and 158 deletions.
207 changes: 191 additions & 16 deletions docs/TorrentLibrary.html
Expand Up @@ -24,7 +24,7 @@
<label for="nav-trigger" class="overlay"></label>

<nav>
<li class="nav-link nav-home-link"><a href="index.html">Home</a></li><li class="nav-heading">Classes</li><li class="nav-heading"><span class="nav-item-type type-class">C</span><span class="nav-item-name"><a href="TorrentLibrary.html">TorrentLibrary</a></span></li><li class="nav-item"><span class="nav-item-type type-function">F</span><span class="nav-item-name"><a href="TorrentLibrary.html#.listVideosExtension">listVideosExtension</a></span></li><li class="nav-item"><span class="nav-item-type type-function">F</span><span class="nav-item-name"><a href="TorrentLibrary.html#addNewPath">addNewPath</a></span></li><li class="nav-item"><span class="nav-item-type type-function">F</span><span class="nav-item-name"><a href="TorrentLibrary.html#hasPathsProvidedByUser">hasPathsProvidedByUser</a></span></li><li class="nav-item"><span class="nav-item-type type-function">F</span><span class="nav-item-name"><a href="TorrentLibrary.html#scan">scan</a></span></li><li class="nav-heading">Externals</li><li class="nav-heading"><span class="nav-item-type type-external">E</span><span class="nav-item-name"><a href="external-nameParser.html">nameParser</a></span></li><li class="nav-heading"><span class="nav-item-type type-external">E</span><span class="nav-item-name"><a href="external-Promise.html">Promise</a></span></li><li class="nav-heading"><a href="global.html">Globals</a></li>
<li class="nav-link nav-home-link"><a href="index.html">Home</a></li><li class="nav-heading">Classes</li><li class="nav-heading"><span class="nav-item-type type-class">C</span><span class="nav-item-name"><a href="TorrentLibrary.html">TorrentLibrary</a></span></li><li class="nav-item"><span class="nav-item-type type-function">F</span><span class="nav-item-name"><a href="TorrentLibrary.html#.listVideosExtension">listVideosExtension</a></span></li><li class="nav-item"><span class="nav-item-type type-function">F</span><span class="nav-item-name"><a href="TorrentLibrary.html#addNewPath">addNewPath</a></span></li><li class="nav-item"><span class="nav-item-type type-function">F</span><span class="nav-item-name"><a href="TorrentLibrary.html#hasPathsProvidedByUser">hasPathsProvidedByUser</a></span></li><li class="nav-item"><span class="nav-item-type type-function">F</span><span class="nav-item-name"><a href="TorrentLibrary.html#removeOldFiles">removeOldFiles</a></span></li><li class="nav-item"><span class="nav-item-type type-function">F</span><span class="nav-item-name"><a href="TorrentLibrary.html#scan">scan</a></span></li><li class="nav-heading">Externals</li><li class="nav-heading"><span class="nav-item-type type-external">E</span><span class="nav-item-name"><a href="external-nameParser.html">nameParser</a></span></li><li class="nav-heading"><span class="nav-item-type type-external">E</span><span class="nav-item-name"><a href="external-Promise.html">Promise</a></span></li><li class="nav-heading"><a href="global.html">Globals</a></li>
</nav>

<div id="main">
Expand Down Expand Up @@ -103,7 +103,7 @@ <h4 class="name" id="TorrentLibrary"><span class="type-signature"></span>new Tor

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line156">line 156</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line157">line 157</a>
</li></ul></dd>


Expand Down Expand Up @@ -219,7 +219,7 @@ <h4 class="name" id=".MOVIES_TYPE"><span class="type-signature">(static) </span>

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line164">line 164</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line165">line 165</a>
</li></ul></dd>


Expand Down Expand Up @@ -286,7 +286,7 @@ <h4 class="name" id=".TV_SERIES_TYPE"><span class="type-signature">(static) </sp

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line175">line 175</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line176">line 176</a>
</li></ul></dd>


Expand Down Expand Up @@ -353,7 +353,7 @@ <h4 class="name" id="allFilesWithCategory"><span class="type-signature"></span>a

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line447">line 447</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line521">line 521</a>
</li></ul></dd>


Expand Down Expand Up @@ -435,7 +435,7 @@ <h4 class="name" id="allMovies"><span class="type-signature"></span>allMovies<sp

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line397">line 397</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line471">line 471</a>
</li></ul></dd>


Expand Down Expand Up @@ -530,7 +530,7 @@ <h4 class="name" id="allTvSeries"><span class="type-signature"></span>allTvSerie

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line434">line 434</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line508">line 508</a>
</li></ul></dd>


Expand Down Expand Up @@ -633,7 +633,7 @@ <h4 class="name" id="categoryForFile"><span class="type-signature"></span>catego

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line213">line 213</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line214">line 214</a>
</li></ul></dd>


Expand Down Expand Up @@ -717,7 +717,7 @@ <h4 class="name" id="defaultPath"><span class="type-signature"></span>defaultPat

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line189">line 189</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line190">line 190</a>
</li></ul></dd>


Expand Down Expand Up @@ -796,7 +796,7 @@ <h4 class="name" id="paths"><span class="type-signature"></span>paths<span class

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line198">line 198</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line199">line 199</a>
</li></ul></dd>


Expand Down Expand Up @@ -876,7 +876,7 @@ <h4 class="name" id="stores"><span class="type-signature"></span>stores<span cla

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line203">line 203</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line204">line 204</a>
</li></ul></dd>


Expand Down Expand Up @@ -963,7 +963,7 @@ <h4 class="name" id=".listVideosExtension"><span class="type-signature">(static)

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line300">line 300</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line311">line 311</a>
</li></ul></dd>


Expand Down Expand Up @@ -1082,7 +1082,7 @@ <h4 class="name" id="addNewPath"><span class="type-signature"></span>addNewPath<

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line318">line 318</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line329">line 329</a>
</li></ul></dd>


Expand Down Expand Up @@ -1267,7 +1267,7 @@ <h4 class="name" id="hasPathsProvidedByUser"><span class="type-signature"></span

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line343">line 343</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line354">line 354</a>
</li></ul></dd>


Expand Down Expand Up @@ -1325,6 +1325,181 @@ <h5>Returns:</h5>



</div>


<div class="section-method">



<h4 class="name" id="removeOldFiles"><span class="type-signature"></span>removeOldFiles<span class="signature">(&hellip;files)</span><span class="type-signature"> &rarr; {<a href="external-Promise.html">external:Promise</a>}</span></h4>





<div class="description">
<p>Removes files stored in this library</p>
</div>





<dl class="details">




<dt class="tag-since">Since:</dt>
<dd class="tag-since"><ul class="dummy"><li>1.0.3</li></ul></dd>























<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line391">line 391</a>
</li></ul></dd>







</dl>









<h5>Parameters:</h5>


<table class="params">
<thead>
<tr>

<th>Name</th>


<th>Type</th>


<th>Attributes</th>




<th class="last">Description</th>
</tr>
</thead>

<tbody>


<tr>

<td class="name"><code>files</code></td>


<td class="type">


<span class="param-type"><code>string</code></span>



</td>


<td class="attributes">





&lt;repeatable><br>

</td>




<td class="description last">
<p>An array of filePath (for example the keys of allFilesWithCategory())</p>

</td>
</tr>


</tbody>
</table>














<div class="section-returns">
<h5>Returns:</h5>



<dl class="param-type">
<dt>
Type:
</dt>
<dd>

<span class="param-type"><code><a href="external-Promise.html">external:Promise</a></code></span>


</dd>
</dl>


<div class="param-desc">
<p>an resolved or reject promise</p>
</div>


</div>



</div>


Expand Down Expand Up @@ -1378,7 +1553,7 @@ <h4 class="name" id="scan"><span class="type-signature"></span>scan<span class="

<dt class="tag-source">Source:</dt>
<dd class="tag-source"><ul class="dummy"><li>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line356">line 356</a>
<a href="TorrentLibrary.js.html">TorrentLibrary.js</a>, <a href="TorrentLibrary.js.html#line367">line 367</a>
</li></ul></dd>


Expand Down Expand Up @@ -1456,7 +1631,7 @@ <h5>Returns:</h5>
<br class="clear">

<footer>
Generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.5.4</a> on Thu Aug 31 2017 23:05:28 GMT+0200 (Romance Daylight Time) using the Minami theme.
Generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.5.4</a> on Sat Sep 02 2017 02:08:22 GMT+0200 (Romance Daylight Time) using the Minami theme.
</footer>

<script>prettyPrint();</script>
Expand Down

0 comments on commit 8887d71

Please sign in to comment.