html/WWWJDic/Utils/Raisers.html in wwwjdic-15.0.0 vs html/WWWJDic/Utils/Raisers.html in wwwjdic-16.0.0
- old
+ new
@@ -2,33 +2,31 @@
<html>
<head>
<meta charset="UTF-8">
-<title>module WWWJDic::Utils::Raisers - wwwjdic 15.0.0</title>
+<title>module WWWJDic::Utils::Raisers - wwwjdic 16.0.0</title>
<script type="text/javascript">
var rdoc_rel_prefix = "../../";
var index_rel_prefix = "../../";
</script>
-<script defer src="../../js/navigation.js"></script>
-<script defer src="../../js/search.js"></script>
-<script defer src="../../js/search_index.js"></script>
-<script defer src="../../js/searcher.js"></script>
-<script defer src="../../js/darkfish.js"></script>
+<script src="../../js/navigation.js" defer></script>
+<script src="../../js/search.js" defer></script>
+<script src="../../js/search_index.js" defer></script>
+<script src="../../js/searcher.js" defer></script>
+<script src="../../js/darkfish.js" defer></script>
<link href="../../css/fonts.css" rel="stylesheet">
<link href="../../css/rdoc.css" rel="stylesheet">
-
-
-<body class="module" id="top" role="document">
+<body id="top" role="document" class="module">
<nav role="navigation">
<div id="project-navigation">
- <div class="nav-section" id="home-section" role="region" title="Quick navigation">
+ <div id="home-section" role="region" title="Quick navigation" class="nav-section">
<h2>
<a href="../../index.html" rel="home">Home</a>
</h2>
<div id="table-of-contents-navigation">
@@ -36,59 +34,56 @@
<a href="../../table_of_contents.html#classes">Classes</a>
<a href="../../table_of_contents.html#methods">Methods</a>
</div>
</div>
- <div class="project-section initially-hidden" id="search-section" role="search">
- <form accept-charset="utf-8" action="#" method="get">
+ <div id="search-section" role="search" class="project-section initially-hidden">
+ <form action="#" method="get" accept-charset="utf-8">
<div id="search-field-wrapper">
- <input aria-autocomplete="list" aria-controls="search-results" aria-label="Search"
- id="search-field" name="search"
- placeholder="Search" role="combobox" spellcheck="false" title="Type to search, Up and Down to navigate, Enter to load"
- type="text">
+ <input id="search-field" role="combobox" aria-label="Search"
+ aria-autocomplete="list" aria-controls="search-results"
+ type="text" name="search" placeholder="Search" spellcheck="false"
+ title="Type to search, Up and Down to navigate, Enter to load">
</div>
- <ul aria-atomic="false" aria-busy="false"
- aria-expanded="false" aria-label="Search Results"
- class="initially-hidden" id="search-results"></ul>
+ <ul id="search-results" aria-label="Search Results"
+ aria-busy="false" aria-expanded="false"
+ aria-atomic="false" class="initially-hidden"></ul>
</form>
</div>
</div>
+
-
<div id="class-metadata">
-
-
-
-
- <!-- Method Quickref -->
-<div class="nav-section" id="method-list-section">
+
+
+
+
+
+<!-- Method Quickref -->
+<div id="method-list-section" class="nav-section">
<h3>Methods</h3>
<ul class="link-list" role="directory">
-
<li ><a href="#method-i-raiser_array">#raiser_array</a>
-
<li ><a href="#method-i-raiser_downcase">#raiser_downcase</a>
-
<li ><a href="#method-i-raiser_to_i">#raiser_to_i</a>
-
</ul>
</div>
</div>
</nav>
-<main aria-labelledby="module-WWWJDic::Utils::Raisers" role="main">
- <h1 class="module" id="module-WWWJDic::Utils::Raisers">
+<main role="main" aria-labelledby="module-WWWJDic::Utils::Raisers">
+ <h1 id="module-WWWJDic::Utils::Raisers" class="module">
module WWWJDic::Utils::Raisers
</h1>
<section class="description">
-
+
<p>This module contains some utility method to raise errors according to (possibly) common conditions.</p>
<dl class="rdoc-list note-list"><dt>Author
<dd>
<p><a href="mailto:marcobresciani_1974@libero.it">Marco Bresciani</a></p>
</dd><dt>Copyright
@@ -99,140 +94,91 @@
<p>GNU General Public License version 3</p>
</dd></dl>
</section>
+ <section id="5Buntitled-5D" class="documentation-section">
- <section class="documentation-section" id="5Buntitled-5D">
-
-
-
-
-
- <section class="method-section" id="public-instance-5Buntitled-5D-method-details">
+ <section id="public-instance-5Buntitled-5D-method-details" class="method-section">
<header>
<h3>Public Instance Methods</h3>
</header>
-
- <div class="method-detail " id="method-i-raiser_array">
-
+ <div id="method-i-raiser_array" class="method-detail ">
<div class="method-heading">
<span class="method-name">raiser_array</span><span
class="method-args">(name = 'error.value', value = nil, array = nil)</span>
-
<span class="method-click-advice">click to toggle source</span>
-
</div>
-
<div class="method-description">
-
<p>Raises an <code>ArgumentError</code> according to parameters, unless the <code>array</code> contains the exact <code>value</code>.</p>
-
-
-
<div class="method-source-code" id="raiser_array-source">
<pre> <span class="ruby-comment"># File lib/wwwjdic/utils/raisers.rb</span>
<span class="line-num">49</span> <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">raiser_array</span>(<span class="ruby-identifier">name</span> = <span class="ruby-string">'error.value'</span>, <span class="ruby-identifier">value</span> = <span class="ruby-keyword">nil</span>, <span class="ruby-identifier">array</span> = <span class="ruby-keyword">nil</span>)
-<span class="line-num">50</span> <span class="ruby-keyword">unless</span> <span class="ruby-identifier">value</span>.<span class="ruby-identifier">nil?</span>
-<span class="line-num">51</span> <span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>, <span class="ruby-constant">I18n</span>.<span class="ruby-identifier">t</span>(<span class="ruby-identifier">name</span>, <span class="ruby-value">value:</span> <span class="ruby-identifier">value</span>) <span class="ruby-keyword">unless</span> <span class="ruby-identifier">array</span>.<span class="ruby-identifier">include?</span> <span class="ruby-identifier">value</span>
-<span class="line-num">52</span> <span class="ruby-keyword">end</span>
-<span class="line-num">53</span> <span class="ruby-keyword">end</span></pre>
+<span class="line-num">50</span> <span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>, <span class="ruby-constant">I18n</span>.<span class="ruby-identifier">t</span>(<span class="ruby-identifier">name</span>, <span class="ruby-value">value:</span> <span class="ruby-identifier">value</span>) <span class="ruby-keyword">if</span> <span class="ruby-operator">!</span><span class="ruby-identifier">value</span>.<span class="ruby-identifier">nil?</span> <span class="ruby-operator">&&</span> <span class="ruby-operator">!</span>(<span class="ruby-identifier">array</span>.<span class="ruby-identifier">include?</span> <span class="ruby-identifier">value</span>)
+<span class="line-num">51</span> <span class="ruby-keyword">end</span></pre>
</div>
-
</div>
-
-
</div>
-
- <div class="method-detail " id="method-i-raiser_downcase">
-
+ <div id="method-i-raiser_downcase" class="method-detail ">
<div class="method-heading">
<span class="method-name">raiser_downcase</span><span
class="method-args">(name = 'error.value', value = nil, array = nil)</span>
-
<span class="method-click-advice">click to toggle source</span>
-
</div>
-
<div class="method-description">
-
<p>Raises an <code>ArgumentError</code> according to parameters, unless the <code>array</code> contains a downcased <code>value</code>.</p>
-
-
-
<div class="method-source-code" id="raiser_downcase-source">
<pre> <span class="ruby-comment"># File lib/wwwjdic/utils/raisers.rb</span>
-<span class="line-num">57</span> <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">raiser_downcase</span>(<span class="ruby-identifier">name</span> = <span class="ruby-string">'error.value'</span>, <span class="ruby-identifier">value</span> = <span class="ruby-keyword">nil</span>, <span class="ruby-identifier">array</span> = <span class="ruby-keyword">nil</span>)
-<span class="line-num">58</span> <span class="ruby-keyword">unless</span> <span class="ruby-identifier">value</span>.<span class="ruby-identifier">nil?</span>
-<span class="line-num">59</span> <span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>, <span class="ruby-constant">I18n</span>.<span class="ruby-identifier">t</span>(<span class="ruby-identifier">name</span>, <span class="ruby-value">value:</span> <span class="ruby-identifier">value</span>) <span class="ruby-keyword">unless</span> <span class="ruby-identifier">array</span>.<span class="ruby-identifier">include?</span> <span class="ruby-identifier">value</span>.<span class="ruby-identifier">downcase</span>
-<span class="line-num">60</span> <span class="ruby-keyword">end</span>
-<span class="line-num">61</span> <span class="ruby-keyword">end</span></pre>
+<span class="line-num">55</span> <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">raiser_downcase</span>(<span class="ruby-identifier">name</span> = <span class="ruby-string">'error.value'</span>, <span class="ruby-identifier">value</span> = <span class="ruby-keyword">nil</span>, <span class="ruby-identifier">array</span> = <span class="ruby-keyword">nil</span>)
+<span class="line-num">56</span> <span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>, <span class="ruby-constant">I18n</span>.<span class="ruby-identifier">t</span>(<span class="ruby-identifier">name</span>, <span class="ruby-value">value:</span> <span class="ruby-identifier">value</span>) <span class="ruby-keyword">if</span> <span class="ruby-operator">!</span><span class="ruby-identifier">value</span>.<span class="ruby-identifier">nil?</span> <span class="ruby-operator">&&</span> <span class="ruby-operator">!</span>(<span class="ruby-identifier">array</span>.<span class="ruby-identifier">include?</span> <span class="ruby-identifier">value</span>.<span class="ruby-identifier">downcase</span>)
+<span class="line-num">57</span> <span class="ruby-keyword">end</span></pre>
</div>
-
</div>
-
-
</div>
-
- <div class="method-detail " id="method-i-raiser_to_i">
-
+ <div id="method-i-raiser_to_i" class="method-detail ">
<div class="method-heading">
<span class="method-name">raiser_to_i</span><span
class="method-args">(name = 'error.value', value = nil, array = nil)</span>
-
<span class="method-click-advice">click to toggle source</span>
-
</div>
-
<div class="method-description">
-
<p>Raises an <code>ArgumentError</code> according to parameters, unless the <code>array</code> contains the number of the <code>value</code>.</p>
-
-
-
<div class="method-source-code" id="raiser_to_i-source">
<pre> <span class="ruby-comment"># File lib/wwwjdic/utils/raisers.rb</span>
-<span class="line-num">65</span> <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">raiser_to_i</span>(<span class="ruby-identifier">name</span> = <span class="ruby-string">'error.value'</span>, <span class="ruby-identifier">value</span> = <span class="ruby-keyword">nil</span>, <span class="ruby-identifier">array</span> = <span class="ruby-keyword">nil</span>)
-<span class="line-num">66</span> <span class="ruby-keyword">unless</span> <span class="ruby-identifier">value</span>.<span class="ruby-identifier">nil?</span>
-<span class="line-num">67</span> <span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>, <span class="ruby-constant">I18n</span>.<span class="ruby-identifier">t</span>(<span class="ruby-identifier">name</span>, <span class="ruby-value">value:</span> <span class="ruby-identifier">value</span>) <span class="ruby-keyword">unless</span> <span class="ruby-identifier">array</span>.<span class="ruby-identifier">include?</span> <span class="ruby-identifier">value</span>.<span class="ruby-identifier">to_i</span>
-<span class="line-num">68</span> <span class="ruby-keyword">end</span>
-<span class="line-num">69</span> <span class="ruby-keyword">end</span></pre>
+<span class="line-num">61</span> <span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">raiser_to_i</span>(<span class="ruby-identifier">name</span> = <span class="ruby-string">'error.value'</span>, <span class="ruby-identifier">value</span> = <span class="ruby-keyword">nil</span>, <span class="ruby-identifier">array</span> = <span class="ruby-keyword">nil</span>)
+<span class="line-num">62</span> <span class="ruby-identifier">raise</span> <span class="ruby-constant">ArgumentError</span>, <span class="ruby-constant">I18n</span>.<span class="ruby-identifier">t</span>(<span class="ruby-identifier">name</span>, <span class="ruby-value">value:</span> <span class="ruby-identifier">value</span>) <span class="ruby-keyword">if</span> <span class="ruby-operator">!</span><span class="ruby-identifier">value</span>.<span class="ruby-identifier">nil?</span> <span class="ruby-operator">&&</span> <span class="ruby-operator">!</span>(<span class="ruby-identifier">array</span>.<span class="ruby-identifier">include?</span> <span class="ruby-identifier">value</span>.<span class="ruby-identifier">to_i</span>)
+<span class="line-num">63</span> <span class="ruby-keyword">end</span></pre>
</div>
-
</div>
-
-
</div>
-
</section>
</section>
-
</main>
<footer id="validator-badges" role="contentinfo">
<p><a href="https://validator.w3.org/check/referer">Validate</a>
- <p>Generated by <a href="https://ruby.github.io/rdoc/">RDoc</a> 6.2.1.
+ <p>Generated by <a href="https://ruby.github.io/rdoc/">RDoc</a> 6.3.0.
<p>Based on <a href="http://deveiate.org/projects/Darkfish-RDoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
</footer>