mushikago-sdk 0.2.3 → 0.3.1
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.
- data/README.md +9 -6
- data/autotest/discover.rb +1 -0
- data/doc/Mushikago.html +37 -21
- data/doc/Mushikago/Auth.html +8 -4
- data/doc/Mushikago/Auth/Signature.html +59 -32
- data/doc/Mushikago/Auth/Signer.html +81 -44
- data/doc/Mushikago/Config.html +41 -18
- data/doc/Mushikago/Hotaru.html +120 -0
- data/doc/Mushikago/Hotaru/Client.html +818 -0
- data/doc/Mushikago/Hotaru/Request.html +303 -0
- data/doc/Mushikago/Http.html +10 -6
- data/doc/Mushikago/Http/Client.html +107 -58
- data/doc/Mushikago/Http/MultipartRequest.html +366 -0
- data/doc/Mushikago/Http/Request.html +289 -167
- data/doc/Mushikago/Http/Response.html +153 -70
- data/doc/Mushikago/Mitsubachi.html +108 -0
- data/doc/Mushikago/Mitsubachi/Client.html +2923 -0
- data/doc/Mushikago/Mitsubachi/HttpFetchRequest.html +363 -0
- data/doc/Mushikago/Mitsubachi/HttpPushRequest.html +365 -0
- data/doc/Mushikago/Mitsubachi/MultipartRequest.html +332 -0
- data/doc/Mushikago/Mitsubachi/ProjectCreateRequest.html +361 -0
- data/doc/Mushikago/Mitsubachi/ProjectDeleteRequest.html +351 -0
- data/doc/Mushikago/Mitsubachi/ProjectDiscontinueRequest.html +349 -0
- data/doc/Mushikago/Mitsubachi/ProjectInfoRequest.html +302 -0
- data/doc/Mushikago/Mitsubachi/ProjectListRequest.html +304 -0
- data/doc/Mushikago/Mitsubachi/ProjectQueuesRequest.html +300 -0
- data/doc/Mushikago/Mitsubachi/ProjectUpdateRequest.html +359 -0
- data/doc/Mushikago/Mitsubachi/Request.html +307 -0
- data/doc/Mushikago/Mitsubachi/ResourceDeleteRequest.html +351 -0
- data/doc/Mushikago/Mitsubachi/ResourceGetRequest.html +302 -0
- data/doc/Mushikago/Mitsubachi/ResourceListRequest.html +306 -0
- data/doc/Mushikago/Mitsubachi/ResourceStoreRequest.html +390 -0
- data/doc/Mushikago/Mitsubachi/ScriptDeleteRequest.html +351 -0
- data/doc/Mushikago/Mitsubachi/ScriptDeployRequest.html +386 -0
- data/doc/Mushikago/Mitsubachi/ScriptGetRequest.html +302 -0
- data/doc/Mushikago/Mitsubachi/ScriptListRequest.html +306 -0
- data/doc/Mushikago/Tombo.html +8 -4
- data/doc/Mushikago/Tombo/CaptureRequest.html +90 -34
- data/doc/Mushikago/Tombo/CapturesRequest.html +68 -27
- data/doc/Mushikago/Tombo/Client.html +181 -75
- data/doc/Mushikago/Tombo/DeleteRequest.html +44 -24
- data/doc/Mushikago/Tombo/InfoRequest.html +32 -16
- data/doc/Mushikago/Tombo/Request.html +45 -15
- data/doc/_index.html +192 -9
- data/doc/class_list.html +1 -1
- data/doc/css/full_list.css +2 -0
- data/doc/css/style.css +12 -10
- data/doc/file.README.html +66 -60
- data/doc/frames.html +1 -1
- data/doc/index.html +66 -60
- data/doc/js/app.js +4 -4
- data/doc/js/full_list.js +23 -6
- data/doc/method_list.html +622 -62
- data/doc/top-level-namespace.html +3 -3
- data/lib/mushikago-sdk.rb +1 -0
- data/lib/mushikago.rb +3 -0
- data/lib/mushikago/auth.rb +1 -0
- data/lib/mushikago/auth/signature.rb +1 -0
- data/lib/mushikago/auth/signer.rb +1 -0
- data/lib/mushikago/configuration.rb +3 -2
- data/lib/mushikago/hotaru.rb +22 -0
- data/lib/mushikago/hotaru/client.rb +76 -0
- data/lib/mushikago/hotaru/request.rb +32 -0
- data/lib/mushikago/http.rb +2 -0
- data/lib/mushikago/http/client.rb +2 -1
- data/lib/mushikago/http/multipart_request.rb +62 -0
- data/lib/mushikago/http/request.rb +5 -2
- data/lib/mushikago/http/response.rb +1 -0
- data/lib/mushikago/mitsubachi.rb +33 -0
- data/lib/mushikago/mitsubachi/client.rb +256 -0
- data/lib/mushikago/mitsubachi/http_fetch_request.rb +33 -0
- data/lib/mushikago/mitsubachi/http_push_request.rb +36 -0
- data/lib/mushikago/mitsubachi/multipart_request.rb +33 -0
- data/lib/mushikago/mitsubachi/project_create_request.rb +32 -0
- data/lib/mushikago/mitsubachi/project_delete_request.rb +23 -0
- data/lib/mushikago/mitsubachi/project_discontinue_request.rb +22 -0
- data/lib/mushikago/mitsubachi/project_info_request.rb +17 -0
- data/lib/mushikago/mitsubachi/project_list_request.rb +21 -0
- data/lib/mushikago/mitsubachi/project_queues_request.rb +16 -0
- data/lib/mushikago/mitsubachi/project_update_request.rb +31 -0
- data/lib/mushikago/mitsubachi/request.rb +32 -0
- data/lib/mushikago/mitsubachi/resource_delete_request.rb +24 -0
- data/lib/mushikago/mitsubachi/resource_get_request.rb +19 -0
- data/lib/mushikago/mitsubachi/resource_list_request.rb +22 -0
- data/lib/mushikago/mitsubachi/resource_store_request.rb +33 -0
- data/lib/mushikago/mitsubachi/script_delete_request.rb +23 -0
- data/lib/mushikago/mitsubachi/script_deploy_request.rb +28 -0
- data/lib/mushikago/mitsubachi/script_get_request.rb +18 -0
- data/lib/mushikago/mitsubachi/script_list_request.rb +21 -0
- data/lib/mushikago/tombo.rb +1 -0
- data/lib/mushikago/tombo/capture_request.rb +2 -1
- data/lib/mushikago/tombo/captures_request.rb +2 -1
- data/lib/mushikago/tombo/client.rb +1 -0
- data/lib/mushikago/tombo/delete_request.rb +2 -1
- data/lib/mushikago/tombo/info_request.rb +2 -1
- data/lib/mushikago/tombo/request.rb +3 -2
- data/lib/mushikago/version.rb +2 -1
- data/spec/mushikago/auth/signature_spec.rb +1 -0
- data/spec/mushikago/auth/signer_spec.rb +1 -0
- data/spec/mushikago/configuration_spec.rb +7 -6
- data/spec/mushikago/http/client_spec.rb +3 -2
- data/spec/mushikago/http/request_spec.rb +3 -1
- data/spec/mushikago/http/response_spec.rb +1 -0
- data/spec/mushikago/tombo/capture_request_spec.rb +3 -2
- data/spec/mushikago/tombo/captures_request_spec.rb +3 -2
- data/spec/mushikago/tombo/client_spec.rb +91 -32
- data/spec/mushikago/tombo/delete_request_spec.rb +3 -2
- data/spec/mushikago/tombo/info_request_spec.rb +3 -2
- data/spec/mushikago/tombo/request_spec.rb +2 -1
- data/spec/spec_helper.rb +1 -0
- metadata +136 -115
data/doc/Mushikago/Config.html
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
<title>
|
|
7
7
|
Class: Mushikago::Config
|
|
8
8
|
|
|
9
|
-
— Documentation by YARD 0.7.
|
|
9
|
+
— Documentation by YARD 0.7.4
|
|
10
10
|
|
|
11
11
|
</title>
|
|
12
12
|
|
|
@@ -98,12 +98,16 @@
|
|
|
98
98
|
|
|
99
99
|
<h2>Overview</h2><div class="docstring">
|
|
100
100
|
<div class="discussion">
|
|
101
|
-
<p>
|
|
101
|
+
<p>
|
|
102
|
+
Mushikago SDK for Rubyの各設定
|
|
103
|
+
</p>
|
|
104
|
+
|
|
102
105
|
|
|
103
106
|
</div>
|
|
104
107
|
</div>
|
|
105
108
|
<div class="tags">
|
|
106
109
|
|
|
110
|
+
|
|
107
111
|
</div>
|
|
108
112
|
|
|
109
113
|
|
|
@@ -169,8 +173,7 @@
|
|
|
169
173
|
<h3>Examples:</h3>
|
|
170
174
|
|
|
171
175
|
<h4><div class='inline'></div></h4>
|
|
172
|
-
<pre class="example code"><span class='
|
|
173
|
-
</pre>
|
|
176
|
+
<pre class="example code"><span class='const'>Mushikago</span><span class='period'>.</span><span class='id identifier rubyid_config'>config</span><span class='period'>.</span><span class='id identifier rubyid_load'>load</span><span class='lparen'>(</span><span class='symbol'>:api_key</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>ABCDEFG</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:secret_key</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>HIJKLMN</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span></pre>
|
|
174
177
|
|
|
175
178
|
</div>
|
|
176
179
|
<h3>Parameters:</h3>
|
|
@@ -188,7 +191,10 @@
|
|
|
188
191
|
|
|
189
192
|
|
|
190
193
|
—
|
|
191
|
-
<div class='inline'><p>
|
|
194
|
+
<div class='inline'><p>
|
|
195
|
+
optionsをロードします
|
|
196
|
+
</p>
|
|
197
|
+
</div>
|
|
192
198
|
|
|
193
199
|
</li>
|
|
194
200
|
|
|
@@ -206,8 +212,11 @@
|
|
|
206
212
|
<span class="default">
|
|
207
213
|
|
|
208
214
|
</span>
|
|
209
|
-
— <div class='inline'><p
|
|
210
|
-
|
|
215
|
+
— <div class='inline'><p>
|
|
216
|
+
発行されたAPIKeyを設定する
|
|
217
|
+
</p>
|
|
218
|
+
</div>
|
|
219
|
+
</li>
|
|
211
220
|
|
|
212
221
|
<li>
|
|
213
222
|
<span class="name">:secret_key(ENV['MUSHIKAGO_SECRET_KEY'])</span>
|
|
@@ -215,34 +224,48 @@
|
|
|
215
224
|
<span class="default">
|
|
216
225
|
|
|
217
226
|
</span>
|
|
218
|
-
— <div class='inline'><p
|
|
219
|
-
|
|
227
|
+
— <div class='inline'><p>
|
|
228
|
+
発行されたSecretKeyを設定する
|
|
229
|
+
</p>
|
|
230
|
+
</div>
|
|
231
|
+
</li>
|
|
220
232
|
|
|
221
233
|
<li>
|
|
222
|
-
<span class="name">:
|
|
234
|
+
<span class="name">:endpoint('api.mushikago.org')</span>
|
|
223
235
|
<span class="type">(<tt>String</tt>)</span>
|
|
224
236
|
<span class="default">
|
|
225
237
|
|
|
226
238
|
</span>
|
|
227
|
-
— <div class='inline'><p>
|
|
228
|
-
|
|
239
|
+
— <div class='inline'><p>
|
|
240
|
+
標準のエンドポイントを設定する
|
|
241
|
+
</p>
|
|
242
|
+
</div>
|
|
243
|
+
</li>
|
|
229
244
|
|
|
230
245
|
</ul>
|
|
231
246
|
|
|
232
247
|
|
|
248
|
+
|
|
233
249
|
</div><table class="source_code">
|
|
234
250
|
<tr>
|
|
235
251
|
<td>
|
|
236
252
|
<pre class="lines">
|
|
237
253
|
|
|
238
254
|
|
|
239
|
-
|
|
255
|
+
14
|
|
256
|
+
15
|
|
257
|
+
16
|
|
258
|
+
17
|
|
259
|
+
18</pre>
|
|
240
260
|
</td>
|
|
241
261
|
<td>
|
|
242
|
-
<pre class="code"><span class="info file"># File 'lib/mushikago/configuration.rb', line
|
|
262
|
+
<pre class="code"><span class="info file"># File 'lib/mushikago/configuration.rb', line 14</span>
|
|
243
263
|
|
|
244
|
-
<span class='
|
|
245
|
-
</
|
|
264
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_load'>load</span> <span class='id identifier rubyid_options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span>
|
|
265
|
+
<span class='id identifier rubyid_options'>options</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_key'>key</span><span class='comma'>,</span> <span class='id identifier rubyid_value'>value</span><span class='op'>|</span>
|
|
266
|
+
<span class='id identifier rubyid_supplied'>supplied</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='rbracket'>]</span> <span class='op'>=</span> <span class='id identifier rubyid_value'>value</span>
|
|
267
|
+
<span class='kw'>end</span>
|
|
268
|
+
<span class='kw'>end</span></pre>
|
|
246
269
|
</td>
|
|
247
270
|
</tr>
|
|
248
271
|
</table>
|
|
@@ -253,9 +276,9 @@
|
|
|
253
276
|
</div>
|
|
254
277
|
|
|
255
278
|
<div id="footer">
|
|
256
|
-
Generated on Thu
|
|
279
|
+
Generated on Thu Jan 26 17:19:02 2012 by
|
|
257
280
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
258
|
-
0.7.
|
|
281
|
+
0.7.4 (ruby-1.9.2).
|
|
259
282
|
</div>
|
|
260
283
|
|
|
261
284
|
</body>
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
2
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
3
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
|
4
|
+
<head>
|
|
5
|
+
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
|
6
|
+
<title>
|
|
7
|
+
Module: Mushikago::Hotaru
|
|
8
|
+
|
|
9
|
+
— Documentation by YARD 0.7.4
|
|
10
|
+
|
|
11
|
+
</title>
|
|
12
|
+
|
|
13
|
+
<link rel="stylesheet" href="../css/style.css" type="text/css" media="screen" charset="utf-8" />
|
|
14
|
+
|
|
15
|
+
<link rel="stylesheet" href="../css/common.css" type="text/css" media="screen" charset="utf-8" />
|
|
16
|
+
|
|
17
|
+
<script type="text/javascript" charset="utf-8">
|
|
18
|
+
relpath = '..';
|
|
19
|
+
if (relpath != '') relpath += '/';
|
|
20
|
+
</script>
|
|
21
|
+
|
|
22
|
+
<script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
|
|
23
|
+
|
|
24
|
+
<script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
</head>
|
|
28
|
+
<body>
|
|
29
|
+
<script type="text/javascript" charset="utf-8">
|
|
30
|
+
if (window.top.frames.main) document.body.className = 'frames';
|
|
31
|
+
</script>
|
|
32
|
+
|
|
33
|
+
<div id="header">
|
|
34
|
+
<div id="menu">
|
|
35
|
+
|
|
36
|
+
<a href="../_index.html">Index (H)</a> »
|
|
37
|
+
<span class='title'><span class='object_link'><a href="../Mushikago.html" title="Mushikago (module)">Mushikago</a></span></span>
|
|
38
|
+
»
|
|
39
|
+
<span class="title">Hotaru</span>
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
<div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
|
|
43
|
+
</div>
|
|
44
|
+
|
|
45
|
+
<div id="search">
|
|
46
|
+
|
|
47
|
+
<a id="class_list_link" href="#">Class List</a>
|
|
48
|
+
|
|
49
|
+
<a id="method_list_link" href="#">Method List</a>
|
|
50
|
+
|
|
51
|
+
<a id="file_list_link" href="#">File List</a>
|
|
52
|
+
|
|
53
|
+
</div>
|
|
54
|
+
<div class="clear"></div>
|
|
55
|
+
</div>
|
|
56
|
+
|
|
57
|
+
<iframe id="search_frame"></iframe>
|
|
58
|
+
|
|
59
|
+
<div id="content"><h1>Module: Mushikago::Hotaru
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
</h1>
|
|
64
|
+
|
|
65
|
+
<dl class="box">
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
<dt class="r1 last">Defined in:</dt>
|
|
75
|
+
<dd class="r1 last">lib/mushikago/hotaru.rb<span class="defines">,<br />
|
|
76
|
+
lib/mushikago/hotaru/client.rb,<br /> lib/mushikago/hotaru/request.rb</span>
|
|
77
|
+
</dd>
|
|
78
|
+
|
|
79
|
+
</dl>
|
|
80
|
+
<div class="clear"></div>
|
|
81
|
+
|
|
82
|
+
<h2>Overview</h2><div class="docstring">
|
|
83
|
+
<div class="discussion">
|
|
84
|
+
<p>
|
|
85
|
+
Hotaruへのアクセスを行うモジュール
|
|
86
|
+
</p>
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
</div>
|
|
90
|
+
</div>
|
|
91
|
+
<div class="tags">
|
|
92
|
+
|
|
93
|
+
|
|
94
|
+
</div><h2>Defined Under Namespace</h2>
|
|
95
|
+
<p class="children">
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
<strong class="classes">Classes:</strong> <span class='object_link'><a href="Hotaru/Client.html" title="Mushikago::Hotaru::Client (class)">Client</a></span>, <span class='object_link'><a href="Hotaru/Request.html" title="Mushikago::Hotaru::Request (class)">Request</a></span>
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
</p>
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
|
|
110
|
+
|
|
111
|
+
</div>
|
|
112
|
+
|
|
113
|
+
<div id="footer">
|
|
114
|
+
Generated on Thu Jan 26 17:19:02 2012 by
|
|
115
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
116
|
+
0.7.4 (ruby-1.9.2).
|
|
117
|
+
</div>
|
|
118
|
+
|
|
119
|
+
</body>
|
|
120
|
+
</html>
|
|
@@ -0,0 +1,818 @@
|
|
|
1
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
2
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
3
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
|
4
|
+
<head>
|
|
5
|
+
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
|
6
|
+
<title>
|
|
7
|
+
Class: Mushikago::Hotaru::Client
|
|
8
|
+
|
|
9
|
+
— Documentation by YARD 0.7.4
|
|
10
|
+
|
|
11
|
+
</title>
|
|
12
|
+
|
|
13
|
+
<link rel="stylesheet" href="../../css/style.css" type="text/css" media="screen" charset="utf-8" />
|
|
14
|
+
|
|
15
|
+
<link rel="stylesheet" href="../../css/common.css" type="text/css" media="screen" charset="utf-8" />
|
|
16
|
+
|
|
17
|
+
<script type="text/javascript" charset="utf-8">
|
|
18
|
+
relpath = '../..';
|
|
19
|
+
if (relpath != '') relpath += '/';
|
|
20
|
+
</script>
|
|
21
|
+
|
|
22
|
+
<script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
|
|
23
|
+
|
|
24
|
+
<script type="text/javascript" charset="utf-8" src="../../js/app.js"></script>
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
</head>
|
|
28
|
+
<body>
|
|
29
|
+
<script type="text/javascript" charset="utf-8">
|
|
30
|
+
if (window.top.frames.main) document.body.className = 'frames';
|
|
31
|
+
</script>
|
|
32
|
+
|
|
33
|
+
<div id="header">
|
|
34
|
+
<div id="menu">
|
|
35
|
+
|
|
36
|
+
<a href="../../_index.html">Index (C)</a> »
|
|
37
|
+
<span class='title'><span class='object_link'><a href="../../Mushikago.html" title="Mushikago (module)">Mushikago</a></span></span> » <span class='title'><span class='object_link'><a href="../Hotaru.html" title="Mushikago::Hotaru (module)">Hotaru</a></span></span>
|
|
38
|
+
»
|
|
39
|
+
<span class="title">Client</span>
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
<div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
|
|
43
|
+
</div>
|
|
44
|
+
|
|
45
|
+
<div id="search">
|
|
46
|
+
|
|
47
|
+
<a id="class_list_link" href="#">Class List</a>
|
|
48
|
+
|
|
49
|
+
<a id="method_list_link" href="#">Method List</a>
|
|
50
|
+
|
|
51
|
+
<a id="file_list_link" href="#">File List</a>
|
|
52
|
+
|
|
53
|
+
</div>
|
|
54
|
+
<div class="clear"></div>
|
|
55
|
+
</div>
|
|
56
|
+
|
|
57
|
+
<iframe id="search_frame"></iframe>
|
|
58
|
+
|
|
59
|
+
<div id="content"><h1>Class: Mushikago::Hotaru::Client
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
</h1>
|
|
64
|
+
|
|
65
|
+
<dl class="box">
|
|
66
|
+
|
|
67
|
+
<dt class="r1">Inherits:</dt>
|
|
68
|
+
<dd class="r1">
|
|
69
|
+
<span class="inheritName"><span class='object_link'><a href="../Http/Client.html" title="Mushikago::Http::Client (class)">Mushikago::Http::Client</a></span></span>
|
|
70
|
+
|
|
71
|
+
<ul class="fullTree">
|
|
72
|
+
<li>Object</li>
|
|
73
|
+
|
|
74
|
+
<li class="next"><span class='object_link'><a href="../Http/Client.html" title="Mushikago::Http::Client (class)">Mushikago::Http::Client</a></span></li>
|
|
75
|
+
|
|
76
|
+
<li class="next">Mushikago::Hotaru::Client</li>
|
|
77
|
+
|
|
78
|
+
</ul>
|
|
79
|
+
<a href="#" class="inheritanceTree">show all</a>
|
|
80
|
+
|
|
81
|
+
</dd>
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
<dt class="r2 last">Defined in:</dt>
|
|
92
|
+
<dd class="r2 last">lib/mushikago/hotaru/client.rb</dd>
|
|
93
|
+
|
|
94
|
+
</dl>
|
|
95
|
+
<div class="clear"></div>
|
|
96
|
+
|
|
97
|
+
<h2>Overview</h2><div class="docstring">
|
|
98
|
+
<div class="discussion">
|
|
99
|
+
<p>
|
|
100
|
+
Hotaruサービスを利用する
|
|
101
|
+
</p>
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
</div>
|
|
105
|
+
</div>
|
|
106
|
+
<div class="tags">
|
|
107
|
+
|
|
108
|
+
<div class="examples">
|
|
109
|
+
<h3>Examples:</h3>
|
|
110
|
+
|
|
111
|
+
<h4><div class='inline'></div></h4>
|
|
112
|
+
<pre class="example code"><span class='id identifier rubyid_client'>client</span> <span class='op'>=</span> <span class='const'>Mushikago</span><span class='op'>::</span><span class='const'>Hotaru</span><span class='op'>::</span><span class='const'>Client</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='symbol'>:api_key</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'><api_key></span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:secret_key</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'><secret_key></span><span class='tstring_end'>'</span></span><span class='rparen'>)</span>
|
|
113
|
+
|
|
114
|
+
<span class='id identifier rubyid_client'>client</span><span class='period'>.</span><span class='id identifier rubyid_capture'>capture</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>http://www.hotaru.ne.jp/</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:thumbnail</span> <span class='op'>=></span> <span class='kw'>true</span><span class='comma'>,</span> <span class='symbol'>:tags</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>hotaru</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>webservice</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span><span class='rparen'>)</span>
|
|
115
|
+
|
|
116
|
+
<span class='id identifier rubyid_captures'>captures</span> <span class='op'>=</span> <span class='id identifier rubyid_client'>client</span><span class='period'>.</span><span class='id identifier rubyid_captures'>captures</span>
|
|
117
|
+
<span class='id identifier rubyid_captures'>captures</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>images</span><span class='tstring_end'>'</span></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_image'>image</span><span class='op'>|</span>
|
|
118
|
+
<span class='id identifier rubyid_puts'>puts</span> <span class='id identifier rubyid_image'>image</span><span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>image_url</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span>
|
|
119
|
+
<span class='kw'>end</span></pre>
|
|
120
|
+
|
|
121
|
+
<h4><div class='inline'><p>
|
|
122
|
+
APIキーをファイルから読み込む場合
|
|
123
|
+
</p>
|
|
124
|
+
</div></h4>
|
|
125
|
+
<pre class="example code"><span class='const'>Mushikago</span><span class='period'>.</span><span class='id identifier rubyid_config'>config</span><span class='period'>.</span><span class='id identifier rubyid_load'>load</span><span class='lparen'>(</span><span class='const'>YAML</span><span class='period'>.</span><span class='id identifier rubyid_load'>load</span><span class='lparen'>(</span><span class='const'>File</span><span class='period'>.</span><span class='id identifier rubyid_read'>read</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>config.yml</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span><span class='rparen'>)</span><span class='rparen'>)</span>
|
|
126
|
+
<span class='id identifier rubyid_client'>client</span> <span class='op'>=</span> <span class='const'>Mushikago</span><span class='op'>::</span><span class='const'>Hotaru</span><span class='op'>::</span><span class='const'>Client</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span></pre>
|
|
127
|
+
|
|
128
|
+
</div>
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
</div>
|
|
132
|
+
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
<h2>Instance Attribute Summary</h2>
|
|
143
|
+
|
|
144
|
+
<h3 class="inherited">Attributes inherited from <span class='object_link'><a href="../Http/Client.html" title="Mushikago::Http::Client (class)">Mushikago::Http::Client</a></span></h3>
|
|
145
|
+
<p class="inherited"><span class='object_link'><a href="../Http/Client.html#api_key-instance_method" title="Mushikago::Http::Client#api_key (method)">api_key</a></span>, <span class='object_link'><a href="../Http/Client.html#signer-instance_method" title="Mushikago::Http::Client#signer (method)">signer</a></span></p>
|
|
146
|
+
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
<h2>
|
|
150
|
+
Instance Method Summary
|
|
151
|
+
<small>(<a href="#" class="summary_toggle">collapse</a>)</small>
|
|
152
|
+
</h2>
|
|
153
|
+
|
|
154
|
+
<ul class="summary">
|
|
155
|
+
|
|
156
|
+
<li class="public ">
|
|
157
|
+
<span class="summary_signature">
|
|
158
|
+
|
|
159
|
+
<a href="#capture-instance_method" title="#capture (instance method)">- (Mushikago::Http::Response) <strong>capture</strong>(url, options = {}) </a>
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
|
|
163
|
+
</span>
|
|
164
|
+
|
|
165
|
+
|
|
166
|
+
|
|
167
|
+
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
|
|
171
|
+
|
|
172
|
+
<span class="summary_desc"><div class='inline'><p>
|
|
173
|
+
指定したURLのキャプチャを取得する.
|
|
174
|
+
</p>
|
|
175
|
+
</div></span>
|
|
176
|
+
|
|
177
|
+
</li>
|
|
178
|
+
|
|
179
|
+
|
|
180
|
+
<li class="public ">
|
|
181
|
+
<span class="summary_signature">
|
|
182
|
+
|
|
183
|
+
<a href="#captures-instance_method" title="#captures (instance method)">- (Mushikago::Http::Response) <strong>captures</strong>(options = {}) </a>
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
|
|
187
|
+
</span>
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
|
|
193
|
+
|
|
194
|
+
|
|
195
|
+
|
|
196
|
+
<span class="summary_desc"><div class='inline'><p>
|
|
197
|
+
いままでキャプチャした画像の情報を取得する.
|
|
198
|
+
</p>
|
|
199
|
+
</div></span>
|
|
200
|
+
|
|
201
|
+
</li>
|
|
202
|
+
|
|
203
|
+
|
|
204
|
+
<li class="public ">
|
|
205
|
+
<span class="summary_signature">
|
|
206
|
+
|
|
207
|
+
<a href="#delete-instance_method" title="#delete (instance method)">- (Mushikago::Http::Response) <strong>delete</strong>(id, options = {}) </a>
|
|
208
|
+
|
|
209
|
+
|
|
210
|
+
|
|
211
|
+
</span>
|
|
212
|
+
|
|
213
|
+
|
|
214
|
+
|
|
215
|
+
|
|
216
|
+
|
|
217
|
+
|
|
218
|
+
|
|
219
|
+
|
|
220
|
+
<span class="summary_desc"><div class='inline'><p>
|
|
221
|
+
指定した画像を削除する.
|
|
222
|
+
</p>
|
|
223
|
+
</div></span>
|
|
224
|
+
|
|
225
|
+
</li>
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
<li class="public ">
|
|
229
|
+
<span class="summary_signature">
|
|
230
|
+
|
|
231
|
+
<a href="#info-instance_method" title="#info (instance method)">- (Mushikago::Http::Response) <strong>info</strong>(options = {}) </a>
|
|
232
|
+
|
|
233
|
+
|
|
234
|
+
|
|
235
|
+
</span>
|
|
236
|
+
|
|
237
|
+
|
|
238
|
+
|
|
239
|
+
|
|
240
|
+
|
|
241
|
+
|
|
242
|
+
|
|
243
|
+
|
|
244
|
+
<span class="summary_desc"><div class='inline'><p>
|
|
245
|
+
APIの使用状況を取得する.
|
|
246
|
+
</p>
|
|
247
|
+
</div></span>
|
|
248
|
+
|
|
249
|
+
</li>
|
|
250
|
+
|
|
251
|
+
|
|
252
|
+
</ul>
|
|
253
|
+
|
|
254
|
+
|
|
255
|
+
|
|
256
|
+
|
|
257
|
+
|
|
258
|
+
|
|
259
|
+
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
|
|
263
|
+
<h3 class="inherited">Methods inherited from <span class='object_link'><a href="../Http/Client.html" title="Mushikago::Http::Client (class)">Mushikago::Http::Client</a></span></h3>
|
|
264
|
+
<p class="inherited"><span class='object_link'><a href="../Http/Client.html#initialize-instance_method" title="Mushikago::Http::Client#initialize (method)">#initialize</a></span>, <span class='object_link'><a href="../Http/Client.html#send_request-instance_method" title="Mushikago::Http::Client#send_request (method)">#send_request</a></span></p>
|
|
265
|
+
<div id="constructor_details" class="method_details_list">
|
|
266
|
+
<h2>Constructor Details</h2>
|
|
267
|
+
|
|
268
|
+
<p class="notice">This class inherits a constructor from <span class='object_link'><a href="../Http/Client.html#initialize-instance_method" title="Mushikago::Http::Client#initialize (method)">Mushikago::Http::Client</a></span></p>
|
|
269
|
+
|
|
270
|
+
</div>
|
|
271
|
+
|
|
272
|
+
|
|
273
|
+
<div id="instance_method_details" class="method_details_list">
|
|
274
|
+
<h2>Instance Method Details</h2>
|
|
275
|
+
|
|
276
|
+
|
|
277
|
+
<div class="method_details first">
|
|
278
|
+
<p class="signature first" id="capture-instance_method">
|
|
279
|
+
|
|
280
|
+
- (<tt><span class='object_link'><a href="../Http/Response.html" title="Mushikago::Http::Response (class)">Mushikago::Http::Response</a></span></tt>) <strong>capture</strong>(url, options = {})
|
|
281
|
+
|
|
282
|
+
|
|
283
|
+
|
|
284
|
+
</p><div class="docstring">
|
|
285
|
+
<div class="discussion">
|
|
286
|
+
<p>
|
|
287
|
+
指定したURLのキャプチャを取得する
|
|
288
|
+
</p>
|
|
289
|
+
|
|
290
|
+
|
|
291
|
+
</div>
|
|
292
|
+
</div>
|
|
293
|
+
<div class="tags">
|
|
294
|
+
|
|
295
|
+
<div class="examples">
|
|
296
|
+
<h3>Examples:</h3>
|
|
297
|
+
|
|
298
|
+
<h4><div class='inline'></div></h4>
|
|
299
|
+
<pre class="example code"><span class='id identifier rubyid_client'>client</span><span class='period'>.</span><span class='id identifier rubyid_capture'>capture</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>http://www.hotaru.ne.jp/</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='symbol'>:thumbnail</span> <span class='op'>=></span> <span class='kw'>true</span><span class='comma'>,</span> <span class='symbol'>:tags</span> <span class='op'>=></span> <span class='lbracket'>[</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>hotaru</span><span class='tstring_end'>'</span></span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>webservice</span><span class='tstring_end'>'</span></span><span class='rbracket'>]</span><span class='rparen'>)</span></pre>
|
|
300
|
+
|
|
301
|
+
</div>
|
|
302
|
+
<h3>Parameters:</h3>
|
|
303
|
+
<ul class="param">
|
|
304
|
+
|
|
305
|
+
<li>
|
|
306
|
+
|
|
307
|
+
<span class='name'>url</span>
|
|
308
|
+
|
|
309
|
+
|
|
310
|
+
<span class='type'>(<tt>String</tt>)</span>
|
|
311
|
+
|
|
312
|
+
|
|
313
|
+
|
|
314
|
+
—
|
|
315
|
+
<div class='inline'><p>
|
|
316
|
+
キャプチャ対象のURL
|
|
317
|
+
</p>
|
|
318
|
+
</div>
|
|
319
|
+
|
|
320
|
+
</li>
|
|
321
|
+
|
|
322
|
+
<li>
|
|
323
|
+
|
|
324
|
+
<span class='name'>options</span>
|
|
325
|
+
|
|
326
|
+
|
|
327
|
+
<span class='type'>(<tt>Hash</tt>)</span>
|
|
328
|
+
|
|
329
|
+
|
|
330
|
+
<em class="default">(defaults to: <tt>{}</tt>)</em>
|
|
331
|
+
|
|
332
|
+
|
|
333
|
+
—
|
|
334
|
+
<div class='inline'><p>
|
|
335
|
+
リクエストのオプション
|
|
336
|
+
</p>
|
|
337
|
+
</div>
|
|
338
|
+
|
|
339
|
+
</li>
|
|
340
|
+
|
|
341
|
+
</ul>
|
|
342
|
+
|
|
343
|
+
|
|
344
|
+
|
|
345
|
+
|
|
346
|
+
|
|
347
|
+
|
|
348
|
+
<h3>Options Hash (<tt>options</tt>):</h3>
|
|
349
|
+
<ul class="option">
|
|
350
|
+
|
|
351
|
+
<li>
|
|
352
|
+
<span class="name">:image_format('jpg')</span>
|
|
353
|
+
<span class="type">(<tt>String</tt>)</span>
|
|
354
|
+
<span class="default">
|
|
355
|
+
|
|
356
|
+
</span>
|
|
357
|
+
— <div class='inline'><p>
|
|
358
|
+
画像のフォーマット(jpg,png)
|
|
359
|
+
</p>
|
|
360
|
+
</div>
|
|
361
|
+
</li>
|
|
362
|
+
|
|
363
|
+
<li>
|
|
364
|
+
<span class="name">:image_quality(80)</span>
|
|
365
|
+
<span class="type">(<tt>Integer</tt>)</span>
|
|
366
|
+
<span class="default">
|
|
367
|
+
|
|
368
|
+
</span>
|
|
369
|
+
— <div class='inline'><p>
|
|
370
|
+
画像の品質(0-100)
|
|
371
|
+
</p>
|
|
372
|
+
</div>
|
|
373
|
+
</li>
|
|
374
|
+
|
|
375
|
+
<li>
|
|
376
|
+
<span class="name">:thumbnail(0)</span>
|
|
377
|
+
<span class="type">(<tt>Boolean</tt>)</span>
|
|
378
|
+
<span class="default">
|
|
379
|
+
|
|
380
|
+
</span>
|
|
381
|
+
— <div class='inline'><p>
|
|
382
|
+
サムネイル取得フラグ(false:取得しない,true:取得する)
|
|
383
|
+
</p>
|
|
384
|
+
</div>
|
|
385
|
+
</li>
|
|
386
|
+
|
|
387
|
+
<li>
|
|
388
|
+
<span class="name">:tags</span>
|
|
389
|
+
<span class="type">(<tt>String</tt>, <tt>Array</tt>)</span>
|
|
390
|
+
<span class="default">
|
|
391
|
+
|
|
392
|
+
</span>
|
|
393
|
+
— <div class='inline'><p>
|
|
394
|
+
タグ
|
|
395
|
+
</p>
|
|
396
|
+
</div>
|
|
397
|
+
</li>
|
|
398
|
+
|
|
399
|
+
</ul>
|
|
400
|
+
|
|
401
|
+
|
|
402
|
+
<h3>Returns:</h3>
|
|
403
|
+
<ul class="return">
|
|
404
|
+
|
|
405
|
+
<li>
|
|
406
|
+
|
|
407
|
+
|
|
408
|
+
<span class='type'>(<tt><span class='object_link'><a href="../Http/Response.html" title="Mushikago::Http::Response (class)">Mushikago::Http::Response</a></span></tt>)</span>
|
|
409
|
+
|
|
410
|
+
|
|
411
|
+
|
|
412
|
+
—
|
|
413
|
+
<div class='inline'><p>
|
|
414
|
+
リクエストの結果
|
|
415
|
+
</p>
|
|
416
|
+
</div>
|
|
417
|
+
|
|
418
|
+
</li>
|
|
419
|
+
|
|
420
|
+
</ul>
|
|
421
|
+
|
|
422
|
+
</div><table class="source_code">
|
|
423
|
+
<tr>
|
|
424
|
+
<td>
|
|
425
|
+
<pre class="lines">
|
|
426
|
+
|
|
427
|
+
|
|
428
|
+
31
|
|
429
|
+
32
|
|
430
|
+
33
|
|
431
|
+
34</pre>
|
|
432
|
+
</td>
|
|
433
|
+
<td>
|
|
434
|
+
<pre class="code"><span class="info file"># File 'lib/mushikago/hotaru/client.rb', line 31</span>
|
|
435
|
+
|
|
436
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_capture'>capture</span> <span class='id identifier rubyid_url'>url</span><span class='comma'>,</span> <span class='id identifier rubyid_options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span>
|
|
437
|
+
<span class='id identifier rubyid_request'>request</span> <span class='op'>=</span> <span class='const'>CaptureRequest</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_url'>url</span><span class='comma'>,</span> <span class='id identifier rubyid_options'>options</span><span class='rparen'>)</span>
|
|
438
|
+
<span class='id identifier rubyid_send_request'>send_request</span><span class='lparen'>(</span><span class='id identifier rubyid_request'>request</span><span class='rparen'>)</span>
|
|
439
|
+
<span class='kw'>end</span></pre>
|
|
440
|
+
</td>
|
|
441
|
+
</tr>
|
|
442
|
+
</table>
|
|
443
|
+
</div>
|
|
444
|
+
|
|
445
|
+
<div class="method_details ">
|
|
446
|
+
<p class="signature " id="captures-instance_method">
|
|
447
|
+
|
|
448
|
+
- (<tt><span class='object_link'><a href="../Http/Response.html" title="Mushikago::Http::Response (class)">Mushikago::Http::Response</a></span></tt>) <strong>captures</strong>(options = {})
|
|
449
|
+
|
|
450
|
+
|
|
451
|
+
|
|
452
|
+
</p><div class="docstring">
|
|
453
|
+
<div class="discussion">
|
|
454
|
+
<p>
|
|
455
|
+
いままでキャプチャした画像の情報を取得する
|
|
456
|
+
</p>
|
|
457
|
+
|
|
458
|
+
|
|
459
|
+
</div>
|
|
460
|
+
</div>
|
|
461
|
+
<div class="tags">
|
|
462
|
+
|
|
463
|
+
<div class="examples">
|
|
464
|
+
<h3>Examples:</h3>
|
|
465
|
+
|
|
466
|
+
<h4><div class='inline'></div></h4>
|
|
467
|
+
<pre class="example code"><span class='id identifier rubyid_client'>client</span><span class='period'>.</span><span class='id identifier rubyid_captures'>captures</span><span class='lparen'>(</span><span class='symbol'>:tag</span> <span class='op'>=></span> <span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>webservice</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span></pre>
|
|
468
|
+
|
|
469
|
+
</div>
|
|
470
|
+
<h3>Parameters:</h3>
|
|
471
|
+
<ul class="param">
|
|
472
|
+
|
|
473
|
+
<li>
|
|
474
|
+
|
|
475
|
+
<span class='name'>options</span>
|
|
476
|
+
|
|
477
|
+
|
|
478
|
+
<span class='type'>(<tt>Hash</tt>)</span>
|
|
479
|
+
|
|
480
|
+
|
|
481
|
+
<em class="default">(defaults to: <tt>{}</tt>)</em>
|
|
482
|
+
|
|
483
|
+
|
|
484
|
+
—
|
|
485
|
+
<div class='inline'><p>
|
|
486
|
+
リクエストのオプション
|
|
487
|
+
</p>
|
|
488
|
+
</div>
|
|
489
|
+
|
|
490
|
+
</li>
|
|
491
|
+
|
|
492
|
+
</ul>
|
|
493
|
+
|
|
494
|
+
|
|
495
|
+
|
|
496
|
+
|
|
497
|
+
<h3>Options Hash (<tt>options</tt>):</h3>
|
|
498
|
+
<ul class="option">
|
|
499
|
+
|
|
500
|
+
<li>
|
|
501
|
+
<span class="name">:id</span>
|
|
502
|
+
<span class="type">(<tt>String</tt>)</span>
|
|
503
|
+
<span class="default">
|
|
504
|
+
|
|
505
|
+
</span>
|
|
506
|
+
— <div class='inline'><p>
|
|
507
|
+
画像のID
|
|
508
|
+
</p>
|
|
509
|
+
</div>
|
|
510
|
+
</li>
|
|
511
|
+
|
|
512
|
+
<li>
|
|
513
|
+
<span class="name">:domain</span>
|
|
514
|
+
<span class="type">(<tt>String</tt>)</span>
|
|
515
|
+
<span class="default">
|
|
516
|
+
|
|
517
|
+
</span>
|
|
518
|
+
— <div class='inline'><p>
|
|
519
|
+
指定したドメインの画像一覧を取得する
|
|
520
|
+
</p>
|
|
521
|
+
</div>
|
|
522
|
+
</li>
|
|
523
|
+
|
|
524
|
+
<li>
|
|
525
|
+
<span class="name">:tag</span>
|
|
526
|
+
<span class="type">(<tt>String</tt>)</span>
|
|
527
|
+
<span class="default">
|
|
528
|
+
|
|
529
|
+
</span>
|
|
530
|
+
— <div class='inline'><p>
|
|
531
|
+
指定したタグの画像一覧を取得する
|
|
532
|
+
</p>
|
|
533
|
+
</div>
|
|
534
|
+
</li>
|
|
535
|
+
|
|
536
|
+
<li>
|
|
537
|
+
<span class="name">:limit(10)</span>
|
|
538
|
+
<span class="type">(<tt>Integer</tt>)</span>
|
|
539
|
+
<span class="default">
|
|
540
|
+
|
|
541
|
+
</span>
|
|
542
|
+
— <div class='inline'><p>
|
|
543
|
+
最大取得件数(1-100)
|
|
544
|
+
</p>
|
|
545
|
+
</div>
|
|
546
|
+
</li>
|
|
547
|
+
|
|
548
|
+
<li>
|
|
549
|
+
<span class="name">:offset(0)</span>
|
|
550
|
+
<span class="type">(<tt>Integer</tt>)</span>
|
|
551
|
+
<span class="default">
|
|
552
|
+
|
|
553
|
+
</span>
|
|
554
|
+
— <div class='inline'><p>
|
|
555
|
+
取得オフセット
|
|
556
|
+
</p>
|
|
557
|
+
</div>
|
|
558
|
+
</li>
|
|
559
|
+
|
|
560
|
+
</ul>
|
|
561
|
+
|
|
562
|
+
|
|
563
|
+
<h3>Returns:</h3>
|
|
564
|
+
<ul class="return">
|
|
565
|
+
|
|
566
|
+
<li>
|
|
567
|
+
|
|
568
|
+
|
|
569
|
+
<span class='type'>(<tt><span class='object_link'><a href="../Http/Response.html" title="Mushikago::Http::Response (class)">Mushikago::Http::Response</a></span></tt>)</span>
|
|
570
|
+
|
|
571
|
+
|
|
572
|
+
|
|
573
|
+
—
|
|
574
|
+
<div class='inline'><p>
|
|
575
|
+
リクエストの結果
|
|
576
|
+
</p>
|
|
577
|
+
</div>
|
|
578
|
+
|
|
579
|
+
</li>
|
|
580
|
+
|
|
581
|
+
</ul>
|
|
582
|
+
|
|
583
|
+
</div><table class="source_code">
|
|
584
|
+
<tr>
|
|
585
|
+
<td>
|
|
586
|
+
<pre class="lines">
|
|
587
|
+
|
|
588
|
+
|
|
589
|
+
47
|
|
590
|
+
48
|
|
591
|
+
49
|
|
592
|
+
50</pre>
|
|
593
|
+
</td>
|
|
594
|
+
<td>
|
|
595
|
+
<pre class="code"><span class="info file"># File 'lib/mushikago/hotaru/client.rb', line 47</span>
|
|
596
|
+
|
|
597
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_captures'>captures</span> <span class='id identifier rubyid_options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span>
|
|
598
|
+
<span class='id identifier rubyid_request'>request</span> <span class='op'>=</span> <span class='const'>CapturesRequest</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_options'>options</span><span class='rparen'>)</span>
|
|
599
|
+
<span class='id identifier rubyid_send_request'>send_request</span><span class='lparen'>(</span><span class='id identifier rubyid_request'>request</span><span class='rparen'>)</span>
|
|
600
|
+
<span class='kw'>end</span></pre>
|
|
601
|
+
</td>
|
|
602
|
+
</tr>
|
|
603
|
+
</table>
|
|
604
|
+
</div>
|
|
605
|
+
|
|
606
|
+
<div class="method_details ">
|
|
607
|
+
<p class="signature " id="delete-instance_method">
|
|
608
|
+
|
|
609
|
+
- (<tt><span class='object_link'><a href="../Http/Response.html" title="Mushikago::Http::Response (class)">Mushikago::Http::Response</a></span></tt>) <strong>delete</strong>(id, options = {})
|
|
610
|
+
|
|
611
|
+
|
|
612
|
+
|
|
613
|
+
</p><div class="docstring">
|
|
614
|
+
<div class="discussion">
|
|
615
|
+
<p>
|
|
616
|
+
指定した画像を削除する
|
|
617
|
+
</p>
|
|
618
|
+
|
|
619
|
+
|
|
620
|
+
</div>
|
|
621
|
+
</div>
|
|
622
|
+
<div class="tags">
|
|
623
|
+
|
|
624
|
+
<div class="examples">
|
|
625
|
+
<h3>Examples:</h3>
|
|
626
|
+
|
|
627
|
+
<h4><div class='inline'></div></h4>
|
|
628
|
+
<pre class="example code"><span class='id identifier rubyid_client'>client</span><span class='period'>.</span><span class='id identifier rubyid_delete'>delete</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>'</span><span class='tstring_content'>5a6cdfa3-xxx3-47d6-8xxx-5f83af6b66cc</span><span class='tstring_end'>'</span></span><span class='rparen'>)</span></pre>
|
|
629
|
+
|
|
630
|
+
</div>
|
|
631
|
+
<h3>Parameters:</h3>
|
|
632
|
+
<ul class="param">
|
|
633
|
+
|
|
634
|
+
<li>
|
|
635
|
+
|
|
636
|
+
<span class='name'>id</span>
|
|
637
|
+
|
|
638
|
+
|
|
639
|
+
<span class='type'>(<tt>String</tt>)</span>
|
|
640
|
+
|
|
641
|
+
|
|
642
|
+
|
|
643
|
+
—
|
|
644
|
+
<div class='inline'><p>
|
|
645
|
+
画像のID
|
|
646
|
+
</p>
|
|
647
|
+
</div>
|
|
648
|
+
|
|
649
|
+
</li>
|
|
650
|
+
|
|
651
|
+
<li>
|
|
652
|
+
|
|
653
|
+
<span class='name'>options</span>
|
|
654
|
+
|
|
655
|
+
|
|
656
|
+
<span class='type'>(<tt>Hash</tt>)</span>
|
|
657
|
+
|
|
658
|
+
|
|
659
|
+
<em class="default">(defaults to: <tt>{}</tt>)</em>
|
|
660
|
+
|
|
661
|
+
|
|
662
|
+
—
|
|
663
|
+
<div class='inline'><p>
|
|
664
|
+
リクエストのオプション
|
|
665
|
+
</p>
|
|
666
|
+
</div>
|
|
667
|
+
|
|
668
|
+
</li>
|
|
669
|
+
|
|
670
|
+
</ul>
|
|
671
|
+
|
|
672
|
+
<h3>Returns:</h3>
|
|
673
|
+
<ul class="return">
|
|
674
|
+
|
|
675
|
+
<li>
|
|
676
|
+
|
|
677
|
+
|
|
678
|
+
<span class='type'>(<tt><span class='object_link'><a href="../Http/Response.html" title="Mushikago::Http::Response (class)">Mushikago::Http::Response</a></span></tt>)</span>
|
|
679
|
+
|
|
680
|
+
|
|
681
|
+
|
|
682
|
+
—
|
|
683
|
+
<div class='inline'><p>
|
|
684
|
+
リクエストの結果
|
|
685
|
+
</p>
|
|
686
|
+
</div>
|
|
687
|
+
|
|
688
|
+
</li>
|
|
689
|
+
|
|
690
|
+
</ul>
|
|
691
|
+
|
|
692
|
+
</div><table class="source_code">
|
|
693
|
+
<tr>
|
|
694
|
+
<td>
|
|
695
|
+
<pre class="lines">
|
|
696
|
+
|
|
697
|
+
|
|
698
|
+
59
|
|
699
|
+
60
|
|
700
|
+
61
|
|
701
|
+
62</pre>
|
|
702
|
+
</td>
|
|
703
|
+
<td>
|
|
704
|
+
<pre class="code"><span class="info file"># File 'lib/mushikago/hotaru/client.rb', line 59</span>
|
|
705
|
+
|
|
706
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_delete'>delete</span> <span class='id identifier rubyid_id'>id</span><span class='comma'>,</span> <span class='id identifier rubyid_options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span>
|
|
707
|
+
<span class='id identifier rubyid_request'>request</span> <span class='op'>=</span> <span class='const'>DeleteRequest</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_id'>id</span><span class='comma'>,</span> <span class='id identifier rubyid_options'>options</span><span class='rparen'>)</span>
|
|
708
|
+
<span class='id identifier rubyid_send_request'>send_request</span><span class='lparen'>(</span><span class='id identifier rubyid_request'>request</span><span class='rparen'>)</span>
|
|
709
|
+
<span class='kw'>end</span></pre>
|
|
710
|
+
</td>
|
|
711
|
+
</tr>
|
|
712
|
+
</table>
|
|
713
|
+
</div>
|
|
714
|
+
|
|
715
|
+
<div class="method_details ">
|
|
716
|
+
<p class="signature " id="info-instance_method">
|
|
717
|
+
|
|
718
|
+
- (<tt><span class='object_link'><a href="../Http/Response.html" title="Mushikago::Http::Response (class)">Mushikago::Http::Response</a></span></tt>) <strong>info</strong>(options = {})
|
|
719
|
+
|
|
720
|
+
|
|
721
|
+
|
|
722
|
+
</p><div class="docstring">
|
|
723
|
+
<div class="discussion">
|
|
724
|
+
<p>
|
|
725
|
+
APIの使用状況を取得する
|
|
726
|
+
</p>
|
|
727
|
+
|
|
728
|
+
|
|
729
|
+
</div>
|
|
730
|
+
</div>
|
|
731
|
+
<div class="tags">
|
|
732
|
+
|
|
733
|
+
<div class="examples">
|
|
734
|
+
<h3>Examples:</h3>
|
|
735
|
+
|
|
736
|
+
<h4><div class='inline'></div></h4>
|
|
737
|
+
<pre class="example code"><span class='id identifier rubyid_client'>client</span><span class='period'>.</span><span class='id identifier rubyid_info'>info</span></pre>
|
|
738
|
+
|
|
739
|
+
</div>
|
|
740
|
+
<h3>Parameters:</h3>
|
|
741
|
+
<ul class="param">
|
|
742
|
+
|
|
743
|
+
<li>
|
|
744
|
+
|
|
745
|
+
<span class='name'>options</span>
|
|
746
|
+
|
|
747
|
+
|
|
748
|
+
<span class='type'>(<tt>Hash</tt>)</span>
|
|
749
|
+
|
|
750
|
+
|
|
751
|
+
<em class="default">(defaults to: <tt>{}</tt>)</em>
|
|
752
|
+
|
|
753
|
+
|
|
754
|
+
—
|
|
755
|
+
<div class='inline'><p>
|
|
756
|
+
リクエストのオプション
|
|
757
|
+
</p>
|
|
758
|
+
</div>
|
|
759
|
+
|
|
760
|
+
</li>
|
|
761
|
+
|
|
762
|
+
</ul>
|
|
763
|
+
|
|
764
|
+
<h3>Returns:</h3>
|
|
765
|
+
<ul class="return">
|
|
766
|
+
|
|
767
|
+
<li>
|
|
768
|
+
|
|
769
|
+
|
|
770
|
+
<span class='type'>(<tt><span class='object_link'><a href="../Http/Response.html" title="Mushikago::Http::Response (class)">Mushikago::Http::Response</a></span></tt>)</span>
|
|
771
|
+
|
|
772
|
+
|
|
773
|
+
|
|
774
|
+
—
|
|
775
|
+
<div class='inline'><p>
|
|
776
|
+
リクエストの結果
|
|
777
|
+
</p>
|
|
778
|
+
</div>
|
|
779
|
+
|
|
780
|
+
</li>
|
|
781
|
+
|
|
782
|
+
</ul>
|
|
783
|
+
|
|
784
|
+
</div><table class="source_code">
|
|
785
|
+
<tr>
|
|
786
|
+
<td>
|
|
787
|
+
<pre class="lines">
|
|
788
|
+
|
|
789
|
+
|
|
790
|
+
70
|
|
791
|
+
71
|
|
792
|
+
72
|
|
793
|
+
73</pre>
|
|
794
|
+
</td>
|
|
795
|
+
<td>
|
|
796
|
+
<pre class="code"><span class="info file"># File 'lib/mushikago/hotaru/client.rb', line 70</span>
|
|
797
|
+
|
|
798
|
+
<span class='kw'>def</span> <span class='id identifier rubyid_info'>info</span> <span class='id identifier rubyid_options'>options</span><span class='op'>=</span><span class='lbrace'>{</span><span class='rbrace'>}</span>
|
|
799
|
+
<span class='id identifier rubyid_request'>request</span> <span class='op'>=</span> <span class='const'>InfoRequest</span><span class='period'>.</span><span class='id identifier rubyid_new'>new</span><span class='lparen'>(</span><span class='id identifier rubyid_options'>options</span><span class='rparen'>)</span>
|
|
800
|
+
<span class='id identifier rubyid_send_request'>send_request</span><span class='lparen'>(</span><span class='id identifier rubyid_request'>request</span><span class='rparen'>)</span>
|
|
801
|
+
<span class='kw'>end</span></pre>
|
|
802
|
+
</td>
|
|
803
|
+
</tr>
|
|
804
|
+
</table>
|
|
805
|
+
</div>
|
|
806
|
+
|
|
807
|
+
</div>
|
|
808
|
+
|
|
809
|
+
</div>
|
|
810
|
+
|
|
811
|
+
<div id="footer">
|
|
812
|
+
Generated on Thu Jan 26 17:19:02 2012 by
|
|
813
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
814
|
+
0.7.4 (ruby-1.9.2).
|
|
815
|
+
</div>
|
|
816
|
+
|
|
817
|
+
</body>
|
|
818
|
+
</html>
|