Skip to content

Commit

Permalink
v1.1.2
Browse files Browse the repository at this point in the history
  • Loading branch information
noraj committed Jun 10, 2021
1 parent dae4a96 commit bbd0a95
Show file tree
Hide file tree
Showing 11 changed files with 14 additions and 222 deletions.
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
haiti-hash (1.1.1)
haiti-hash (1.1.2)
docopt (~> 0.6)
paint (~> 2.2)

Expand Down
194 changes: 1 addition & 193 deletions docs/yard/HashIdentifier.html
Original file line number Diff line number Diff line change
Expand Up @@ -232,30 +232,6 @@ <h2>

<ul class="summary">

<li class="private ">
<span class="summary_signature">

<a href="#identify-instance_method" title="#identify (instance method)">#<strong>identify</strong>(hash) &#x21d2; Array&lt;Chf&gt; </a>



</span>



<span class="note title private">private</span>





<span class="summary_desc"><div class='inline'>
<p>Check which hash types are matching the provided hash.</p>
</div></span>

</li>


<li class="public ">
<span class="summary_signature">

Expand All @@ -279,30 +255,6 @@ <h2>
<p>A new instance of hash identifier.</p>
</div></span>

</li>


<li class="private ">
<span class="summary_signature">

<a href="#sort_commons-instance_method" title="#sort_commons (instance method)">#<strong>sort_commons</strong> &#x21d2; Object </a>



</span>



<span class="note title private">private</span>





<span class="summary_desc"><div class='inline'>
<p>Sort common hash types first.</p>
</div></span>

</li>


Expand Down Expand Up @@ -521,154 +473,10 @@ <h3 class="signature " id="type-instance_method">
</div>


<div id="instance_method_details" class="method_details_list">
<h2>Instance Method Details</h2>


<div class="method_details first">
<h3 class="signature first" id="identify-instance_method">

#<strong>identify</strong>(hash) &#x21d2; <tt>Array&lt;<span class='object_link'><a href="HashIdentifier/Chf.html" title="HashIdentifier::Chf (class)">Chf</a></span>&gt;</tt> <span class="extras">(private)</span>





</h3><div class="docstring">
<div class="discussion">

<p>Check which hash types are matching the provided hash</p>


</div>
</div>
<div class="tags">
<p class="tag_title">Parameters:</p>
<ul class="param">

<li>

<span class='name'>hash</span>


<span class='type'>(<tt>String</tt>)</span>



&mdash;
<div class='inline'>
<p>the hash to identify</p>
</div>

</li>

</ul>

<p class="tag_title">Returns:</p>
<ul class="return">

<li>


<span class='type'>(<tt>Array&lt;<span class='object_link'><a href="HashIdentifier/Chf.html" title="HashIdentifier::Chf (class)">Chf</a></span>&gt;</tt>)</span>



&mdash;
<div class='inline'>
<p>list of <span class='object_link'><a href="HashIdentifier/Chf.html" title="HashIdentifier::Chf (class)">Chf</a></span> objects, representing the identified hashes</p>
</div>

</li>

</ul>

</div><table class="source_code">
<tr>
<td>
<pre class="lines">


39
40
41
42
43
44
45
46
47
48
49
50</pre>
</td>
<td>
<pre class="code"><span class="info file"># File 'lib/haiti.rb', line 39</span>

<span class='kw'>def</span> <span class='id identifier rubyid_identify'>identify</span><span class='lparen'>(</span><span class='id identifier rubyid_hash'>hash</span><span class='rparen'>)</span>
<span class='id identifier rubyid_res'>res</span> <span class='op'>=</span> <span class='lbracket'>[</span><span class='rbracket'>]</span>
<span class='const'><span class='object_link'><a href="#PROTOTYPES-constant" title="HashIdentifier::PROTOTYPES (constant)">PROTOTYPES</a></span></span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_prototype'>prototype</span><span class='op'>|</span>
<span class='id identifier rubyid_reg'>reg</span> <span class='op'>=</span> <span class='const'>Regexp</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span> <span class='id identifier rubyid_prototype'>prototype</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>regex</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='const'>Regexp</span><span class='op'>::</span><span class='const'>IGNORECASE</span>
<span class='kw'>next</span> <span class='kw'>unless</span> <span class='id identifier rubyid_reg'>reg</span><span class='period'>.</span><span class='id identifier rubyid_match?'>match?</span><span class='lparen'>(</span><span class='id identifier rubyid_hash'>hash</span><span class='rparen'>)</span>

