humidifier-reservoir 0.0.1 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,331 @@
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
+ Class: Humidifier::Reservoir::CLI
8
+
9
+ &mdash; 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::CLI";
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 (C)</a> &raquo;
40
+ <span class='title'><span class='object_link'><a href="../../Humidifier.html" title="Humidifier (module)">Humidifier</a></span></span> &raquo; <span class='title'><span class='object_link'><a href="../Reservoir.html" title="Humidifier::Reservoir (module)">Reservoir</a></span></span>
41
+ &raquo;
42
+ <span class="title">CLI</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>Class: Humidifier::Reservoir::CLI
63
+
64
+
65
+
66
+ </h1>
67
+ <div class="box_info">
68
+
69
+ <dl>
70
+ <dt>Inherits:</dt>
71
+ <dd>
72
+ <span class="inheritName">Thor</span>
73
+
74
+ <ul class="fullTree">
75
+ <li>Object</li>
76
+
77
+ <li class="next">Thor</li>
78
+
79
+ <li class="next">Humidifier::Reservoir::CLI</li>
80
+
81
+ </ul>
82
+ <a href="#" class="inheritanceTree">show all</a>
83
+
84
+ </dd>
85
+ </dl>
86
+
87
+
88
+
89
+
90
+
91
+
92
+
93
+
94
+
95
+
96
+
97
+ <dl>
98
+ <dt>Defined in:</dt>
99
+ <dd>lib/humidifier/reservoir/cli.rb</dd>
100
+ </dl>
101
+
102
+ </div>
103
+
104
+ <h2>Overview</h2><div class="docstring">
105
+ <div class="discussion">
106
+
107
+ <p>A CLI for running commands to manipulate the stacks that Reservoir knows
108
+ about.</p>
109
+
110
+
111
+ </div>
112
+ </div>
113
+ <div class="tags">
114
+
115
+
116
+ </div>
117
+
118
+
119
+
120
+
121
+
122
+
123
+
124
+ <h2>
125
+ Instance Method Summary
126
+ <small><a href="#" class="summary_toggle">collapse</a></small>
127
+ </h2>
128
+
129
+ <ul class="summary">
130
+
131
+ <li class="public ">
132
+ <span class="summary_signature">
133
+
134
+ <a href="#deploy-instance_method" title="#deploy (instance method)">#<strong>deploy</strong>(name = nil) &#x21d2; Object </a>
135
+
136
+
137
+
138
+ </span>
139
+
140
+
141
+
142
+
143
+
144
+
145
+
146
+
147
+
148
+ <span class="summary_desc"><div class='inline'></div></span>
149
+
150
+ </li>
151
+
152
+
153
+ <li class="public ">
154
+ <span class="summary_signature">
155
+
156
+ <a href="#display-instance_method" title="#display (instance method)">#<strong>display</strong>(name, pattern = nil) &#x21d2; Object </a>
157
+
158
+
159
+
160
+ </span>
161
+
162
+
163
+
164
+
165
+
166
+
167
+
168
+
169
+
170
+ <span class="summary_desc"><div class='inline'></div></span>
171
+
172
+ </li>
173
+
174
+
175
+ <li class="public ">
176
+ <span class="summary_signature">
177
+
178
+ <a href="#validate-instance_method" title="#validate (instance method)">#<strong>validate</strong>(name = nil) &#x21d2; Object </a>
179
+
180
+
181
+
182
+ </span>
183
+
184
+
185
+
186
+
187
+
188
+
189
+
190
+
191
+
192
+ <span class="summary_desc"><div class='inline'></div></span>
193
+
194
+ </li>
195
+
196
+
197
+ </ul>
198
+
199
+
200
+
201
+
202
+
203
+ <div id="instance_method_details" class="method_details_list">
204
+ <h2>Instance Method Details</h2>
205
+
206
+
207
+ <div class="method_details first">
208
+ <h3 class="signature first" id="deploy-instance_method">
209
+
210
+ #<strong>deploy</strong>(name = nil) &#x21d2; <tt>Object</tt>
211
+
212
+
213
+
214
+
215
+
216
+ </h3><table class="source_code">
217
+ <tr>
218
+ <td>
219
+ <pre class="lines">
220
+
221
+
222
+ 13
223
+ 14
224
+ 15
225
+ 16
226
+ 17
227
+ 18
228
+ 19
229
+ 20
230
+ 21
231
+ 22</pre>
232
+ </td>
233
+ <td>
234
+ <pre class="code"><span class="info file"># File 'lib/humidifier/reservoir/cli.rb', line 13</span>
235
+
236
+ <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>
237
+ <span class='id identifier rubyid_stack_names'>stack_names</span> <span class='op'>=</span> <span class='id identifier rubyid_name'>name</span> <span class='op'>?</span> <span class='lbracket'>[</span><span class='id identifier rubyid_name'>name</span><span class='rbracket'>]</span> <span class='op'>:</span> <span class='const'><span class='object_link'><a href="../Reservoir.html" title="Humidifier::Reservoir (module)">Reservoir</a></span></span><span class='period'>.</span><span class='id identifier rubyid_stacks'><span class='object_link'><a href="../Reservoir.html#stacks-class_method" title="Humidifier::Reservoir.stacks (method)">stacks</a></span></span>
238
+ <span class='id identifier rubyid_authorize'>authorize</span>
239
+
240
+ <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>
241
+ <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='rparen'>)</span>
242
+ <span class='id identifier rubyid_puts'>puts</span> <span class='tstring'><span class='tstring_beg'>&quot;</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'>&quot;</span></span>
243
+ <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>
244
+ <span class='kw'>end</span>
245
+ <span class='kw'>end</span></pre>
246
+ </td>
247
+ </tr>
248
+ </table>
249
+ </div>
250
+
251
+ <div class="method_details ">
252
+ <h3 class="signature " id="display-instance_method">
253
+
254
+ #<strong>display</strong>(name, pattern = nil) &#x21d2; <tt>Object</tt>
255
+
256
+
257
+
258
+
259
+
260
+ </h3><table class="source_code">
261
+ <tr>
262
+ <td>
263
+ <pre class="lines">
264
+
265
+
266
+ 25
267
+ 26
268
+ 27</pre>
269
+ </td>
270
+ <td>
271
+ <pre class="code"><span class="info file"># File 'lib/humidifier/reservoir/cli.rb', line 25</span>
272
+
273
+ <span class='kw'>def</span> <span class='id identifier rubyid_display'>display</span><span class='lparen'>(</span><span class='id identifier rubyid_name'>name</span><span class='comma'>,</span> <span class='id identifier rubyid_pattern'>pattern</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='rparen'>)</span>
274
+ <span class='id identifier rubyid_puts'>puts</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_name'>name</span><span class='comma'>,</span> <span class='id identifier rubyid_pattern'>pattern</span> <span class='op'>&amp;&amp;</span> <span class='tstring'><span class='regexp_beg'>/</span><span class='embexpr_beg'>#{</span><span class='id identifier rubyid_pattern'>pattern</span><span class='embexpr_end'>}</span><span class='regexp_end'>/i</span></span><span class='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_to_cf'><span class='object_link'><a href="Stack.html#to_cf-instance_method" title="Humidifier::Reservoir::Stack#to_cf (method)">to_cf</a></span></span>
275
+ <span class='kw'>end</span></pre>
276
+ </td>
277
+ </tr>
278
+ </table>
279
+ </div>
280
+
281
+ <div class="method_details ">
282
+ <h3 class="signature " id="validate-instance_method">
283
+
284
+ #<strong>validate</strong>(name = nil) &#x21d2; <tt>Object</tt>
285
+
286
+
287
+
288
+
289
+
290
+ </h3><table class="source_code">
291
+ <tr>
292
+ <td>
293
+ <pre class="lines">
294
+
295
+
296
+ 30
297
+ 31
298
+ 32
299
+ 33
300
+ 34
301
+ 35
302
+ 36</pre>
303
+ </td>
304
+ <td>
305
+ <pre class="code"><span class="info file"># File 'lib/humidifier/reservoir/cli.rb', line 30</span>
306
+
307
+ <span class='kw'>def</span> <span class='id identifier rubyid_validate'>validate</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>
308
+ <span class='id identifier rubyid_stack_names'>stack_names</span> <span class='op'>=</span> <span class='id identifier rubyid_name'>name</span> <span class='op'>?</span> <span class='lbracket'>[</span><span class='id identifier rubyid_name'>name</span><span class='rbracket'>]</span> <span class='op'>:</span> <span class='const'><span class='object_link'><a href="../Reservoir.html" title="Humidifier::Reservoir (module)">Reservoir</a></span></span><span class='period'>.</span><span class='id identifier rubyid_stacks'><span class='object_link'><a href="../Reservoir.html#stacks-class_method" title="Humidifier::Reservoir.stacks (method)">stacks</a></span></span>
309
+ <span class='id identifier rubyid_authorize'>authorize</span>
310
+
311
+ <span class='id identifier rubyid_print'>print</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Validating... </span><span class='tstring_end'>&#39;</span></span>
312
+ <span class='id identifier rubyid_puts'>puts</span> <span class='tstring'><span class='tstring_beg'>&#39;</span><span class='tstring_content'>Valid.</span><span class='tstring_end'>&#39;</span></span> <span class='kw'>if</span> <span class='id identifier rubyid_stack_names'>stack_names</span><span class='period'>.</span><span class='id identifier rubyid_all?'>all?</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_stack_name'>stack_name</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='rparen'>)</span><span class='period'>.</span><span class='id identifier rubyid_valid?'><span class='object_link'><a href="Stack.html#valid%3F-instance_method" title="Humidifier::Reservoir::Stack#valid? (method)">valid?</a></span></span> <span class='rbrace'>}</span>
313
+ <span class='kw'>end</span></pre>
314
+ </td>
315
+ </tr>
316
+ </table>
317
+ </div>
318
+
319
+ </div>
320
+
321
+ </div>
322
+
323
+ <div id="footer">
324
+ Generated on Sun Oct 1 09:25:22 2017 by
325
+ <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
326
+ 0.9.9 (ruby-2.4.1).
327
+ </div>
328
+
329
+ </div>
330
+ </body>
331
+ </html>