grafana 0.8.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/LICENSE +21 -0
- data/README.md +36 -0
- data/doc/Array.html +200 -0
- data/doc/Boolean.html +122 -0
- data/doc/FalseClass.html +132 -0
- data/doc/Grafana.html +172 -0
- data/doc/Hash.html +212 -0
- data/doc/Logging.html +326 -0
- data/doc/Object.html +286 -0
- data/doc/Time.html +200 -0
- data/doc/TrueClass.html +132 -0
- data/doc/_index.html +380 -0
- data/doc/class_list.html +51 -0
- data/doc/file.README.html +117 -0
- data/doc/file_list.html +56 -0
- data/doc/frames.html +17 -0
- data/doc/index.html +117 -0
- data/doc/method_list.html +771 -0
- data/doc/top-level-namespace.html +112 -0
- data/lib/grafana.rb +7 -0
- data/lib/grafana/admin.rb +310 -0
- data/lib/grafana/alerts.rb +38 -0
- data/lib/grafana/annotations.rb +40 -0
- data/lib/grafana/client.rb +126 -0
- data/lib/grafana/dashboard.rb +149 -0
- data/lib/grafana/dashboard_versions.rb +30 -0
- data/lib/grafana/datasource.rb +271 -0
- data/lib/grafana/login.rb +139 -0
- data/lib/grafana/network.rb +169 -0
- data/lib/grafana/organization.rb +101 -0
- data/lib/grafana/organizations.rb +406 -0
- data/lib/grafana/snapshot.rb +47 -0
- data/lib/grafana/tags.rb +41 -0
- data/lib/grafana/tools.rb +66 -0
- data/lib/grafana/user.rb +116 -0
- data/lib/grafana/users.rb +122 -0
- data/lib/grafana/validator.rb +28 -0
- data/lib/grafana/version.rb +17 -0
- data/lib/logging.rb +35 -0
- data/lib/monkey_patches.rb +92 -0
- metadata +294 -0
data/doc/Object.html
ADDED
@@ -0,0 +1,286 @@
|
|
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: Object
|
8
|
+
|
9
|
+
— Documentation by YARD 0.9.11
|
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 = "Object";
|
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 (O)</a> »
|
40
|
+
|
41
|
+
|
42
|
+
<span class="title">Object</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: Object
|
63
|
+
|
64
|
+
|
65
|
+
|
66
|
+
</h1>
|
67
|
+
<div class="box_info">
|
68
|
+
|
69
|
+
<dl>
|
70
|
+
<dt>Inherits:</dt>
|
71
|
+
<dd>
|
72
|
+
<span class="inheritName">BasicObject</span>
|
73
|
+
|
74
|
+
</dd>
|
75
|
+
</dl>
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
|
82
|
+
|
83
|
+
|
84
|
+
|
85
|
+
|
86
|
+
|
87
|
+
<dl>
|
88
|
+
<dt>Defined in:</dt>
|
89
|
+
<dd>lib/monkey_patches.rb</dd>
|
90
|
+
</dl>
|
91
|
+
|
92
|
+
</div>
|
93
|
+
|
94
|
+
<h2>Overview</h2><div class="docstring">
|
95
|
+
<div class="discussion">
|
96
|
+
|
97
|
+
<p>None of the above solutions work with a multi-level hash They only work on
|
98
|
+
the first level: :level1=>{“level2”=>“baz”} The
|
99
|
+
following two variations solve the problem in the same way transform hash
|
100
|
+
keys to symbols multi_hash = { 'foo' => 'bar',
|
101
|
+
'level1' => { 'level2' => 'baz' } }
|
102
|
+
multi_hash = multi_hash.deep_string_keys</p>
|
103
|
+
|
104
|
+
|
105
|
+
</div>
|
106
|
+
</div>
|
107
|
+
<div class="tags">
|
108
|
+
|
109
|
+
|
110
|
+
</div>
|
111
|
+
|
112
|
+
|
113
|
+
|
114
|
+
|
115
|
+
|
116
|
+
|
117
|
+
|
118
|
+
<h2>
|
119
|
+
Instance Method Summary
|
120
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
121
|
+
</h2>
|
122
|
+
|
123
|
+
<ul class="summary">
|
124
|
+
|
125
|
+
<li class="public ">
|
126
|
+
<span class="summary_signature">
|
127
|
+
|
128
|
+
<a href="#deep_string_keys-instance_method" title="#deep_string_keys (instance method)">#<strong>deep_string_keys</strong> ⇒ Object </a>
|
129
|
+
|
130
|
+
|
131
|
+
|
132
|
+
</span>
|
133
|
+
|
134
|
+
|
135
|
+
|
136
|
+
|
137
|
+
|
138
|
+
|
139
|
+
|
140
|
+
|
141
|
+
|
142
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
143
|
+
|
144
|
+
</li>
|
145
|
+
|
146
|
+
|
147
|
+
<li class="public ">
|
148
|
+
<span class="summary_signature">
|
149
|
+
|
150
|
+
<a href="#deep_symbolize_keys-instance_method" title="#deep_symbolize_keys (instance method)">#<strong>deep_symbolize_keys</strong> ⇒ Object </a>
|
151
|
+
|
152
|
+
|
153
|
+
|
154
|
+
</span>
|
155
|
+
|
156
|
+
|
157
|
+
|
158
|
+
|
159
|
+
|
160
|
+
|
161
|
+
|
162
|
+
|
163
|
+
|
164
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
165
|
+
|
166
|
+
</li>
|
167
|
+
|
168
|
+
|
169
|
+
</ul>
|
170
|
+
|
171
|
+
|
172
|
+
|
173
|
+
|
174
|
+
<div id="instance_method_details" class="method_details_list">
|
175
|
+
<h2>Instance Method Details</h2>
|
176
|
+
|
177
|
+
|
178
|
+
<div class="method_details first">
|
179
|
+
<h3 class="signature first" id="deep_string_keys-instance_method">
|
180
|
+
|
181
|
+
#<strong>deep_string_keys</strong> ⇒ <tt><span class='object_link'><a href="" title="Object (class)">Object</a></span></tt>
|
182
|
+
|
183
|
+
|
184
|
+
|
185
|
+
|
186
|
+
|
187
|
+
</h3><table class="source_code">
|
188
|
+
<tr>
|
189
|
+
<td>
|
190
|
+
<pre class="lines">
|
191
|
+
|
192
|
+
|
193
|
+
29
|
194
|
+
30
|
195
|
+
31
|
196
|
+
32
|
197
|
+
33
|
198
|
+
34
|
199
|
+
35
|
200
|
+
36
|
201
|
+
37
|
202
|
+
38
|
203
|
+
39
|
204
|
+
40</pre>
|
205
|
+
</td>
|
206
|
+
<td>
|
207
|
+
<pre class="code"><span class="info file"># File 'lib/monkey_patches.rb', line 29</span>
|
208
|
+
|
209
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_deep_string_keys'>deep_string_keys</span>
|
210
|
+
|
211
|
+
<span class='kw'>if</span><span class='lparen'>(</span> <span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span> <span class='const'><span class='object_link'><a href="Hash.html" title="Hash (class)">Hash</a></span></span> <span class='rparen'>)</span> <span class='rparen'>)</span>
|
212
|
+
<span class='kw'>return</span> <span class='id identifier rubyid_inject'>inject</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='id identifier rubyid_memo'>memo</span><span class='comma'>,</span> <span class='lparen'>(</span><span class='id identifier rubyid_k'>k</span><span class='comma'>,</span> <span class='id identifier rubyid_v'>v</span><span class='rparen'>)</span><span class='op'>|</span>
|
213
|
+
<span class='id identifier rubyid_memo'>memo</span><span class='period'>.</span><span class='id identifier rubyid_tap'>tap</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_m'>m</span><span class='op'>|</span> <span class='id identifier rubyid_m'>m</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='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_v'>v</span><span class='period'>.</span><span class='id identifier rubyid_deep_string_keys'>deep_string_keys</span> <span class='rbrace'>}</span>
|
214
|
+
<span class='kw'>end</span>
|
215
|
+
<span class='kw'>elsif</span><span class='lparen'>(</span> <span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span> <span class='const'><span class='object_link'><a href="Array.html" title="Array (class)">Array</a></span></span> <span class='rparen'>)</span> <span class='rparen'>)</span>
|
216
|
+
<span class='kw'>return</span> <span class='id identifier rubyid_map'>map</span><span class='lparen'>(</span><span class='op'>&</span><span class='symbol'>:deep_string_keys</span><span class='rparen'>)</span>
|
217
|
+
<span class='kw'>end</span>
|
218
|
+
|
219
|
+
<span class='kw'>self</span>
|
220
|
+
<span class='kw'>end</span></pre>
|
221
|
+
</td>
|
222
|
+
</tr>
|
223
|
+
</table>
|
224
|
+
</div>
|
225
|
+
|
226
|
+
<div class="method_details ">
|
227
|
+
<h3 class="signature " id="deep_symbolize_keys-instance_method">
|
228
|
+
|
229
|
+
#<strong>deep_symbolize_keys</strong> ⇒ <tt><span class='object_link'><a href="" title="Object (class)">Object</a></span></tt>
|
230
|
+
|
231
|
+
|
232
|
+
|
233
|
+
|
234
|
+
|
235
|
+
</h3><table class="source_code">
|
236
|
+
<tr>
|
237
|
+
<td>
|
238
|
+
<pre class="lines">
|
239
|
+
|
240
|
+
|
241
|
+
16
|
242
|
+
17
|
243
|
+
18
|
244
|
+
19
|
245
|
+
20
|
246
|
+
21
|
247
|
+
22
|
248
|
+
23
|
249
|
+
24
|
250
|
+
25
|
251
|
+
26
|
252
|
+
27</pre>
|
253
|
+
</td>
|
254
|
+
<td>
|
255
|
+
<pre class="code"><span class="info file"># File 'lib/monkey_patches.rb', line 16</span>
|
256
|
+
|
257
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_deep_symbolize_keys'>deep_symbolize_keys</span>
|
258
|
+
|
259
|
+
<span class='kw'>if</span><span class='lparen'>(</span> <span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span> <span class='const'><span class='object_link'><a href="Hash.html" title="Hash (class)">Hash</a></span></span> <span class='rparen'>)</span> <span class='rparen'>)</span>
|
260
|
+
<span class='kw'>return</span> <span class='id identifier rubyid_inject'>inject</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='id identifier rubyid_memo'>memo</span><span class='comma'>,</span> <span class='lparen'>(</span><span class='id identifier rubyid_k'>k</span><span class='comma'>,</span> <span class='id identifier rubyid_v'>v</span><span class='rparen'>)</span><span class='op'>|</span>
|
261
|
+
<span class='id identifier rubyid_memo'>memo</span><span class='period'>.</span><span class='id identifier rubyid_tap'>tap</span> <span class='lbrace'>{</span> <span class='op'>|</span><span class='id identifier rubyid_m'>m</span><span class='op'>|</span> <span class='id identifier rubyid_m'>m</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='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_v'>v</span><span class='period'>.</span><span class='id identifier rubyid_deep_string_keys'>deep_string_keys</span> <span class='rbrace'>}</span>
|
262
|
+
<span class='kw'>end</span>
|
263
|
+
<span class='kw'>elsif</span><span class='lparen'>(</span> <span class='id identifier rubyid_is_a?'>is_a?</span><span class='lparen'>(</span> <span class='const'><span class='object_link'><a href="Array.html" title="Array (class)">Array</a></span></span> <span class='rparen'>)</span> <span class='rparen'>)</span>
|
264
|
+
<span class='kw'>return</span> <span class='id identifier rubyid_map'>map</span><span class='lparen'>(</span><span class='op'>&</span><span class='symbol'>:deep_string_keys</span><span class='rparen'>)</span>
|
265
|
+
<span class='kw'>end</span>
|
266
|
+
|
267
|
+
<span class='kw'>self</span>
|
268
|
+
<span class='kw'>end</span></pre>
|
269
|
+
</td>
|
270
|
+
</tr>
|
271
|
+
</table>
|
272
|
+
</div>
|
273
|
+
|
274
|
+
</div>
|
275
|
+
|
276
|
+
</div>
|
277
|
+
|
278
|
+
<div id="footer">
|
279
|
+
Generated on Sun Dec 10 16:07:39 2017 by
|
280
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
281
|
+
0.9.11 (ruby-2.2.8).
|
282
|
+
</div>
|
283
|
+
|
284
|
+
</div>
|
285
|
+
</body>
|
286
|
+
</html>
|
data/doc/Time.html
ADDED
@@ -0,0 +1,200 @@
|
|
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: Time
|
8
|
+
|
9
|
+
— Documentation by YARD 0.9.11
|
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 = "Time";
|
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 (T)</a> »
|
40
|
+
|
41
|
+
|
42
|
+
<span class="title">Time</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: Time
|
63
|
+
|
64
|
+
|
65
|
+
|
66
|
+
</h1>
|
67
|
+
<div class="box_info">
|
68
|
+
|
69
|
+
<dl>
|
70
|
+
<dt>Inherits:</dt>
|
71
|
+
<dd>
|
72
|
+
<span class="inheritName"><span class='object_link'><a href="Object.html" title="Object (class)">Object</a></span></span>
|
73
|
+
|
74
|
+
<ul class="fullTree">
|
75
|
+
<li><span class='object_link'><a href="Object.html" title="Object (class)">Object</a></span></li>
|
76
|
+
|
77
|
+
<li class="next">Time</li>
|
78
|
+
|
79
|
+
</ul>
|
80
|
+
<a href="#" class="inheritanceTree">show all</a>
|
81
|
+
|
82
|
+
</dd>
|
83
|
+
</dl>
|
84
|
+
|
85
|
+
|
86
|
+
|
87
|
+
|
88
|
+
|
89
|
+
|
90
|
+
|
91
|
+
|
92
|
+
|
93
|
+
|
94
|
+
|
95
|
+
<dl>
|
96
|
+
<dt>Defined in:</dt>
|
97
|
+
<dd>lib/monkey_patches.rb</dd>
|
98
|
+
</dl>
|
99
|
+
|
100
|
+
</div>
|
101
|
+
|
102
|
+
<h2>Overview</h2><div class="docstring">
|
103
|
+
<div class="discussion">
|
104
|
+
<hr>
|
105
|
+
|
106
|
+
|
107
|
+
</div>
|
108
|
+
</div>
|
109
|
+
<div class="tags">
|
110
|
+
|
111
|
+
|
112
|
+
</div>
|
113
|
+
|
114
|
+
|
115
|
+
|
116
|
+
|
117
|
+
|
118
|
+
|
119
|
+
|
120
|
+
<h2>
|
121
|
+
Instance Method Summary
|
122
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
123
|
+
</h2>
|
124
|
+
|
125
|
+
<ul class="summary">
|
126
|
+
|
127
|
+
<li class="public ">
|
128
|
+
<span class="summary_signature">
|
129
|
+
|
130
|
+
<a href="#add_minutes-instance_method" title="#add_minutes (instance method)">#<strong>add_minutes</strong>(m) ⇒ Object </a>
|
131
|
+
|
132
|
+
|
133
|
+
|
134
|
+
</span>
|
135
|
+
|
136
|
+
|
137
|
+
|
138
|
+
|
139
|
+
|
140
|
+
|
141
|
+
|
142
|
+
|
143
|
+
|
144
|
+
<span class="summary_desc"><div class='inline'></div></span>
|
145
|
+
|
146
|
+
</li>
|
147
|
+
|
148
|
+
|
149
|
+
</ul>
|
150
|
+
|
151
|
+
|
152
|
+
|
153
|
+
|
154
|
+
<div id="instance_method_details" class="method_details_list">
|
155
|
+
<h2>Instance Method Details</h2>
|
156
|
+
|
157
|
+
|
158
|
+
<div class="method_details first">
|
159
|
+
<h3 class="signature first" id="add_minutes-instance_method">
|
160
|
+
|
161
|
+
#<strong>add_minutes</strong>(m) ⇒ <tt><span class='object_link'><a href="Object.html" title="Object (class)">Object</a></span></tt>
|
162
|
+
|
163
|
+
|
164
|
+
|
165
|
+
|
166
|
+
|
167
|
+
</h3><table class="source_code">
|
168
|
+
<tr>
|
169
|
+
<td>
|
170
|
+
<pre class="lines">
|
171
|
+
|
172
|
+
|
173
|
+
73
|
174
|
+
74
|
175
|
+
75</pre>
|
176
|
+
</td>
|
177
|
+
<td>
|
178
|
+
<pre class="code"><span class="info file"># File 'lib/monkey_patches.rb', line 73</span>
|
179
|
+
|
180
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_add_minutes'>add_minutes</span><span class='lparen'>(</span><span class='id identifier rubyid_m'>m</span><span class='rparen'>)</span>
|
181
|
+
<span class='kw'>self</span> <span class='op'>+</span> <span class='lparen'>(</span><span class='int'>60</span> <span class='op'>*</span> <span class='id identifier rubyid_m'>m</span><span class='rparen'>)</span>
|
182
|
+
<span class='kw'>end</span></pre>
|
183
|
+
</td>
|
184
|
+
</tr>
|
185
|
+
</table>
|
186
|
+
</div>
|
187
|
+
|
188
|
+
</div>
|
189
|
+
|
190
|
+
</div>
|
191
|
+
|
192
|
+
<div id="footer">
|
193
|
+
Generated on Sun Dec 10 16:07:39 2017 by
|
194
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
195
|
+
0.9.11 (ruby-2.2.8).
|
196
|
+
</div>
|
197
|
+
|
198
|
+
</div>
|
199
|
+
</body>
|
200
|
+
</html>
|