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

890 lines
16 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>
Class: Sass::Callable
&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/Callable.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">Callable</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>Class: Sass::Callable
</h1>
<dl class="box">
<dt class="r1">Inherits:</dt>
<dd class="r1">
<span class="inheritName">Struct</span>
<ul class="fullTree">
<li>Object</li>
<li class="next">Struct</li>
<li class="next">Sass::Callable</li>
</ul>
<a href="#" class="inheritanceTree">show all</a>
</dd>
<dt class="r2 last">Defined in:</dt>
<dd class="r2 last">.ruby-sass/lib/sass/engine.rb</dd>
</dl>
<div class="clear"></div>
<h2>Overview</h2><div class="docstring">
<div class="discussion">
<p>A Sass mixin or function.</p>
<p>`name`: `String` : The name of the mixin/function.</p>
<p>`args`: `Array&lt;(Script::Tree::Node, Script::Tree::Node)&gt;` : The
arguments for the mixin/function.</p>
<pre class="code ruby"><code class="ruby">Each element is a tuple containing the variable node of the argument
and the parse tree for the default value of the argument.
</code></pre>
<p>`splat`: `Script::Tree::Node?` : The variable node of the splat argument
for this callable, or null.</p>
<p>`environment`: <span class='object_link'><a href="Environment.html" title="Sass::Environment (class)">Environment</a></span> : The environment in which the
mixin/function was defined.</p>
<pre class="code ruby"><code class="ruby">This is captured so that the mixin/function can have access
to local variables defined in its scope.
</code></pre>
<p>`tree`: `Array&lt;Tree::Node&gt;` : The parse tree for the mixin/function.</p>
<p>`has_content`: `Boolean` : Whether the callable accepts a content block.</p>
<p>`type`: `String` : The user-friendly name of the type of the callable.</p>
<p>`origin`: `Symbol` : From whence comes the callable: `:stylesheet`,
`:builtin`, `:css`</p>
<pre class="code ruby"><code class="ruby">A callable with an origin of `:stylesheet` was defined in the stylesheet itself.
A callable with an origin of `:builtin` was defined in ruby.
A callable (function) with an origin of `:css` returns a function call with arguments to CSS.
</code></pre>
</div>
</div>
<div class="tags">
</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="#args-instance_method" title="#args (instance method)">#<strong>args</strong> &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'>
<p>Returns the value of attribute args.</p>
</div></span>
</li>
<li class="public ">
<span class="summary_signature">
<a href="#environment-instance_method" title="#environment (instance method)">#<strong>environment</strong> &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'>
<p>Returns the value of attribute environment.</p>
</div></span>
</li>
<li class="public ">
<span class="summary_signature">
<a href="#has_content-instance_method" title="#has_content (instance method)">#<strong>has_content</strong> &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'>
<p>Returns the value of attribute has_content.</p>
</div></span>
</li>
<li class="public ">
<span class="summary_signature">
<a href="#name-instance_method" title="#name (instance method)">#<strong>name</strong> &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'>
<p>Returns the value of attribute name.</p>
</div></span>
</li>
<li class="public ">
<span class="summary_signature">
<a href="#origin-instance_method" title="#origin (instance method)">#<strong>origin</strong> &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'>
<p>Returns the value of attribute origin.</p>
</div></span>
</li>
<li class="public ">
<span class="summary_signature">
<a href="#splat-instance_method" title="#splat (instance method)">#<strong>splat</strong> &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'>
<p>Returns the value of attribute splat.</p>
</div></span>
</li>
<li class="public ">
<span class="summary_signature">
<a href="#tree-instance_method" title="#tree (instance method)">#<strong>tree</strong> &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'>
<p>Returns the value of attribute tree.</p>
</div></span>
</li>
<li class="public ">
<span class="summary_signature">
<a href="#type-instance_method" title="#type (instance method)">#<strong>type</strong> &#x21d2; Object </a>
</span>
<span class="summary_desc"><div class='inline'>
<p>Returns the value of attribute type.</p>
</div></span>
</li>
</ul>
<div id="instance_attr_details" class="attr_details">
<h2>Instance Attribute Details</h2>
<span id="args=-instance_method"></span>
<div class="method_details first">
<h3 class="signature first" id="args-instance_method">
#<strong>args</strong> &#x21d2; <tt>Object</tt>
</h3><div class="docstring">
<div class="discussion">
<p>Returns the value of attribute args</p>
</div>
</div>
<div class="tags">
<p class="tag_title">Returns:</p>
<ul class="return">
<li>
<span class='type'>(<tt>Object</tt>)</span>
&mdash;
<div class='inline'>
<p>the current value of args</p>
</div>
</li>
</ul>
</div><table class="source_code">
<tr>
<td>
<pre class="lines">
89
90
91</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/engine.rb', line 89</span>
<span class='kw'>def</span> <span class='id identifier rubyid_args'>args</span>
<span class='ivar'>@args</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
<span id="environment=-instance_method"></span>
<div class="method_details ">
<h3 class="signature " id="environment-instance_method">
#<strong>environment</strong> &#x21d2; <tt>Object</tt>
</h3><div class="docstring">
<div class="discussion">
<p>Returns the value of attribute environment</p>
</div>
</div>
<div class="tags">
<p class="tag_title">Returns:</p>
<ul class="return">
<li>
<span class='type'>(<tt>Object</tt>)</span>
&mdash;
<div class='inline'>
<p>the current value of environment</p>
</div>
</li>
</ul>
</div><table class="source_code">
<tr>
<td>
<pre class="lines">
89
90
91</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/engine.rb', line 89</span>
<span class='kw'>def</span> <span class='id identifier rubyid_environment'>environment</span>
<span class='ivar'>@environment</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
<span id="has_content=-instance_method"></span>
<div class="method_details ">
<h3 class="signature " id="has_content-instance_method">
#<strong>has_content</strong> &#x21d2; <tt>Object</tt>
</h3><div class="docstring">
<div class="discussion">
<p>Returns the value of attribute has_content</p>
</div>
</div>
<div class="tags">
<p class="tag_title">Returns:</p>
<ul class="return">
<li>
<span class='type'>(<tt>Object</tt>)</span>
&mdash;
<div class='inline'>
<p>the current value of has_content</p>
</div>
</li>
</ul>
</div><table class="source_code">
<tr>
<td>
<pre class="lines">
89
90
91</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/engine.rb', line 89</span>
<span class='kw'>def</span> <span class='id identifier rubyid_has_content'>has_content</span>
<span class='ivar'>@has_content</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
<span id="name=-instance_method"></span>
<div class="method_details ">
<h3 class="signature " id="name-instance_method">
#<strong>name</strong> &#x21d2; <tt>Object</tt>
</h3><div class="docstring">
<div class="discussion">
<p>Returns the value of attribute name</p>
</div>
</div>
<div class="tags">
<p class="tag_title">Returns:</p>
<ul class="return">
<li>
<span class='type'>(<tt>Object</tt>)</span>
&mdash;
<div class='inline'>
<p>the current value of name</p>
</div>
</li>
</ul>
</div><table class="source_code">
<tr>
<td>
<pre class="lines">
89
90
91</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/engine.rb', line 89</span>
<span class='kw'>def</span> <span class='id identifier rubyid_name'>name</span>
<span class='ivar'>@name</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
<span id="origin=-instance_method"></span>
<div class="method_details ">
<h3 class="signature " id="origin-instance_method">
#<strong>origin</strong> &#x21d2; <tt>Object</tt>
</h3><div class="docstring">
<div class="discussion">
<p>Returns the value of attribute origin</p>
</div>
</div>
<div class="tags">
<p class="tag_title">Returns:</p>
<ul class="return">
<li>
<span class='type'>(<tt>Object</tt>)</span>
&mdash;
<div class='inline'>
<p>the current value of origin</p>
</div>
</li>
</ul>
</div><table class="source_code">
<tr>
<td>
<pre class="lines">
89
90
91</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/engine.rb', line 89</span>
<span class='kw'>def</span> <span class='id identifier rubyid_origin'>origin</span>
<span class='ivar'>@origin</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
<span id="splat=-instance_method"></span>
<div class="method_details ">
<h3 class="signature " id="splat-instance_method">
#<strong>splat</strong> &#x21d2; <tt>Object</tt>
</h3><div class="docstring">
<div class="discussion">
<p>Returns the value of attribute splat</p>
</div>
</div>
<div class="tags">
<p class="tag_title">Returns:</p>
<ul class="return">
<li>
<span class='type'>(<tt>Object</tt>)</span>
&mdash;
<div class='inline'>
<p>the current value of splat</p>
</div>
</li>
</ul>
</div><table class="source_code">
<tr>
<td>
<pre class="lines">
89
90
91</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/engine.rb', line 89</span>
<span class='kw'>def</span> <span class='id identifier rubyid_splat'>splat</span>
<span class='ivar'>@splat</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
<span id="tree=-instance_method"></span>
<div class="method_details ">
<h3 class="signature " id="tree-instance_method">
#<strong>tree</strong> &#x21d2; <tt>Object</tt>
</h3><div class="docstring">
<div class="discussion">
<p>Returns the value of attribute tree</p>
</div>
</div>
<div class="tags">
<p class="tag_title">Returns:</p>
<ul class="return">
<li>
<span class='type'>(<tt>Object</tt>)</span>
&mdash;
<div class='inline'>
<p>the current value of tree</p>
</div>
</li>
</ul>
</div><table class="source_code">
<tr>
<td>
<pre class="lines">
89
90
91</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/engine.rb', line 89</span>
<span class='kw'>def</span> <span class='id identifier rubyid_tree'>tree</span>
<span class='ivar'>@tree</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
<span id="type=-instance_method"></span>
<div class="method_details ">
<h3 class="signature " id="type-instance_method">
#<strong>type</strong> &#x21d2; <tt>Object</tt>
</h3><div class="docstring">
<div class="discussion">
<p>Returns the value of attribute type</p>
</div>
</div>
<div class="tags">
<p class="tag_title">Returns:</p>
<ul class="return">
<li>
<span class='type'>(<tt>Object</tt>)</span>
&mdash;
<div class='inline'>
<p>the current value of type</p>
</div>
</li>
</ul>
</div><table class="source_code">
<tr>
<td>
<pre class="lines">
89
90
91</pre>
</td>
<td>
<pre class="code"><span class="info file"># File '.ruby-sass/lib/sass/engine.rb', line 89</span>
<span class='kw'>def</span> <span class='id identifier rubyid_type'>type</span>
<span class='ivar'>@type</span>
<span class='kw'>end</span></pre>
</td>
</tr>
</table>
</div>
</div>
</div>
<div id="footer">
Generated on Mon Oct 22 13:20:51 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>