triglav-agent 1.0.0.pre1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +11 -0
- data/.rspec +2 -0
- data/.travis.yml +6 -0
- data/.yardopts +6 -0
- data/CHANGELOG.md +3 -0
- data/CODE_OF_CONDUCT.md +49 -0
- data/Gemfile +5 -0
- data/LICENSE.txt +21 -0
- data/README.md +59 -0
- data/Rakefile +11 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/docs/Triglav/Agent/ApiClient/AuthenticationError.html +150 -0
- data/docs/Triglav/Agent/ApiClient/ConnectionError.html +150 -0
- data/docs/Triglav/Agent/ApiClient/Error.html +296 -0
- data/docs/Triglav/Agent/ApiClient.html +545 -0
- data/docs/Triglav/Agent/Base/CLI.html +498 -0
- data/docs/Triglav/Agent/Base/Connection.html +258 -0
- data/docs/Triglav/Agent/Base/Monitor.html +370 -0
- data/docs/Triglav/Agent/Base/Processor.html +623 -0
- data/docs/Triglav/Agent/Base/Setting.html +1081 -0
- data/docs/Triglav/Agent/Base/Worker.html +635 -0
- data/docs/Triglav/Agent/Base.html +121 -0
- data/docs/Triglav/Agent/Configuration.html +967 -0
- data/docs/Triglav/Agent/Error.html +130 -0
- data/docs/Triglav/Agent/HashUtil.html +351 -0
- data/docs/Triglav/Agent/LogFormatter.html +271 -0
- data/docs/Triglav/Agent/Logger.html +287 -0
- data/docs/Triglav/Agent/StorageFile.html +1130 -0
- data/docs/Triglav/Agent/Timer.html +424 -0
- data/docs/Triglav/Agent/TooManyError.html +134 -0
- data/docs/Triglav/Agent.html +131 -0
- data/docs/Triglav.html +119 -0
- data/docs/_index.html +335 -0
- data/docs/class_list.html +51 -0
- data/docs/css/common.css +1 -0
- data/docs/css/full_list.css +58 -0
- data/docs/css/style.css +481 -0
- data/docs/file.LICENSE.html +72 -0
- data/docs/file.README.html +137 -0
- data/docs/file_list.html +61 -0
- data/docs/frames.html +17 -0
- data/docs/index.html +137 -0
- data/docs/js/app.js +243 -0
- data/docs/js/full_list.js +216 -0
- data/docs/js/jquery.js +4 -0
- data/docs/method_list.html +659 -0
- data/docs/top-level-namespace.html +112 -0
- data/example/config.yml +40 -0
- data/lib/triglav/agent/api_client.rb +199 -0
- data/lib/triglav/agent/base/cli.rb +98 -0
- data/lib/triglav/agent/base/connection.rb +30 -0
- data/lib/triglav/agent/base/monitor.rb +32 -0
- data/lib/triglav/agent/base/processor.rb +136 -0
- data/lib/triglav/agent/base/setting.rb +112 -0
- data/lib/triglav/agent/base/worker.rb +95 -0
- data/lib/triglav/agent/configuration.rb +79 -0
- data/lib/triglav/agent/error.rb +4 -0
- data/lib/triglav/agent/hash_util.rb +36 -0
- data/lib/triglav/agent/logger.rb +50 -0
- data/lib/triglav/agent/storage_file.rb +144 -0
- data/lib/triglav/agent/timer.rb +80 -0
- data/lib/triglav/agent/version.rb +5 -0
- data/lib/triglav/agent.rb +20 -0
- data/lib/triglav-agent.rb +1 -0
- data/triglav-agent.gemspec +33 -0
- metadata +250 -0
@@ -0,0 +1,130 @@
|
|
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
|
+
Exception: Triglav::Agent::Error
|
8
|
+
|
9
|
+
— Documentation by YARD 0.9.5
|
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 = "Triglav::Agent::Error";
|
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"></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 (E)</a> »
|
40
|
+
<span class='title'><span class='object_link'><a href="../../Triglav.html" title="Triglav (module)">Triglav</a></span></span> » <span class='title'><span class='object_link'><a href="../Agent.html" title="Triglav::Agent (module)">Agent</a></span></span>
|
41
|
+
»
|
42
|
+
<span class="title">Error</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
|
+
<iframe id="search_frame" src="../../class_list.html"></iframe>
|
63
|
+
|
64
|
+
<div id="content"><h1>Exception: Triglav::Agent::Error
|
65
|
+
|
66
|
+
|
67
|
+
|
68
|
+
</h1>
|
69
|
+
<div class="box_info">
|
70
|
+
|
71
|
+
<dl>
|
72
|
+
<dt>Inherits:</dt>
|
73
|
+
<dd>
|
74
|
+
<span class="inheritName">StandardError</span>
|
75
|
+
|
76
|
+
<ul class="fullTree">
|
77
|
+
<li>Object</li>
|
78
|
+
|
79
|
+
<li class="next">StandardError</li>
|
80
|
+
|
81
|
+
<li class="next">Triglav::Agent::Error</li>
|
82
|
+
|
83
|
+
</ul>
|
84
|
+
<a href="#" class="inheritanceTree">show all</a>
|
85
|
+
|
86
|
+
</dd>
|
87
|
+
</dl>
|
88
|
+
|
89
|
+
|
90
|
+
|
91
|
+
|
92
|
+
|
93
|
+
|
94
|
+
|
95
|
+
|
96
|
+
|
97
|
+
|
98
|
+
|
99
|
+
<dl>
|
100
|
+
<dt>Defined in:</dt>
|
101
|
+
<dd>lib/triglav/agent/error.rb</dd>
|
102
|
+
</dl>
|
103
|
+
|
104
|
+
</div>
|
105
|
+
|
106
|
+
<div id="subclasses">
|
107
|
+
<h2>Direct Known Subclasses</h2>
|
108
|
+
<p class="children"><span class='object_link'><a href="TooManyError.html" title="Triglav::Agent::TooManyError (class)">TooManyError</a></span></p>
|
109
|
+
</div>
|
110
|
+
|
111
|
+
|
112
|
+
|
113
|
+
|
114
|
+
|
115
|
+
|
116
|
+
|
117
|
+
|
118
|
+
|
119
|
+
|
120
|
+
</div>
|
121
|
+
|
122
|
+
<div id="footer">
|
123
|
+
Generated on Thu Feb 23 23:20:33 2017 by
|
124
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
125
|
+
0.9.5 (ruby-2.3.2).
|
126
|
+
</div>
|
127
|
+
|
128
|
+
</div>
|
129
|
+
</body>
|
130
|
+
</html>
|
@@ -0,0 +1,351 @@
|
|
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: Triglav::Agent::HashUtil
|
8
|
+
|
9
|
+
— Documentation by YARD 0.9.5
|
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 = "Triglav::Agent::HashUtil";
|
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"></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 (H)</a> »
|
40
|
+
<span class='title'><span class='object_link'><a href="../../Triglav.html" title="Triglav (module)">Triglav</a></span></span> » <span class='title'><span class='object_link'><a href="../Agent.html" title="Triglav::Agent (module)">Agent</a></span></span>
|
41
|
+
»
|
42
|
+
<span class="title">HashUtil</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
|
+
<iframe id="search_frame" src="../../class_list.html"></iframe>
|
63
|
+
|
64
|
+
<div id="content"><h1>Class: Triglav::Agent::HashUtil
|
65
|
+
|
66
|
+
|
67
|
+
|
68
|
+
</h1>
|
69
|
+
<div class="box_info">
|
70
|
+
|
71
|
+
<dl>
|
72
|
+
<dt>Inherits:</dt>
|
73
|
+
<dd>
|
74
|
+
<span class="inheritName">Object</span>
|
75
|
+
|
76
|
+
<ul class="fullTree">
|
77
|
+
<li>Object</li>
|
78
|
+
|
79
|
+
<li class="next">Triglav::Agent::HashUtil</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/triglav/agent/hash_util.rb</dd>
|
100
|
+
</dl>
|
101
|
+
|
102
|
+
</div>
|
103
|
+
|
104
|
+
|
105
|
+
|
106
|
+
|
107
|
+
|
108
|
+
|
109
|
+
|
110
|
+
|
111
|
+
|
112
|
+
<h2>
|
113
|
+
Class Method Summary
|
114
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
115
|
+
</h2>
|
116
|
+
|
117
|
+
<ul class="summary">
|
118
|
+
|
119
|
+
<li class="public ">
|
120
|
+
<span class="summary_signature">
|
121
|
+
|
122
|
+
<a href="#deep_stringify_keys-class_method" title="deep_stringify_keys (class method)">.<strong>deep_stringify_keys</strong>(obj) ⇒ Object </a>
|
123
|
+
|
124
|
+
|
125
|
+
|
126
|
+
</span>
|
127
|
+
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
|
136
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
137
|
+
|
138
|
+
</li>
|
139
|
+
|
140
|
+
|
141
|
+
<li class="public ">
|
142
|
+
<span class="summary_signature">
|
143
|
+
|
144
|
+
<a href="#deep_symbolize_keys-class_method" title="deep_symbolize_keys (class method)">.<strong>deep_symbolize_keys</strong>(obj) ⇒ Object </a>
|
145
|
+
|
146
|
+
|
147
|
+
|
148
|
+
</span>
|
149
|
+
|
150
|
+
|
151
|
+
|
152
|
+
|
153
|
+
|
154
|
+
|
155
|
+
|
156
|
+
|
157
|
+
|
158
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
159
|
+
|
160
|
+
</li>
|
161
|
+
|
162
|
+
|
163
|
+
<li class="public ">
|
164
|
+
<span class="summary_signature">
|
165
|
+
|
166
|
+
<a href="#setdig-class_method" title="setdig (class method)">.<strong>setdig</strong>(hash, key, val) ⇒ Object </a>
|
167
|
+
|
168
|
+
|
169
|
+
|
170
|
+
</span>
|
171
|
+
|
172
|
+
|
173
|
+
|
174
|
+
|
175
|
+
|
176
|
+
|
177
|
+
|
178
|
+
|
179
|
+
|
180
|
+
<span class="summary_desc"><div class='inline'>
|
181
|
+
<p>HashUtil.setdig(hash, ['a', 'b'], 'bar') # like <a
|
182
|
+
href="'a'">hash</a>['b'] = 'bar'.</p>
|
183
|
+
</div></span>
|
184
|
+
|
185
|
+
</li>
|
186
|
+
|
187
|
+
|
188
|
+
</ul>
|
189
|
+
|
190
|
+
|
191
|
+
|
192
|
+
|
193
|
+
<div id="class_method_details" class="method_details_list">
|
194
|
+
<h2>Class Method Details</h2>
|
195
|
+
|
196
|
+
|
197
|
+
<div class="method_details first">
|
198
|
+
<h3 class="signature first" id="deep_stringify_keys-class_method">
|
199
|
+
|
200
|
+
.<strong>deep_stringify_keys</strong>(obj) ⇒ <tt>Object</tt>
|
201
|
+
|
202
|
+
|
203
|
+
|
204
|
+
|
205
|
+
|
206
|
+
</h3><table class="source_code">
|
207
|
+
<tr>
|
208
|
+
<td>
|
209
|
+
<pre class="lines">
|
210
|
+
|
211
|
+
|
212
|
+
14
|
213
|
+
15
|
214
|
+
16
|
215
|
+
17
|
216
|
+
18
|
217
|
+
19
|
218
|
+
20
|
219
|
+
21
|
220
|
+
22
|
221
|
+
23</pre>
|
222
|
+
</td>
|
223
|
+
<td>
|
224
|
+
<pre class="code"><span class="info file"># File 'lib/triglav/agent/hash_util.rb', line 14</span>
|
225
|
+
|
226
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_deep_stringify_keys'>deep_stringify_keys</span><span class='lparen'>(</span><span class='id identifier rubyid_obj'>obj</span><span class='rparen'>)</span>
|
227
|
+
<span class='kw'>case</span> <span class='id identifier rubyid_obj'>obj</span>
|
228
|
+
<span class='kw'>when</span> <span class='const'>Hash</span>
|
229
|
+
<span class='id identifier rubyid_obj'>obj</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_k'>k</span><span class='comma'>,</span> <span class='id identifier rubyid_v'>v</span><span class='op'>|</span> <span class='lbracket'>[</span><span class='id identifier rubyid_k'>k</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span><span class='comma'>,</span> <span class='id identifier rubyid_deep_stringify_keys'>deep_stringify_keys</span><span class='lparen'>(</span><span class='id identifier rubyid_v'>v</span><span class='rparen'>)</span><span class='rbracket'>]</span> <span class='rbrace'>}</span><span class='period'>.</span><span class='id identifier rubyid_to_h'>to_h</span>
|
230
|
+
<span class='kw'>when</span> <span class='const'>Array</span>
|
231
|
+
<span class='id identifier rubyid_obj'>obj</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_v'>v</span><span class='op'>|</span> <span class='id identifier rubyid_deep_stringify_keys'>deep_stringify_keys</span><span class='lparen'>(</span><span class='id identifier rubyid_v'>v</span><span class='rparen'>)</span> <span class='rbrace'>}</span>
|
232
|
+
<span class='kw'>else</span>
|
233
|
+
<span class='id identifier rubyid_obj'>obj</span>
|
234
|
+
<span class='kw'>end</span>
|
235
|
+
<span class='kw'>end</span></pre>
|
236
|
+
</td>
|
237
|
+
</tr>
|
238
|
+
</table>
|
239
|
+
</div>
|
240
|
+
|
241
|
+
<div class="method_details ">
|
242
|
+
<h3 class="signature " id="deep_symbolize_keys-class_method">
|
243
|
+
|
244
|
+
.<strong>deep_symbolize_keys</strong>(obj) ⇒ <tt>Object</tt>
|
245
|
+
|
246
|
+
|
247
|
+
|
248
|
+
|
249
|
+
|
250
|
+
</h3><table class="source_code">
|
251
|
+
<tr>
|
252
|
+
<td>
|
253
|
+
<pre class="lines">
|
254
|
+
|
255
|
+
|
256
|
+
3
|
257
|
+
4
|
258
|
+
5
|
259
|
+
6
|
260
|
+
7
|
261
|
+
8
|
262
|
+
9
|
263
|
+
10
|
264
|
+
11
|
265
|
+
12</pre>
|
266
|
+
</td>
|
267
|
+
<td>
|
268
|
+
<pre class="code"><span class="info file"># File 'lib/triglav/agent/hash_util.rb', line 3</span>
|
269
|
+
|
270
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_deep_symbolize_keys'>deep_symbolize_keys</span><span class='lparen'>(</span><span class='id identifier rubyid_obj'>obj</span><span class='rparen'>)</span>
|
271
|
+
<span class='kw'>case</span> <span class='id identifier rubyid_obj'>obj</span>
|
272
|
+
<span class='kw'>when</span> <span class='const'>Hash</span>
|
273
|
+
<span class='id identifier rubyid_obj'>obj</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_k'>k</span><span class='comma'>,</span> <span class='id identifier rubyid_v'>v</span><span class='op'>|</span> <span class='lbracket'>[</span><span class='id identifier rubyid_k'>k</span><span class='period'>.</span><span class='id identifier rubyid_to_sym'>to_sym</span><span class='comma'>,</span> <span class='id identifier rubyid_deep_symbolize_keys'>deep_symbolize_keys</span><span class='lparen'>(</span><span class='id identifier rubyid_v'>v</span><span class='rparen'>)</span><span class='rbracket'>]</span> <span class='rbrace'>}</span><span class='period'>.</span><span class='id identifier rubyid_to_h'>to_h</span>
|
274
|
+
<span class='kw'>when</span> <span class='const'>Array</span>
|
275
|
+
<span class='id identifier rubyid_obj'>obj</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_v'>v</span><span class='op'>|</span> <span class='id identifier rubyid_deep_symbolize_keys'>deep_symbolize_keys</span><span class='lparen'>(</span><span class='id identifier rubyid_v'>v</span><span class='rparen'>)</span> <span class='rbrace'>}</span>
|
276
|
+
<span class='kw'>else</span>
|
277
|
+
<span class='id identifier rubyid_obj'>obj</span>
|
278
|
+
<span class='kw'>end</span>
|
279
|
+
<span class='kw'>end</span></pre>
|
280
|
+
</td>
|
281
|
+
</tr>
|
282
|
+
</table>
|
283
|
+
</div>
|
284
|
+
|
285
|
+
<div class="method_details ">
|
286
|
+
<h3 class="signature " id="setdig-class_method">
|
287
|
+
|
288
|
+
.<strong>setdig</strong>(hash, key, val) ⇒ <tt>Object</tt>
|
289
|
+
|
290
|
+
|
291
|
+
|
292
|
+
|
293
|
+
|
294
|
+
</h3><div class="docstring">
|
295
|
+
<div class="discussion">
|
296
|
+
|
297
|
+
<p>HashUtil.setdig(hash, ['a', 'b'], 'bar') # like <a
|
298
|
+
href="'a'">hash</a>['b'] = 'bar'</p>
|
299
|
+
|
300
|
+
|
301
|
+
</div>
|
302
|
+
</div>
|
303
|
+
<div class="tags">
|
304
|
+
|
305
|
+
|
306
|
+
</div><table class="source_code">
|
307
|
+
<tr>
|
308
|
+
<td>
|
309
|
+
<pre class="lines">
|
310
|
+
|
311
|
+
|
312
|
+
26
|
313
|
+
27
|
314
|
+
28
|
315
|
+
29
|
316
|
+
30
|
317
|
+
31
|
318
|
+
32
|
319
|
+
33
|
320
|
+
34</pre>
|
321
|
+
</td>
|
322
|
+
<td>
|
323
|
+
<pre class="code"><span class="info file"># File 'lib/triglav/agent/hash_util.rb', line 26</span>
|
324
|
+
|
325
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_setdig'>setdig</span><span class='lparen'>(</span><span class='id identifier rubyid_hash'>hash</span><span class='comma'>,</span> <span class='id identifier rubyid_key'>key</span><span class='comma'>,</span> <span class='id identifier rubyid_val'>val</span><span class='rparen'>)</span>
|
326
|
+
<span class='id identifier rubyid_keys'>keys</span> <span class='op'>=</span> <span class='const'>Array</span><span class='lparen'>(</span><span class='id identifier rubyid_key'>key</span><span class='rparen'>)</span>
|
327
|
+
<span class='id identifier rubyid_sub_hash'>sub_hash</span> <span class='op'>=</span> <span class='id identifier rubyid_hash'>hash</span>
|
328
|
+
<span class='id identifier rubyid_keys'>keys</span><span class='lbracket'>[</span><span class='int'>0</span><span class='op'>...</span><span class='op'>-</span><span class='int'>1</span><span class='rbracket'>]</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_k'>k</span><span class='op'>|</span>
|
329
|
+
<span class='id identifier rubyid_sub_hash'>sub_hash</span> <span class='op'>=</span> <span class='lparen'>(</span><span class='id identifier rubyid_sub_hash'>sub_hash</span><span class='lbracket'>[</span><span class='id identifier rubyid_k'>k</span><span class='rbracket'>]</span> <span class='op'>||=</span> <span class='lbrace'>{</span><span class='rbrace'>}</span><span class='rparen'>)</span>
|
330
|
+
<span class='kw'>end</span>
|
331
|
+
<span class='id identifier rubyid_sub_hash'>sub_hash</span><span class='lbracket'>[</span><span class='id identifier rubyid_keys'>keys</span><span class='period'>.</span><span class='id identifier rubyid_last'>last</span><span class='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_val'>val</span>
|
332
|
+
<span class='id identifier rubyid_hash'>hash</span>
|
333
|
+
<span class='kw'>end</span></pre>
|
334
|
+
</td>
|
335
|
+
</tr>
|
336
|
+
</table>
|
337
|
+
</div>
|
338
|
+
|
339
|
+
</div>
|
340
|
+
|
341
|
+
</div>
|
342
|
+
|
343
|
+
<div id="footer">
|
344
|
+
Generated on Thu Feb 23 23:20:33 2017 by
|
345
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
346
|
+
0.9.5 (ruby-2.3.2).
|
347
|
+
</div>
|
348
|
+
|
349
|
+
</div>
|
350
|
+
</body>
|
351
|
+
</html>
|