sass-site/source/documentation/Sass/Logger/LogLevel/ClassMethods.html
2018-10-22 14:13:05 -07:00

452 lines
14 KiB
HTML

<!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" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>
Module: Sass::Logger::LogLevel::ClassMethods
&mdash; Documentation by YARD 0.9.12
</title>
<link rel="stylesheet" href="../../../css/style.css" type="text/css" charset="utf-8" />
<link rel="stylesheet" href="../../../../assets/css/docs.css" type="text/css" charset="utf-8" />
<script type="text/javascript" charset="utf-8">
hasFrames = window.top.frames.main ? true : false;
relpath = '../../../';
framesUrl = "../../../frames.html#!Sass/Logger/LogLevel/ClassMethods.html";
</script>
<script type="text/javascript" charset="utf-8" src="../../../js/jquery.js"></script>
<script type="text/javascript" charset="utf-8" src="../../../js/app.js"></script>
</head>
<body>
<div id="header">
<div id="menu">
<a href="../../../_index.html">Index (C)</a> &raquo;
<span class='title'><span class='object_link'><a href="../../../Sass.html" title="Sass (module)">Sass</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../../Logger.html" title="Sass::Logger (module)">Logger</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../LogLevel.html" title="Sass::Logger::LogLevel (module)">LogLevel</a></span></span>
&raquo;
<span class="title">ClassMethods</span>
<div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
</div>
<div id="search">
<a class="full_list_link" id="class_list_link"
href="../../../class_list.html">
Class List
</a>
<a class="full_list_link" id="method_list_link"
href="../../../method_list.html">
Method List
</a>
<a class="full_list_link" id="file_list_link"
href="../../../file_list.html">
File List
</a>
</div>
<div class="clear"></div>
</div>
<iframe id="search_frame"></iframe>
<div id="content"><h1>Module: Sass::Logger::LogLevel::ClassMethods
</h1>
<dl class="box">
<dt class="r1 last">Defined in:</dt>
<dd class="r1 last">.ruby-sass/lib/sass/logger/log_level.rb</dd>
</dl>
<div class="clear"></div>
<h2>Instance Attribute Summary <small>(<a href="#" class="summary_toggle">collapse</a>)</small></h2>
<ul class="summary">
<li class="public ">
<span class="summary_signature">
<a href="#log_levels-instance_method" title="#log_levels (instance method)">#<strong>log_levels</strong> &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'></div></span>
</li>
</ul>
<h2>
Instance Method Summary
<small>(<a href="#" class="summary_toggle">collapse</a>)</small>
</h2>
<ul class="summary">
<li class="public ">
<span class="summary_signature">
<a href="#define_logger-instance_method" title="#define_logger (instance method)">#<strong>define_logger</strong>(name, options = {}) &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'></div></span>
</li>
<li class="public ">
<span class="summary_signature">
<a href="#inherited-instance_method" title="#inherited (instance method)">#<strong>inherited</strong>(subclass) &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'></div></span>
</li>
<li class="public ">
<span class="summary_signature">
<a href="#log_level-instance_method" title="#log_level (instance method)">#<strong>log_level</strong>(name, options = {}) &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'></div></span>
</li>
<li class="public ">
<span class="summary_signature">
<a href="#log_level%3F-instance_method" title="#log_level? (instance method)">#<strong>log_level?</strong>(level, min_level) &#x21d2; Boolean </a>
</span>
<span class="summary_desc"><div class='inline'></div></span>
</li>
</ul>
<div id="instance_attr_details" class="attr_details">
<h2>Instance Attribute Details</h2>
<span id="log_levels=-instance_method"></span>
<div class="method_details first">
<h3 class="signature first" id="log_levels-instance_method">
#<strong>log_levels</strong> &#x21d2; <tt>Object</tt>
</h3><table class="source_code">
<tr>
<td>
<pre class="lines">
15
16
17</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/logger/log_level.rb', line 15</span>
<span class='kw'>def</span> <span class='id identifier rubyid_log_levels'>log_levels</span>
<span class='ivar'>@log_levels</span> <span class='op'>||=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
</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="define_logger-instance_method">
#<strong>define_logger</strong>(name, options = {}) &#x21d2; <tt>Object</tt>
</h3><table class="source_code">
<tr>
<td>
<pre class="lines">
35
36
37
38
39
40
41</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/logger/log_level.rb', line 35</span>
<span class='kw'>def</span> <span class='id identifier rubyid_define_logger'>define_logger</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='comma'>,</span> <span class='id identifier rubyid_options'>options</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
<span class='id identifier rubyid_class_eval'>class_eval</span> <span class='heredoc_beg'>&lt;&lt;-RUBY</span><span class='comma'>,</span> <span class='kw'>__FILE__</span><span class='comma'>,</span> <span class='kw'>__LINE__</span> <span class='op'>+</span> <span class='int'>1</span>
<span class='tstring_content'> def </span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_name'>name</span><span class='embexpr_end'>}</span><span class='tstring_content'>(message)
</span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_options'>options</span><span class='period'>.</span><span class='id identifier rubyid_fetch'>fetch</span><span class='lparen'>(</span><span class='symbeg'>:</span><span class='id identifier rubyid_to'>to</span><span class='comma'>,</span> <span class='symbeg'>:</span><span class='id identifier rubyid_log'>log</span><span class='rparen'>)</span><span class='embexpr_end'>}</span><span class='tstring_content'>(</span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_name'>name</span><span class='period'>.</span><span class='id identifier rubyid_inspect'>inspect</span><span class='embexpr_end'>}</span><span class='tstring_content'>, message)
end
</span><span class='heredoc_end'> RUBY
</span><span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
<div class="method_details ">
<h3 class="signature " id="inherited-instance_method">
#<strong>inherited</strong>(subclass) &#x21d2; <tt>Object</tt>
</h3><table class="source_code">
<tr>
<td>
<pre class="lines">
9
10
11</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/logger/log_level.rb', line 9</span>
<span class='kw'>def</span> <span class='id identifier rubyid_inherited'>inherited</span><span class='lparen'>(</span><span class='id identifier rubyid_subclass'>subclass</span><span class='rparen'>)</span>
<span class='id identifier rubyid_subclass'>subclass</span><span class='period'>.</span><span class='id identifier rubyid_log_levels'>log_levels</span> <span class='op'>=</span> <span class='id identifier rubyid_subclass'>subclass</span><span class='period'>.</span><span class='id identifier rubyid_superclass'>superclass</span><span class='period'>.</span><span class='id identifier rubyid_log_levels'>log_levels</span><span class='period'>.</span><span class='id identifier rubyid_dup'>dup</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
<div class="method_details ">
<h3 class="signature " id="log_level-instance_method">
#<strong>log_level</strong>(name, options = {}) &#x21d2; <tt>Object</tt>
</h3><table class="source_code">
<tr>
<td>
<pre class="lines">
23
24
25
26
27
28
29
30
31
32
33</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/logger/log_level.rb', line 23</span>
<span class='kw'>def</span> <span class='id identifier rubyid_log_level'>log_level</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='comma'>,</span> <span class='id identifier rubyid_options'>options</span> <span class='op'>=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
<span class='kw'>if</span> <span class='id identifier rubyid_options'>options</span><span class='lbracket'>[</span><span class='symbol'>:prepend</span><span class='rbracket'>]</span>
<span class='id identifier rubyid_level'>level</span> <span class='op'>=</span> <span class='id identifier rubyid_log_levels'>log_levels</span><span class='period'>.</span><span class='id identifier rubyid_values'>values</span><span class='period'>.</span><span class='id identifier rubyid_min'>min</span>
<span class='id identifier rubyid_level'>level</span> <span class='op'>=</span> <span class='id identifier rubyid_level'>level</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span> <span class='op'>?</span> <span class='int'>0</span> <span class='op'>:</span> <span class='id identifier rubyid_level'>level</span> <span class='op'>-</span> <span class='int'>1</span>
<span class='kw'>else</span>
<span class='id identifier rubyid_level'>level</span> <span class='op'>=</span> <span class='id identifier rubyid_log_levels'>log_levels</span><span class='period'>.</span><span class='id identifier rubyid_values'>values</span><span class='period'>.</span><span class='id identifier rubyid_max'>max</span>
<span class='id identifier rubyid_level'>level</span> <span class='op'>=</span> <span class='id identifier rubyid_level'>level</span><span class='period'>.</span><span class='id identifier rubyid_nil?'>nil?</span> <span class='op'>?</span> <span class='int'>0</span> <span class='op'>:</span> <span class='id identifier rubyid_level'>level</span> <span class='op'>+</span> <span class='int'>1</span>
<span class='kw'>end</span>
<span class='id identifier rubyid_log_levels'>log_levels</span><span class='period'>.</span><span class='id identifier rubyid_update'>update</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span> <span class='op'>=&gt;</span> <span class='id identifier rubyid_level'>level</span><span class='rparen'>)</span>
<span class='id identifier rubyid_define_logger'>define_logger</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='rparen'>)</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
<div class="method_details ">
<h3 class="signature " id="log_level?-instance_method">
#<strong>log_level?</strong>(level, min_level) &#x21d2; <tt>Boolean</tt>
</h3><div class="docstring">
<div class="discussion">
</div>
</div>
<div class="tags">
<p class="tag_title">Returns:</p>
<ul class="return">
<li>
<span class='type'>(<tt>Boolean</tt>)</span>
</li>
</ul>
</div><table class="source_code">
<tr>
<td>
<pre class="lines">
19
20
21</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/logger/log_level.rb', line 19</span>
<span class='kw'>def</span> <span class='id identifier rubyid_log_level?'>log_level?</span><span class='lparen'>(</span><span class='id identifier rubyid_level'>level</span><span class='comma'>,</span> <span class='id identifier rubyid_min_level'>min_level</span><span class='rparen'>)</span>
<span class='id identifier rubyid_log_levels'>log_levels</span><span class='lbracket'>[</span><span class='id identifier rubyid_level'>level</span><span class='rbracket'>]</span> <span class='op'>&gt;=</span> <span class='id identifier rubyid_log_levels'>log_levels</span><span class='lbracket'>[</span><span class='id identifier rubyid_min_level'>min_level</span><span class='rbracket'>]</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
</div>
</div>
<div id="footer">
Generated on Mon Oct 22 13:20:48 2018 by
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
0.9.12 (ruby-2.5.3).
</div>
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-535380-14', 'sass-lang.com');
ga('send', 'pageview');
</script>
</body>
</html>