<span class='id identifier rubyid_prototype'>prototype</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>modes</span><span class='tstring_end'>&#39;</span></span><span class='rbracket'>]</span><span class='period'>.</span><span class='id identifier rubyid_each'>each</span> <span class='kw'>do</span> <span class='op'>|</span><span class='id identifier rubyid_mode'>mode</span><span class='op'>|</span>
<span class='id identifier rubyid_res'>res</span> <span class='op'>&lt;&lt;</span> <span class='const'><span class='object_link'><a href="HashIdentifier/Chf.html" title="HashIdentifier::Chf (class)">Chf</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="HashIdentifier/Chf.html#initialize-instance_method" title="HashIdentifier::Chf#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='id identifier rubyid_mode'>mode</span><span class='rparen'>)</span>
<span class='kw'>end</span>
<span class='kw'>end</span>
<span class='kw'>return</span> <span class='id identifier rubyid_res'>res</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>

<div class="method_details ">
<h3 class="signature " id="sort_commons-instance_method">

#<strong>sort_commons</strong> &#x21d2; <tt>Object</tt> <span class="extras">(private)</span>





</h3><div class="docstring">
<div class="discussion">

<p>Sort common hash types first</p>


</div>
</div>
<div class="tags">


</div><table class="source_code">
<tr>
<td>
<pre class="lines">


53
54
55</pre>
</td>
<td>
<pre class="code"><span class="info file"># File 'lib/haiti.rb', line 53</span>

<span class='kw'>def</span> <span class='id identifier rubyid_sort_commons'>sort_commons</span>
<span class='ivar'>@type</span><span class='period'>.</span><span class='id identifier rubyid_sort_by!'>sort_by!</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_e'>e</span><span class='op'>|</span> <span class='const'><span class='object_link'><a href="#COMMONS-constant" title="HashIdentifier::COMMONS (constant)">COMMONS</a></span></span><span class='period'>.</span><span class='id identifier rubyid_include?'>include?</span><span class='lparen'>(</span><span class='id identifier rubyid_e'>e</span><span class='period'>.</span><span class='id identifier rubyid_name'>name</span><span class='rparen'>)</span> <span class='op'>?</span> <span class='int'>0</span> <span class='op'>:</span> <span class='int'>1</span> <span class='rbrace'>}</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>

</div>

</div>

<div id="footer">
Generated on Tue Apr 27 10:07:42 2021 by
Generated on Thu Jun 10 10:44:31 2021 by
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
0.9.26 (ruby-3.0.1).
</div>
Expand Down
2 changes: 1 addition & 1 deletion docs/yard/HashIdentifier/Chf.html
Original file line number Diff line number Diff line change
Expand Up @@ -580,7 +580,7 @@ <h3 class="signature " id="name-instance_method">
</div>

<div id="footer">
Generated on Tue Apr 27 10:07:42 2021 by
Generated on Thu Jun 10 10:44:31 2021 by
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
0.9.26 (ruby-3.0.1).
</div>
Expand Down
4 changes: 2 additions & 2 deletions docs/yard/Version.html
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ <h2>
<dt id="VERSION-constant" class="">VERSION =

</dt>
<dd><pre class="code"><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>1.1.1</span><span class='tstring_end'>&#39;</span></span></pre></dd>
<dd><pre class="code"><span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>1.1.2</span><span class='tstring_end'>&#39;</span></span></pre></dd>

</dl>

Expand All @@ -116,7 +116,7 @@ <h2>
</div>

<div id="footer">
Generated on Tue Apr 27 10:07:42 2021 by
Generated on Thu Jun 10 10:44:31 2021 by
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
0.9.26 (ruby-3.0.1).
</div>
Expand Down
2 changes: 1 addition & 1 deletion docs/yard/_index.html
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ <h2>Namespace Listing A-Z</h2>
</div>

