humidifier-reservoir 0.2.3 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +15 -3
- data/docs/Humidifier.html +2 -2
- data/docs/Humidifier/Reservoir.html +23 -21
- data/docs/Humidifier/Reservoir/BaseMapper.html +1 -1
- data/docs/Humidifier/Reservoir/CLI.html +5 -5
- data/docs/Humidifier/Reservoir/Config.html +1 -1
- data/docs/Humidifier/Reservoir/Error.html +1 -1
- data/docs/Humidifier/Reservoir/Mapping.html +1 -1
- data/docs/Humidifier/Reservoir/ParameterList.html +197 -0
- data/docs/Humidifier/Reservoir/Stack.html +123 -41
- data/docs/Humidifier/Reservoir/Stack/Export.html +1 -1
- data/docs/_index.html +19 -1
- data/docs/class_list.html +1 -1
- data/docs/file.LICENSE.html +1 -1
- data/docs/file.README.html +25 -9
- data/docs/index.html +25 -9
- data/docs/method_list.html +40 -24
- data/docs/top-level-namespace.html +1 -1
- data/lib/humidifier/reservoir.rb +1 -0
- data/lib/humidifier/reservoir/cli.rb +10 -3
- data/lib/humidifier/reservoir/parameter_list.rb +16 -0
- data/lib/humidifier/reservoir/stack.rb +31 -11
- data/lib/humidifier/reservoir/version.rb +1 -1
- metadata +3 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d1b17c11c89451849c3ceb3ffa69df8756df5b7a
|
4
|
+
data.tar.gz: 3e5d54694c33bc73ee83695125fa8323340da5c6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 48055b66dede0396c5bd2d08fde6d0aec8c8f7fba2868f8f223710bf85b5a5630c67c21ccda8f5feb77297a5a07117634a45a6a6fd2c5b7ebf1b7e49973dfb81
|
7
|
+
data.tar.gz: b3c9d18792c8331410e6bc324842830168d9ab635cdf2fb7e5082a33e772c158c95b27de7cc8075680f32e4534b71abae43640961fe9da15173137724eb2410c
|
data/README.md
CHANGED
@@ -120,10 +120,14 @@ Below are the list of commands and some of their options.
|
|
120
120
|
Creates a change set for either the specified stack or all stacks in the repo. The change set represents the changes between what is currently deployed versus
|
121
121
|
the resources represented by the configuration.
|
122
122
|
|
123
|
-
#### `deploy [?stack]`
|
123
|
+
#### `deploy [?stack] [*parameters]`
|
124
124
|
|
125
125
|
Creates or updates (depending on if the stack already exists) one or all stacks in the repo.
|
126
126
|
|
127
|
+
#### --prefix
|
128
|
+
|
129
|
+
The `deploy` command also allows a `--prefix` command line argument that will override the default prefix (if one is configured) for the stack that is being deployed. This is especially useful when you're deploying multiple copies of the same stack (for instance, multiple autoscaling groups) that have different purposes or semantically mean newer versions of resources.
|
130
|
+
|
127
131
|
#### `display [stack] [?pattern]`
|
128
132
|
|
129
133
|
Displays the specified stack in JSON format on the command line. If you optionally pass a pattern argument, it will filter the resources down to just ones whose names match the given pattern.
|
@@ -136,9 +140,17 @@ Upload one or all stacks in the repo to S3 for reference later. Note that this m
|
|
136
140
|
|
137
141
|
Validate that one or all stacks in the repo are properly configured and using values that CloudFormation understands.
|
138
142
|
|
139
|
-
|
143
|
+
### Parameters
|
140
144
|
|
141
|
-
|
145
|
+
CloudFormation template parameters can be specified by having a special `parameters.yml` file in your stack directory. This file should contain a YAML-encoded object whose keys are the names of the parameters and whose values are the parameter configuration (using the same underscore paradigm as `humidifier` resources for specifying configuration).
|
146
|
+
|
147
|
+
You can pass values to the CLI deploy command after the stack name on the command line as in:
|
148
|
+
|
149
|
+
```sh
|
150
|
+
bin/reservoir deploy foobar Param1=Foo Param2=Bar
|
151
|
+
```
|
152
|
+
|
153
|
+
Those parameters will get passed in as values when the stack is deployed.
|
142
154
|
|
143
155
|
### Shortcuts
|
144
156
|
|
data/docs/Humidifier.html
CHANGED
@@ -79,7 +79,7 @@
|
|
79
79
|
<dl>
|
80
80
|
<dt>Defined in:</dt>
|
81
81
|
<dd>lib/humidifier/reservoir.rb<span class="defines">,<br />
|
82
|
-
lib/humidifier/reservoir/cli.rb,<br /> lib/humidifier/reservoir/error.rb,<br /> lib/humidifier/reservoir/stack.rb,<br /> lib/humidifier/reservoir/config.rb,<br /> lib/humidifier/reservoir/mapping.rb,<br /> lib/humidifier/reservoir/version.rb,<br /> lib/humidifier/reservoir/base_mapper.rb</span>
|
82
|
+
lib/humidifier/reservoir/cli.rb,<br /> lib/humidifier/reservoir/error.rb,<br /> lib/humidifier/reservoir/stack.rb,<br /> lib/humidifier/reservoir/config.rb,<br /> lib/humidifier/reservoir/mapping.rb,<br /> lib/humidifier/reservoir/version.rb,<br /> lib/humidifier/reservoir/base_mapper.rb,<br /> lib/humidifier/reservoir/parameter_list.rb</span>
|
83
83
|
</dd>
|
84
84
|
</dl>
|
85
85
|
|
@@ -107,7 +107,7 @@
|
|
107
107
|
</div>
|
108
108
|
|
109
109
|
<div id="footer">
|
110
|
-
Generated on Tue Dec 5
|
110
|
+
Generated on Tue Dec 5 18:38:21 2017 by
|
111
111
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
112
112
|
0.9.12 (ruby-2.4.2).
|
113
113
|
</div>
|
@@ -79,7 +79,7 @@
|
|
79
79
|
<dl>
|
80
80
|
<dt>Defined in:</dt>
|
81
81
|
<dd>lib/humidifier/reservoir.rb<span class="defines">,<br />
|
82
|
-
lib/humidifier/reservoir/cli.rb,<br /> lib/humidifier/reservoir/error.rb,<br /> lib/humidifier/reservoir/stack.rb,<br /> lib/humidifier/reservoir/config.rb,<br /> lib/humidifier/reservoir/mapping.rb,<br /> lib/humidifier/reservoir/version.rb,<br /> lib/humidifier/reservoir/base_mapper.rb</span>
|
82
|
+
lib/humidifier/reservoir/cli.rb,<br /> lib/humidifier/reservoir/error.rb,<br /> lib/humidifier/reservoir/stack.rb,<br /> lib/humidifier/reservoir/config.rb,<br /> lib/humidifier/reservoir/mapping.rb,<br /> lib/humidifier/reservoir/version.rb,<br /> lib/humidifier/reservoir/base_mapper.rb,<br /> lib/humidifier/reservoir/parameter_list.rb</span>
|
83
83
|
</dd>
|
84
84
|
</dl>
|
85
85
|
|
@@ -100,6 +100,8 @@
|
|
100
100
|
<p class="children">
|
101
101
|
|
102
102
|
|
103
|
+
<strong class="modules">Modules:</strong> <span class='object_link'><a href="Reservoir/ParameterList.html" title="Humidifier::Reservoir::ParameterList (module)">ParameterList</a></span>
|
104
|
+
|
103
105
|
|
104
106
|
|
105
107
|
<strong class="classes">Classes:</strong> <span class='object_link'><a href="Reservoir/BaseMapper.html" title="Humidifier::Reservoir::BaseMapper (class)">BaseMapper</a></span>, <span class='object_link'><a href="Reservoir/CLI.html" title="Humidifier::Reservoir::CLI (class)">CLI</a></span>, <span class='object_link'><a href="Reservoir/Config.html" title="Humidifier::Reservoir::Config (class)">Config</a></span>, <span class='object_link'><a href="Reservoir/Error.html" title="Humidifier::Reservoir::Error (class)">Error</a></span>, <span class='object_link'><a href="Reservoir/Mapping.html" title="Humidifier::Reservoir::Mapping (class)">Mapping</a></span>, <span class='object_link'><a href="Reservoir/Stack.html" title="Humidifier::Reservoir::Stack (class)">Stack</a></span>
|
@@ -124,7 +126,7 @@
|
|
124
126
|
|
125
127
|
</div>
|
126
128
|
</dt>
|
127
|
-
<dd><pre class="code"><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>0.
|
129
|
+
<dd><pre class="code"><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>0.3.0</span><span class='tstring_end'>'</span></span><span class='period'>.</span><span class='id identifier rubyid_freeze'>freeze</span></pre></dd>
|
128
130
|
|
129
131
|
</dl>
|
130
132
|
|
@@ -298,12 +300,12 @@
|
|
298
300
|
<pre class="lines">
|
299
301
|
|
300
302
|
|
301
|
-
19
|
302
303
|
20
|
303
|
-
21
|
304
|
+
21
|
305
|
+
22</pre>
|
304
306
|
</td>
|
305
307
|
<td>
|
306
|
-
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line
|
308
|
+
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line 20</span>
|
307
309
|
|
308
310
|
<span class='kw'>def</span> <span class='id identifier rubyid_config'>config</span>
|
309
311
|
<span class='ivar'>@config</span> <span class='op'>||=</span> <span class='const'><span class='object_link'><a href="Reservoir/Config.html" title="Humidifier::Reservoir::Config (class)">Config</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Reservoir/Config.html#initialize-instance_method" title="Humidifier::Reservoir::Config#initialize (method)">new</a></span></span>
|
@@ -350,12 +352,12 @@
|
|
350
352
|
<pre class="lines">
|
351
353
|
|
352
354
|
|
353
|
-
23
|
354
355
|
24
|
355
|
-
25
|
356
|
+
25
|
357
|
+
26</pre>
|
356
358
|
</td>
|
357
359
|
<td>
|
358
|
-
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line
|
360
|
+
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line 24</span>
|
359
361
|
|
360
362
|
<span class='kw'>def</span> <span class='id identifier rubyid_configure'>configure</span>
|
361
363
|
<span class='kw'>yield</span> <span class='id identifier rubyid_config'>config</span>
|
@@ -380,12 +382,12 @@
|
|
380
382
|
<pre class="lines">
|
381
383
|
|
382
384
|
|
383
|
-
27
|
384
385
|
28
|
385
|
-
29
|
386
|
+
29
|
387
|
+
30</pre>
|
386
388
|
</td>
|
387
389
|
<td>
|
388
|
-
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line
|
390
|
+
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line 28</span>
|
389
391
|
|
390
392
|
<span class='kw'>def</span> <span class='id identifier rubyid_files_for'>files_for</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='rparen'>)</span>
|
391
393
|
<span class='id identifier rubyid_config'>config</span><span class='period'>.</span><span class='id identifier rubyid_files_for'>files_for</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='rparen'>)</span>
|
@@ -410,12 +412,12 @@
|
|
410
412
|
<pre class="lines">
|
411
413
|
|
412
414
|
|
413
|
-
31
|
414
415
|
32
|
415
|
-
33
|
416
|
+
33
|
417
|
+
34</pre>
|
416
418
|
</td>
|
417
419
|
<td>
|
418
|
-
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line
|
420
|
+
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line 32</span>
|
419
421
|
|
420
422
|
<span class='kw'>def</span> <span class='id identifier rubyid_mapping_for'>mapping_for</span><span class='lparen'>(</span><span class='id identifier rubyid_type'>type</span><span class='rparen'>)</span>
|
421
423
|
<span class='id identifier rubyid_config'>config</span><span class='period'>.</span><span class='id identifier rubyid_mapping_for'>mapping_for</span><span class='lparen'>(</span><span class='id identifier rubyid_type'>type</span><span class='rparen'>)</span>
|
@@ -440,12 +442,12 @@
|
|
440
442
|
<pre class="lines">
|
441
443
|
|
442
444
|
|
443
|
-
35
|
444
445
|
36
|
445
|
-
37
|
446
|
+
37
|
447
|
+
38</pre>
|
446
448
|
</td>
|
447
449
|
<td>
|
448
|
-
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line
|
450
|
+
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line 36</span>
|
449
451
|
|
450
452
|
<span class='kw'>def</span> <span class='id identifier rubyid_stack_prefix'>stack_prefix</span>
|
451
453
|
<span class='id identifier rubyid_config'>config</span><span class='period'>.</span><span class='id identifier rubyid_stack_prefix'>stack_prefix</span>
|
@@ -470,12 +472,12 @@
|
|
470
472
|
<pre class="lines">
|
471
473
|
|
472
474
|
|
473
|
-
39
|
474
475
|
40
|
475
|
-
41
|
476
|
+
41
|
477
|
+
42</pre>
|
476
478
|
</td>
|
477
479
|
<td>
|
478
|
-
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line
|
480
|
+
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir.rb', line 40</span>
|
479
481
|
|
480
482
|
<span class='kw'>def</span> <span class='id identifier rubyid_stacks'>stacks</span>
|
481
483
|
<span class='id identifier rubyid_config'>config</span><span class='period'>.</span><span class='id identifier rubyid_stacks'>stacks</span>
|
@@ -490,7 +492,7 @@
|
|
490
492
|
</div>
|
491
493
|
|
492
494
|
<div id="footer">
|
493
|
-
Generated on Tue Dec 5
|
495
|
+
Generated on Tue Dec 5 18:38:21 2017 by
|
494
496
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
495
497
|
0.9.12 (ruby-2.4.2).
|
496
498
|
</div>
|
@@ -487,7 +487,7 @@ logical name for the resource, and the user-specified attributes.</p>
|
|
487
487
|
</div>
|
488
488
|
|
489
489
|
<div id="footer">
|
490
|
-
Generated on Tue Dec 5
|
490
|
+
Generated on Tue Dec 5 18:38:22 2017 by
|
491
491
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
492
492
|
0.9.12 (ruby-2.4.2).
|
493
493
|
</div>
|
@@ -153,7 +153,7 @@ about.</p>
|
|
153
153
|
<li class="public ">
|
154
154
|
<span class="summary_signature">
|
155
155
|
|
156
|
-
<a href="#deploy-instance_method" title="#deploy (instance method)">#<strong>deploy</strong>(name = nil) ⇒ Object </a>
|
156
|
+
<a href="#deploy-instance_method" title="#deploy (instance method)">#<strong>deploy</strong>(name = nil, *parameters) ⇒ Object </a>
|
157
157
|
|
158
158
|
|
159
159
|
|
@@ -295,7 +295,7 @@ about.</p>
|
|
295
295
|
<div class="method_details ">
|
296
296
|
<h3 class="signature " id="deploy-instance_method">
|
297
297
|
|
298
|
-
#<strong>deploy</strong>(name = nil) ⇒ <tt>Object</tt>
|
298
|
+
#<strong>deploy</strong>(name = nil, *parameters) ⇒ <tt>Object</tt>
|
299
299
|
|
300
300
|
|
301
301
|
|
@@ -321,14 +321,14 @@ about.</p>
|
|
321
321
|
<td>
|
322
322
|
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir/cli.rb', line 28</span>
|
323
323
|
|
324
|
-
<span class='kw'>def</span> <span class='id identifier rubyid_deploy'>deploy</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='rparen'>)</span>
|
324
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_deploy'>deploy</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='comma'>,</span> <span class='op'>*</span><span class='id identifier rubyid_parameters'>parameters</span><span class='rparen'>)</span>
|
325
325
|
<span class='id identifier rubyid_stack_names'>stack_names</span> <span class='op'>=</span> <span class='id identifier rubyid_stack_names_from'>stack_names_from</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='rparen'>)</span>
|
326
326
|
<span class='id identifier rubyid_authorize'>authorize</span>
|
327
327
|
|
328
328
|
<span class='id identifier rubyid_stack_names'>stack_names</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_stack_name'>stack_name</span><span class='op'>|</span>
|
329
329
|
<span class='id identifier rubyid_stack'>stack</span> <span class='op'>=</span> <span class='const'><span class='object_link'><a href="Stack.html" title="Humidifier::Reservoir::Stack (class)">Stack</a></span></span><span class='period'>.</span><span class='id identifier rubyid_new'><span class='object_link'><a href="Stack.html#initialize-instance_method" title="Humidifier::Reservoir::Stack#initialize (method)">new</a></span></span><span class='lparen'>(</span><span class='id identifier rubyid_stack_name'>stack_name</span><span class='comma'>,</span> <span class='label'>prefix:</span> <span class='id identifier rubyid_options'>options</span><span class='lbracket'>[</span><span class='symbol'>:prefix</span><span class='rbracket'>]</span><span class='rparen'>)</span>
|
330
330
|
<span class='id identifier rubyid_puts'>puts</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Deploying </span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_stack'>stack</span><span class='period'>.</span><span class='id identifier rubyid_stack_name'>stack_name</span><span class='embexpr_end'>}</span><span class='tstring_end'>"</span></span>
|
331
|
-
<span class='id identifier rubyid_stack'>stack</span><span class='period'>.</span><span class='id identifier rubyid_deploy'>deploy</span><span class='lparen'>(</span><span class='id identifier rubyid_options'>options</span><span class='lbracket'>[</span><span class='symbol'>:wait</span><span class='rbracket'>]</span><span class='rparen'>)</span>
|
331
|
+
<span class='id identifier rubyid_stack'>stack</span><span class='period'>.</span><span class='id identifier rubyid_deploy'>deploy</span><span class='lparen'>(</span><span class='id identifier rubyid_options'>options</span><span class='lbracket'>[</span><span class='symbol'>:wait</span><span class='rbracket'>]</span><span class='comma'>,</span> <span class='id identifier rubyid_parameters_from'>parameters_from</span><span class='lparen'>(</span><span class='id identifier rubyid_parameters'>parameters</span><span class='rparen'>)</span><span class='rparen'>)</span>
|
332
332
|
<span class='kw'>end</span>
|
333
333
|
<span class='kw'>end</span></pre>
|
334
334
|
</td>
|
@@ -463,7 +463,7 @@ about.</p>
|
|
463
463
|
</div>
|
464
464
|
|
465
465
|
<div id="footer">
|
466
|
-
Generated on Tue Dec 5
|
466
|
+
Generated on Tue Dec 5 18:38:21 2017 by
|
467
467
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
468
468
|
0.9.12 (ruby-2.4.2).
|
469
469
|
</div>
|
@@ -668,7 +668,7 @@
|
|
668
668
|
</div>
|
669
669
|
|
670
670
|
<div id="footer">
|
671
|
-
Generated on Tue Dec 5
|
671
|
+
Generated on Tue Dec 5 18:38:22 2017 by
|
672
672
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
673
673
|
0.9.12 (ruby-2.4.2).
|
674
674
|
</div>
|
@@ -126,7 +126,7 @@ CLI.</p>
|
|
126
126
|
</div>
|
127
127
|
|
128
128
|
<div id="footer">
|
129
|
-
Generated on Tue Dec 5
|
129
|
+
Generated on Tue Dec 5 18:38:21 2017 by
|
130
130
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
131
131
|
0.9.12 (ruby-2.4.2).
|
132
132
|
</div>
|
@@ -445,7 +445,7 @@ default.</p>
|
|
445
445
|
</div>
|
446
446
|
|
447
447
|
<div id="footer">
|
448
|
-
Generated on Tue Dec 5
|
448
|
+
Generated on Tue Dec 5 18:38:22 2017 by
|
449
449
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
450
450
|
0.9.12 (ruby-2.4.2).
|
451
451
|
</div>
|
@@ -0,0 +1,197 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<meta charset="utf-8">
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
6
|
+
<title>
|
7
|
+
Module: Humidifier::Reservoir::ParameterList
|
8
|
+
|
9
|
+
— Humidifier::Reservoir
|
10
|
+
|
11
|
+
</title>
|
12
|
+
|
13
|
+
<link rel="stylesheet" href="../../css/style.css" type="text/css" charset="utf-8" />
|
14
|
+
|
15
|
+
<link rel="stylesheet" href="../../css/common.css" type="text/css" charset="utf-8" />
|
16
|
+
|
17
|
+
<script type="text/javascript" charset="utf-8">
|
18
|
+
pathId = "Humidifier::Reservoir::ParameterList";
|
19
|
+
relpath = '../../';
|
20
|
+
</script>
|
21
|
+
|
22
|
+
|
23
|
+
<script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
|
24
|
+
|
25
|
+
<script type="text/javascript" charset="utf-8" src="../../js/app.js"></script>
|
26
|
+
|
27
|
+
|
28
|
+
</head>
|
29
|
+
<body>
|
30
|
+
<div class="nav_wrap">
|
31
|
+
<iframe id="nav" src="../../class_list.html?1"></iframe>
|
32
|
+
<div id="resizer"></div>
|
33
|
+
</div>
|
34
|
+
|
35
|
+
<div id="main" tabindex="-1">
|
36
|
+
<div id="header">
|
37
|
+
<div id="menu">
|
38
|
+
|
39
|
+
<a href="../../_index.html">Index (P)</a> »
|
40
|
+
<span class='title'><span class='object_link'><a href="../../Humidifier.html" title="Humidifier (module)">Humidifier</a></span></span> » <span class='title'><span class='object_link'><a href="../Reservoir.html" title="Humidifier::Reservoir (module)">Reservoir</a></span></span>
|
41
|
+
»
|
42
|
+
<span class="title">ParameterList</span>
|
43
|
+
|
44
|
+
</div>
|
45
|
+
|
46
|
+
<div id="search">
|
47
|
+
|
48
|
+
<a class="full_list_link" id="class_list_link"
|
49
|
+
href="../../class_list.html">
|
50
|
+
|
51
|
+
<svg width="24" height="24">
|
52
|
+
<rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
|
53
|
+
<rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
|
54
|
+
<rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
|
55
|
+
</svg>
|
56
|
+
</a>
|
57
|
+
|
58
|
+
</div>
|
59
|
+
<div class="clear"></div>
|
60
|
+
</div>
|
61
|
+
|
62
|
+
<div id="content"><h1>Module: Humidifier::Reservoir::ParameterList
|
63
|
+
|
64
|
+
|
65
|
+
|
66
|
+
</h1>
|
67
|
+
<div class="box_info">
|
68
|
+
|
69
|
+
|
70
|
+
|
71
|
+
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
<dl>
|
80
|
+
<dt>Defined in:</dt>
|
81
|
+
<dd>lib/humidifier/reservoir/parameter_list.rb</dd>
|
82
|
+
</dl>
|
83
|
+
|
84
|
+
</div>
|
85
|
+
|
86
|
+
<h2>Overview</h2><div class="docstring">
|
87
|
+
<div class="discussion">
|
88
|
+
|
89
|
+
<p>The list of parameters for a given stack parsed from the given filepath.</p>
|
90
|
+
|
91
|
+
|
92
|
+
</div>
|
93
|
+
</div>
|
94
|
+
<div class="tags">
|
95
|
+
|
96
|
+
|
97
|
+
</div>
|
98
|
+
|
99
|
+
|
100
|
+
|
101
|
+
|
102
|
+
|
103
|
+
|
104
|
+
|
105
|
+
<h2>
|
106
|
+
Class Method Summary
|
107
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
108
|
+
</h2>
|
109
|
+
|
110
|
+
<ul class="summary">
|
111
|
+
|
112
|
+
<li class="public ">
|
113
|
+
<span class="summary_signature">
|
114
|
+
|
115
|
+
<a href="#from-class_method" title="from (class method)">.<strong>from</strong>(filepath) ⇒ Object </a>
|
116
|
+
|
117
|
+
|
118
|
+
|
119
|
+
</span>
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
|
124
|
+
|
125
|
+
|
126
|
+
|
127
|
+
|
128
|
+
|
129
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
130
|
+
|
131
|
+
</li>
|
132
|
+
|
133
|
+
|
134
|
+
</ul>
|
135
|
+
|
136
|
+
|
137
|
+
|
138
|
+
|
139
|
+
<div id="class_method_details" class="method_details_list">
|
140
|
+
<h2>Class Method Details</h2>
|
141
|
+
|
142
|
+
|
143
|
+
<div class="method_details first">
|
144
|
+
<h3 class="signature first" id="from-class_method">
|
145
|
+
|
146
|
+
.<strong>from</strong>(filepath) ⇒ <tt>Object</tt>
|
147
|
+
|
148
|
+
|
149
|
+
|
150
|
+
|
151
|
+
|
152
|
+
</h3><table class="source_code">
|
153
|
+
<tr>
|
154
|
+
<td>
|
155
|
+
<pre class="lines">
|
156
|
+
|
157
|
+
|
158
|
+
5
|
159
|
+
6
|
160
|
+
7
|
161
|
+
8
|
162
|
+
9
|
163
|
+
10
|
164
|
+
11
|
165
|
+
12
|
166
|
+
13</pre>
|
167
|
+
</td>
|
168
|
+
<td>
|
169
|
+
<pre class="code"><span class="info file"># File 'lib/humidifier/reservoir/parameter_list.rb', line 5</span>
|
170
|
+
|
171
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_from'>from</span><span class='lparen'>(</span><span class='id identifier rubyid_filepath'>filepath</span><span class='rparen'>)</span>
|
172
|
+
<span class='id identifier rubyid_loaded'>loaded</span> <span class='op'>=</span> <span class='const'>YAML</span><span class='period'>.</span><span class='id identifier rubyid_load_file'>load_file</span><span class='lparen'>(</span><span class='id identifier rubyid_filepath'>filepath</span><span class='rparen'>)</span>
|
173
|
+
<span class='kw'>return</span> <span class='lbrace'>{</span><span class='rbrace'>}</span> <span class='kw'>unless</span> <span class='id identifier rubyid_loaded'>loaded</span>
|
174
|
+
|
175
|
+
<span class='id identifier rubyid_loaded'>loaded</span><span class='period'>.</span><span class='id identifier rubyid_each_with_object'>each_with_object</span><span class='lparen'>(</span><span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span> <span class='kw'>do</span> <span class='op'>|</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='comma'>,</span> <span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span><span class='comma'>,</span> <span class='id identifier rubyid_params'>params</span><span class='op'>|</span>
|
176
|
+
<span class='id identifier rubyid_opts'>opts</span> <span class='op'>=</span> <span class='id identifier rubyid_opts'>opts</span><span class='period'>.</span><span class='id identifier rubyid_map'>map</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_key'>key</span><span class='comma'>,</span> <span class='id identifier rubyid_value'>value</span><span class='op'>|</span> <span class='lbracket'>[</span><span class='id identifier rubyid_key'>key</span><span class='period'>.</span><span class='id identifier rubyid_to_sym'>to_sym</span><span class='comma'>,</span> <span class='id identifier rubyid_value'>value</span><span class='rbracket'>]</span> <span class='rbrace'>}</span><span class='period'>.</span><span class='id identifier rubyid_to_h'>to_h</span>
|
177
|
+
<span class='id identifier rubyid_params'>params</span><span class='lbracket'>[</span><span class='id identifier rubyid_name'>name</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='const'>Parameter</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_opts'>opts</span><span class='rparen'>)</span>
|
178
|
+
<span class='kw'>end</span>
|
179
|
+
<span class='kw'>end</span></pre>
|
180
|
+
</td>
|
181
|
+
</tr>
|
182
|
+
</table>
|
183
|
+
</div>
|
184
|
+
|
185
|
+
</div>
|
186
|
+
|
187
|
+
</div>
|
188
|
+
|
189
|
+
<div id="footer">
|
190
|
+
Generated on Tue Dec 5 18:38:21 2017 by
|
191
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
192
|
+
0.9.12 (ruby-2.4.2).
|
193
|
+
</div>
|
194
|
+
|
195
|
+
</div>
|
196
|
+
</body>
|
197
|
+
</html>
|