<div id="footer">
Generated on Tue Apr 27 10:07:42 2021 by
Generated on Thu Jun 10 10:44:31 2021 by
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
0.9.26 (ruby-3.0.1).
</div>
Expand Down
2 changes: 1 addition & 1 deletion docs/yard/file.LICENSE.html
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
<div id="content"><div id='filecontents'>The MIT License (MIT)<br/><br/>Copyright (c) 2020-2020 Alexandre ZANNI<br/>Copyright (c) 2019-2020 Alexandre ZANNI at Orange Cyberdefense<br/><br/>Permission is hereby granted, free of charge, to any person obtaining a copy<br/>of this software and associated documentation files (the &quot;Software&quot;), to deal<br/>in the Software without restriction, including without limitation the rights<br/>to use, copy, modify, merge, publish, distribute, sublicense, and/or sell<br/>copies of the Software, and to permit persons to whom the Software is<br/>furnished to do so, subject to the following conditions:<br/><br/>The above copyright notice and this permission notice shall be included in<br/>all copies or substantial portions of the Software.<br/><br/>THE SOFTWARE IS PROVIDED &quot;AS IS&quot;, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR<br/>IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,<br/>FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE<br/>AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER<br/>LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,<br/>OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN<br/>THE SOFTWARE.</div></div>

<div id="footer">
Generated on Tue Apr 27 10:07:42 2021 by
Generated on Thu Jun 10 10:44:31 2021 by
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
0.9.26 (ruby-3.0.1).
</div>
Expand Down
2 changes: 1 addition & 1 deletion docs/yard/file.README.html
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ <h2 id="author">Author</h2>
</div></div>

<div id="footer">
Generated on Tue Apr 27 10:07:42 2021 by
Generated on Thu Jun 10 10:44:31 2021 by
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
0.9.26 (ruby-3.0.1).
</div>
Expand Down
2 changes: 1 addition & 1 deletion docs/yard/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ <h2 id="author">Author</h2>
</div></div>

<div id="footer">
Generated on Tue Apr 27 10:07:42 2021 by
Generated on Thu Jun 10 10:44:31 2021 by
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
0.9.26 (ruby-3.0.1).
</div>
Expand Down
22 changes: 3 additions & 19 deletions docs/yard/method_list.html
Original file line number Diff line number Diff line change
Expand Up @@ -69,53 +69,37 @@ <h1 id="full_list_header">Method List</h1>


<li class="even ">
<div class="item">
<span class='object_link'><a href="HashIdentifier.html#identify-instance_method" title="HashIdentifier#identify (method)">#identify</a></span>
<small>HashIdentifier</small>
</div>
</li>


<li class="odd ">
<div class="item">
<span class='object_link'><a href="HashIdentifier.html#initialize-instance_method" title="HashIdentifier#initialize (method)">#initialize</a></span>
<small>HashIdentifier</small>
</div>
</li>


<li class="even ">
<li class="odd ">
<div class="item">
<span class='object_link'><a href="HashIdentifier/Chf.html#initialize-instance_method" title="HashIdentifier::Chf#initialize (method)">#initialize</a></span>
<small>HashIdentifier::Chf</small>
</div>
</li>


<li class="odd ">
<li class="even ">
<div class="item">
<span class='object_link'><a href="HashIdentifier/Chf.html#john-instance_method" title="HashIdentifier::Chf#john (method)">#john</a></span>
<small>HashIdentifier::Chf</small>
</div>
</li>


<li class="even ">
<li class="odd ">
<div class="item">
<span class='object_link'><a href="HashIdentifier/Chf.html#name-instance_method" title="HashIdentifier::Chf#name (method)">#name</a></span>
<small>HashIdentifier::Chf</small>
</div>
</li>


<li class="odd ">
<div class="item">
<span class='object_link'><a href="HashIdentifier.html#sort_commons-instance_method" title="HashIdentifier#sort_commons (method)">#sort_commons</a></span>
<small>HashIdentifier</small>
</div>
</li>


<li class="even ">
<div class="item">
<span class='object_link'><a href="HashIdentifier.html#type-instance_method" title="HashIdentifier#type (method)">#type</a></span>
Expand Down
2 changes: 1 addition & 1 deletion docs/yard/top-level-namespace.html
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ <h2>Defined Under Namespace</h2>
</div>

<div id="footer">
Generated on Tue Apr 27 10:07:42 2021 by
Generated on Thu Jun 10 10:44:31 2021 by
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
0.9.26 (ruby-3.0.1).
</div>
Expand Down
2 changes: 1 addition & 1 deletion lib/haiti/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module Version
VERSION = '1.1.1'
VERSION = '1.1.2'
end

0 comments on commit bbd0a95

Please sign in to comment.