jpmobile 0.0.3 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (94) hide show
  1. data/CHANGELOG +4 -0
  2. data/README +8 -5
  3. data/Rakefile +6 -7
  4. data/lib/jpmobile.rb +12 -2
  5. data/lib/jpmobile/email.rb +19 -0
  6. data/lib/jpmobile/filter.rb +1 -15
  7. data/lib/jpmobile/helpers.rb +76 -34
  8. data/lib/jpmobile/hook_action_controller.rb +1 -0
  9. data/lib/jpmobile/hook_action_view.rb +79 -28
  10. data/lib/jpmobile/mobile/abstract_mobile.rb +13 -1
  11. data/lib/jpmobile/mobile/au.rb +2 -0
  12. data/lib/jpmobile/mobile/docomo.rb +3 -1
  13. data/lib/jpmobile/mobile/emobile.rb +2 -0
  14. data/lib/jpmobile/mobile/softbank.rb +7 -1
  15. data/lib/jpmobile/mobile/willcom.rb +4 -0
  16. data/lib/jpmobile/mobile/z_display_info_docomo.rb +85 -2
  17. data/lib/jpmobile/mobile/z_ip_addresses_au.rb +40 -25
  18. data/lib/jpmobile/mobile/z_ip_addresses_docomo.rb +3 -1
  19. data/lib/jpmobile/mobile/z_ip_addresses_willcom.rb +97 -76
  20. data/lib/jpmobile/position.rb +8 -2
  21. data/lib/jpmobile/request_with_mobile.rb +1 -1
  22. data/lib/jpmobile/util.rb +21 -0
  23. data/lib/jpmobile/version.rb +1 -1
  24. data/test/au_test.rb +1 -1
  25. data/tools/update_display_info_docomo.rb +1 -0
  26. data/tools/update_ip_addresses_willcom.rb +2 -1
  27. metadata +36 -82
  28. data/doc/classes/ActionController.html +0 -120
  29. data/doc/classes/ActionController/AbstractRequest.html +0 -118
  30. data/doc/classes/ActionController/CgiRequest.html +0 -160
  31. data/doc/classes/ActionView.html +0 -101
  32. data/doc/classes/DatumConv.html +0 -324
  33. data/doc/classes/Jpmobile/Display.html +0 -333
  34. data/doc/classes/Jpmobile/Emoticon.html +0 -467
  35. data/doc/classes/Jpmobile/Filter.html +0 -120
  36. data/doc/classes/Jpmobile/Filter/ApplyOnlyForMobile.html +0 -172
  37. data/doc/classes/Jpmobile/Filter/Base.html +0 -269
  38. data/doc/classes/Jpmobile/Filter/Emoticon.html +0 -118
  39. data/doc/classes/Jpmobile/Filter/Emoticon/Inner.html +0 -184
  40. data/doc/classes/Jpmobile/Filter/Emoticon/Outer.html +0 -207
  41. data/doc/classes/Jpmobile/Filter/FilterTable.html +0 -178
  42. data/doc/classes/Jpmobile/Filter/HankakuKana.html +0 -126
  43. data/doc/classes/Jpmobile/Filter/Sjis.html +0 -271
  44. data/doc/classes/Jpmobile/Helpers.html +0 -588
  45. data/doc/classes/Jpmobile/Mobile.html +0 -150
  46. data/doc/classes/Jpmobile/Mobile/AbstractMobile.html +0 -389
  47. data/doc/classes/Jpmobile/Mobile/Au.html +0 -420
  48. data/doc/classes/Jpmobile/Mobile/Ddipocket.html +0 -138
  49. data/doc/classes/Jpmobile/Mobile/Docomo.html +0 -411
  50. data/doc/classes/Jpmobile/Mobile/Emobile.html +0 -183
  51. data/doc/classes/Jpmobile/Mobile/Jphone.html +0 -212
  52. data/doc/classes/Jpmobile/Mobile/Softbank.html +0 -344
  53. data/doc/classes/Jpmobile/Mobile/Vodafone.html +0 -176
  54. data/doc/classes/Jpmobile/Mobile/Willcom.html +0 -211
  55. data/doc/classes/Jpmobile/Position.html +0 -384
  56. data/doc/classes/Jpmobile/RequestWithMobile.html +0 -263
  57. data/doc/created.rid +0 -1
  58. data/doc/files/CHANGELOG.html +0 -110
  59. data/doc/files/README.html +0 -455
  60. data/doc/files/lib/jpmobile/datum_conv_rb.html +0 -110
  61. data/doc/files/lib/jpmobile/emoticon/au_rb.html +0 -124
  62. data/doc/files/lib/jpmobile/emoticon/conversion_table_rb.html +0 -124
  63. data/doc/files/lib/jpmobile/emoticon/docomo_rb.html +0 -119
  64. data/doc/files/lib/jpmobile/emoticon/softbank_rb.html +0 -119
  65. data/doc/files/lib/jpmobile/emoticon/z_combine_rb.html +0 -101
  66. data/doc/files/lib/jpmobile/emoticon_rb.html +0 -101
  67. data/doc/files/lib/jpmobile/filter_rb.html +0 -115
  68. data/doc/files/lib/jpmobile/helpers_rb.html +0 -105
  69. data/doc/files/lib/jpmobile/hook_abstract_request_rb.html +0 -108
  70. data/doc/files/lib/jpmobile/hook_action_controller_rb.html +0 -101
  71. data/doc/files/lib/jpmobile/hook_action_view_rb.html +0 -110
  72. data/doc/files/lib/jpmobile/mobile/abstract_mobile_rb.html +0 -108
  73. data/doc/files/lib/jpmobile/mobile/au_rb.html +0 -112
  74. data/doc/files/lib/jpmobile/mobile/display_rb.html +0 -111
  75. data/doc/files/lib/jpmobile/mobile/docomo_rb.html +0 -105
  76. data/doc/files/lib/jpmobile/mobile/emobile_rb.html +0 -105
  77. data/doc/files/lib/jpmobile/mobile/softbank_rb.html +0 -115
  78. data/doc/files/lib/jpmobile/mobile/willcom_rb.html +0 -108
  79. data/doc/files/lib/jpmobile/mobile/z_display_info_docomo_rb.html +0 -114
  80. data/doc/files/lib/jpmobile/mobile/z_ip_addresses_au_rb.html +0 -114
  81. data/doc/files/lib/jpmobile/mobile/z_ip_addresses_docomo_rb.html +0 -124
  82. data/doc/files/lib/jpmobile/mobile/z_ip_addresses_emobile_rb.html +0 -111
  83. data/doc/files/lib/jpmobile/mobile/z_ip_addresses_softbank_rb.html +0 -124
  84. data/doc/files/lib/jpmobile/mobile/z_ip_addresses_willcom_rb.html +0 -114
  85. data/doc/files/lib/jpmobile/position_rb.html +0 -105
  86. data/doc/files/lib/jpmobile/request_with_mobile_rb.html +0 -111
  87. data/doc/files/lib/jpmobile/trans_sid_rb.html +0 -118
  88. data/doc/files/lib/jpmobile/version_rb.html +0 -101
  89. data/doc/files/lib/jpmobile_rb.html +0 -101
  90. data/doc/fr_class_index.html +0 -55
  91. data/doc/fr_file_index.html +0 -58
  92. data/doc/fr_method_index.html +0 -134
  93. data/doc/index.html +0 -24
  94. data/doc/rdoc-style.css +0 -208
@@ -1,420 +0,0 @@
1
- <?xml version="1.0" encoding=" UTF-8"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
- <head>
8
- <title>Class: Jpmobile::Mobile::Au</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset= UTF-8" />
10
- <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
12
- <script type="text/javascript">
13
- // <![CDATA[
14
-
15
- function popupCode( url ) {
16
- window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
17
- }
18
-
19
- function toggleCode( id ) {
20
- if ( document.getElementById )
21
- elem = document.getElementById( id );
22
- else if ( document.all )
23
- elem = eval( "document.all." + id );
24
- else
25
- return false;
26
-
27
- elemStyle = elem.style;
28
-
29
- if ( elemStyle.display != "block" ) {
30
- elemStyle.display = "block"
31
- } else {
32
- elemStyle.display = "none"
33
- }
34
-
35
- return true;
36
- }
37
-
38
- // Make codeblocks hidden by default
39
- document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
40
-
41
- // ]]>
42
- </script>
43
-
44
- </head>
45
- <body>
46
-
47
-
48
-
49
- <div id="classHeader">
50
- <table class="header-table">
51
- <tr class="top-aligned-row">
52
- <td><strong>Class</strong></td>
53
- <td class="class-name-in-header">Jpmobile::Mobile::Au</td>
54
- </tr>
55
- <tr class="top-aligned-row">
56
- <td><strong>In:</strong></td>
57
- <td>
58
- <a href="../../../files/lib/jpmobile/mobile/au_rb.html">
59
- lib/jpmobile/mobile/au.rb
60
- </a>
61
- <br />
62
- </td>
63
- </tr>
64
-
65
- <tr class="top-aligned-row">
66
- <td><strong>Parent:</strong></td>
67
- <td>
68
- <a href="AbstractMobile.html">
69
- AbstractMobile
70
- </a>
71
- </td>
72
- </tr>
73
- </table>
74
- </div>
75
- <!-- banner header -->
76
-
77
- <div id="bodyContent">
78
-
79
-
80
-
81
- <div id="contextContent">
82
-
83
- <div id="description">
84
- <h2>au携帯電話</h2>
85
- <p>
86
- CDMA 1X, CDMA 1X WINを含む。
87
- </p>
88
-
89
- </div>
90
-
91
-
92
- </div>
93
-
94
- <div id="method-list">
95
- <h3 class="section-bar">Methods</h3>
96
-
97
- <div class="name-list">
98
- <a href="#M000048">device_id</a>&nbsp;&nbsp;
99
- <a href="#M000047">display</a>&nbsp;&nbsp;
100
- <a href="#M000045">ident_subscriber</a>&nbsp;&nbsp;
101
- <a href="#M000046">position</a>&nbsp;&nbsp;
102
- <a href="#M000044">subno</a>&nbsp;&nbsp;
103
- <a href="#M000051">supports_cookie?</a>&nbsp;&nbsp;
104
- <a href="#M000050">supports_gps?</a>&nbsp;&nbsp;
105
- <a href="#M000049">supports_location?</a>&nbsp;&nbsp;
106
- </div>
107
- </div>
108
-
109
- </div>
110
-
111
-
112
- <!-- if includes -->
113
-
114
- <div id="section">
115
-
116
-
117
- <div id="constants-list">
118
- <h3 class="section-bar">Constants</h3>
119
-
120
- <div class="name-list">
121
- <table summary="Constants">
122
- <tr class="top-aligned-row context-row">
123
- <td class="context-item-name">USER_AGENT_REGEXP</td>
124
- <td>=</td>
125
- <td class="context-item-value">/^(?:KDDI|UP.Browser\/.+?)-(.+?) /</td>
126
- <td width="3em">&nbsp;</td>
127
- <td class="context-item-desc">
128
- 対応するUser-Agentの正規表現 User-Agent文字列中に
129
- &quot;UP.Browser&quot; を含む<a
130
- href="Vodafone.html">Vodafone</a>の端末があるので注意が必要
131
-
132
- </td>
133
- </tr>
134
- <tr class="top-aligned-row context-row">
135
- <td class="context-item-name">LOCATION_UNSUPPORTED_DEVICE_ID</td>
136
- <td>=</td>
137
- <td class="context-item-value">[&quot;PT21&quot;, &quot;TS25&quot;, &quot;KCTE&quot;, &quot;TST9&quot;, &quot;KCU1&quot;, &quot;SYT5&quot;, &quot;KCTD&quot;, &quot;TST8&quot;, &quot;TST7&quot;, &quot;KCTC&quot;, &quot;SYT4&quot;, &quot;KCTB&quot;, &quot;KCTA&quot;, &quot;TST6&quot;, &quot;KCT9&quot;, &quot;TST5&quot;, &quot;TST4&quot;, &quot;KCT8&quot;, &quot;SYT3&quot;, &quot;KCT7&quot;, &quot;MIT1&quot;, &quot;MAT3&quot;, &quot;KCT6&quot;, &quot;TST3&quot;, &quot;KCT5&quot;, &quot;KCT4&quot;, &quot;SYT2&quot;, &quot;MAT1&quot;, &quot;MAT2&quot;, &quot;TST2&quot;, &quot;KCT3&quot;, &quot;KCT2&quot;, &quot;KCT1&quot;, &quot;TST1&quot;, &quot;SYT1&quot;]</td>
138
- <td width="3em">&nbsp;</td>
139
- <td class="context-item-desc">
140
- 簡易位置情報取得に対応していないデバイスID <a
141
- href="http://www.au.kddi.com/ezfactory/tec/spec/eznavi.html">www.au.kddi.com/ezfactory/tec/spec/eznavi.html</a>
142
-
143
- </td>
144
- </tr>
145
- <tr class="top-aligned-row context-row">
146
- <td class="context-item-name">GPS_UNSUPPORTED_DEVICE_ID</td>
147
- <td>=</td>
148
- <td class="context-item-value">[&quot;PT21&quot;, &quot;KC26&quot;, &quot;SN28&quot;, &quot;SN26&quot;, &quot;KC23&quot;, &quot;SA28&quot;, &quot;TS25&quot;, &quot;SA25&quot;, &quot;SA24&quot;, &quot;SN23&quot;, &quot;ST14&quot;, &quot;KC15&quot;, &quot;SN22&quot;, &quot;KC14&quot;, &quot;ST13&quot;, &quot;SN17&quot;, &quot;SY15&quot;, &quot;CA14&quot;, &quot;HI14&quot;, &quot;TS14&quot;, &quot;KC13&quot;, &quot;SN15&quot;, &quot;SN16&quot;, &quot;SY14&quot;, &quot;ST12&quot;, &quot;TS13&quot;, &quot;CA13&quot;, &quot;MA13&quot;, &quot;HI13&quot;, &quot;SN13&quot;, &quot;SY13&quot;, &quot;SN12&quot;, &quot;SN14&quot;, &quot;ST11&quot;, &quot;DN11&quot;, &quot;SY12&quot;, &quot;KCTE&quot;, &quot;TST9&quot;, &quot;KCU1&quot;, &quot;SYT5&quot;, &quot;KCTD&quot;, &quot;TST8&quot;, &quot;TST7&quot;, &quot;KCTC&quot;, &quot;SYT4&quot;, &quot;KCTB&quot;, &quot;KCTA&quot;, &quot;TST6&quot;, &quot;KCT9&quot;, &quot;TST5&quot;, &quot;TST4&quot;, &quot;KCT8&quot;, &quot;SYT3&quot;, &quot;KCT7&quot;, &quot;MIT1&quot;, &quot;MAT3&quot;, &quot;KCT6&quot;, &quot;TST3&quot;, &quot;KCT5&quot;, &quot;KCT4&quot;, &quot;SYT2&quot;, &quot;MAT1&quot;, &quot;MAT2&quot;, &quot;TST2&quot;, &quot;KCT3&quot;, &quot;KCT2&quot;, &quot;KCT1&quot;, &quot;TST1&quot;, &quot;SYT1&quot;]</td>
149
- <td width="3em">&nbsp;</td>
150
- <td class="context-item-desc">
151
- GPS取得に対応していないデバイスID
152
-
153
- </td>
154
- </tr>
155
- </table>
156
- </div>
157
- </div>
158
-
159
-
160
-
161
-
162
-
163
-
164
- <!-- if method_list -->
165
- <div id="methods">
166
- <h3 class="section-bar">Public Instance methods</h3>
167
-
168
- <div id="method-M000048" class="method-detail">
169
- <a name="M000048"></a>
170
-
171
- <div class="method-heading">
172
- <a href="#M000048" class="method-signature">
173
- <span class="method-name">device_id</span><span class="method-args">()</span>
174
- </a>
175
- </div>
176
-
177
- <div class="method-description">
178
- <p>
179
- デバイスIDを返す
180
- </p>
181
- <p><a class="source-toggle" href="#"
182
- onclick="toggleCode('M000048-source');return false;">[Source]</a></p>
183
- <div class="method-source-code" id="M000048-source">
184
- <pre>
185
- <span class="ruby-comment cmt"># File lib/jpmobile/mobile/au.rb, line 72</span>
186
- 72: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">device_id</span>
187
- 73: <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@request</span>.<span class="ruby-identifier">env</span>[<span class="ruby-value str">'HTTP_USER_AGENT'</span>] <span class="ruby-operator">=~</span> <span class="ruby-constant">USER_AGENT_REGEXP</span>
188
- 74: <span class="ruby-keyword kw">return</span> <span class="ruby-identifier">$1</span>
189
- 75: <span class="ruby-keyword kw">else</span>
190
- 76: <span class="ruby-keyword kw">nil</span>
191
- 77: <span class="ruby-keyword kw">end</span>
192
- 78: <span class="ruby-keyword kw">end</span>
193
- </pre>
194
- </div>
195
- </div>
196
- </div>
197
-
198
- <div id="method-M000047" class="method-detail">
199
- <a name="M000047"></a>
200
-
201
- <div class="method-heading">
202
- <a href="#M000047" class="method-signature">
203
- <span class="method-name">display</span><span class="method-args">()</span>
204
- </a>
205
- </div>
206
-
207
- <div class="method-description">
208
- <p>
209
- 画面情報を <tt><a href="../Display.html">Display</a></tt>
210
- クラスのインスタンスで返す。
211
- </p>
212
- <p><a class="source-toggle" href="#"
213
- onclick="toggleCode('M000047-source');return false;">[Source]</a></p>
214
- <div class="method-source-code" id="M000047-source">
215
- <pre>
216
- <span class="ruby-comment cmt"># File lib/jpmobile/mobile/au.rb, line 54</span>
217
- 54: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">display</span>
218
- 55: <span class="ruby-keyword kw">return</span> <span class="ruby-ivar">@__display</span> <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@__display</span>
219
- 56:
220
- 57: <span class="ruby-identifier">p_w</span> = <span class="ruby-identifier">p_h</span> = <span class="ruby-identifier">col_p</span> = <span class="ruby-identifier">cols</span> = <span class="ruby-keyword kw">nil</span>
221
- 58: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">r</span> = <span class="ruby-ivar">@request</span>.<span class="ruby-identifier">env</span>[<span class="ruby-value str">'HTTP_X_UP_DEVCAP_SCREENPIXELS'</span>]
222
- 59: <span class="ruby-identifier">p_w</span>, <span class="ruby-identifier">p_h</span> = <span class="ruby-identifier">r</span>.<span class="ruby-identifier">split</span>(<span class="ruby-regexp re">/,/</span>,<span class="ruby-value">2</span>).<span class="ruby-identifier">map</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">x</span><span class="ruby-operator">|</span> <span class="ruby-identifier">x</span>.<span class="ruby-identifier">to_i</span>}
223
- 60: <span class="ruby-keyword kw">end</span>
224
- 61: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">r</span> = <span class="ruby-ivar">@request</span>.<span class="ruby-identifier">env</span>[<span class="ruby-value str">'HTTP_X_UP_DEVCAP_ISCOLOR'</span>]
225
- 62: <span class="ruby-identifier">col_p</span> = (<span class="ruby-identifier">r</span> <span class="ruby-operator">==</span> <span class="ruby-value str">'1'</span>)
226
- 63: <span class="ruby-keyword kw">end</span>
227
- 64: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">r</span> = <span class="ruby-ivar">@request</span>.<span class="ruby-identifier">env</span>[<span class="ruby-value str">'HTTP_X_UP_DEVCAP_SCREENDEPTH'</span>]
228
- 65: <span class="ruby-identifier">a</span> = <span class="ruby-identifier">r</span>.<span class="ruby-identifier">split</span>(<span class="ruby-regexp re">/,/</span>)
229
- 66: <span class="ruby-identifier">cols</span> = <span class="ruby-value">2</span> <span class="ruby-operator">**</span> <span class="ruby-identifier">a</span>[<span class="ruby-value">0</span>].<span class="ruby-identifier">to_i</span>
230
- 67: <span class="ruby-keyword kw">end</span>
231
- 68: <span class="ruby-ivar">@__display</span> = <span class="ruby-constant">Jpmobile</span><span class="ruby-operator">::</span><span class="ruby-constant">Display</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">p_w</span>, <span class="ruby-identifier">p_h</span>, <span class="ruby-keyword kw">nil</span>, <span class="ruby-keyword kw">nil</span>, <span class="ruby-identifier">col_p</span>, <span class="ruby-identifier">cols</span>)
232
- 69: <span class="ruby-keyword kw">end</span>
233
- </pre>
234
- </div>
235
- </div>
236
- </div>
237
-
238
- <div id="method-M000045" class="method-detail">
239
- <a name="M000045"></a>
240
-
241
- <div class="method-heading">
242
- <span class="method-name">ident_subscriber</span><span class="method-args">()</span>
243
- </div>
244
-
245
- <div class="method-description">
246
- <p>
247
- Alias for <a href="Au.html#M000044">subno</a>
248
- </p>
249
- </div>
250
- </div>
251
-
252
- <div id="method-M000046" class="method-detail">
253
- <a name="M000046"></a>
254
-
255
- <div class="method-heading">
256
- <a href="#M000046" class="method-signature">
257
- <span class="method-name">position</span><span class="method-args">()</span>
258
- </a>
259
- </div>
260
-
261
- <div class="method-description">
262
- <p>
263
- 位置情報があれば <a href="../Position.html">Position</a>
264
- のインスタンスを返す。無ければ <tt>nil</tt> を返す。
265
- </p>
266
- <p><a class="source-toggle" href="#"
267
- onclick="toggleCode('M000046-source');return false;">[Source]</a></p>
268
- <div class="method-source-code" id="M000046-source">
269
- <pre>
270
- <span class="ruby-comment cmt"># File lib/jpmobile/mobile/au.rb, line 27</span>
271
- 27: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">position</span>
272
- 28: <span class="ruby-keyword kw">return</span> <span class="ruby-ivar">@__posotion</span> <span class="ruby-keyword kw">if</span> <span class="ruby-keyword kw">defined?</span> <span class="ruby-ivar">@__posotion</span>
273
- 29: <span class="ruby-keyword kw">return</span> <span class="ruby-ivar">@__posotion</span> = <span class="ruby-keyword kw">nil</span> <span class="ruby-keyword kw">if</span> ( <span class="ruby-identifier">params</span>[<span class="ruby-value str">&quot;lat&quot;</span>].<span class="ruby-identifier">nil?</span> <span class="ruby-operator">||</span> <span class="ruby-identifier">params</span>[<span class="ruby-value str">'lat'</span>] <span class="ruby-operator">==</span> <span class="ruby-value str">''</span> <span class="ruby-operator">||</span> <span class="ruby-identifier">params</span>[<span class="ruby-value str">&quot;lon&quot;</span>].<span class="ruby-identifier">nil?</span> <span class="ruby-operator">||</span> <span class="ruby-identifier">params</span>[<span class="ruby-value str">&quot;lon&quot;</span>] <span class="ruby-operator">==</span> <span class="ruby-value str">''</span> )
274
- 30: <span class="ruby-identifier">l</span> = <span class="ruby-constant">Jpmobile</span><span class="ruby-operator">::</span><span class="ruby-constant">Position</span>.<span class="ruby-identifier">new</span>
275
- 31: <span class="ruby-identifier">l</span>.<span class="ruby-identifier">options</span> = <span class="ruby-identifier">params</span>.<span class="ruby-identifier">reject</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">x</span>,<span class="ruby-identifier">v</span><span class="ruby-operator">|</span> <span class="ruby-operator">!</span>[<span class="ruby-value str">&quot;ver&quot;</span>, <span class="ruby-value str">&quot;datum&quot;</span>, <span class="ruby-value str">&quot;unit&quot;</span>, <span class="ruby-value str">&quot;lat&quot;</span>, <span class="ruby-value str">&quot;lon&quot;</span>, <span class="ruby-value str">&quot;alt&quot;</span>, <span class="ruby-value str">&quot;time&quot;</span>, <span class="ruby-value str">&quot;smaj&quot;</span>, <span class="ruby-value str">&quot;smin&quot;</span>, <span class="ruby-value str">&quot;vert&quot;</span>, <span class="ruby-value str">&quot;majaa&quot;</span>, <span class="ruby-value str">&quot;fm&quot;</span>].<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">x</span>) }
276
- 32: <span class="ruby-keyword kw">case</span> <span class="ruby-identifier">params</span>[<span class="ruby-value str">&quot;unit&quot;</span>]
277
- 33: <span class="ruby-keyword kw">when</span> <span class="ruby-value str">&quot;1&quot;</span>
278
- 34: <span class="ruby-identifier">l</span>.<span class="ruby-identifier">lat</span> = <span class="ruby-identifier">params</span>[<span class="ruby-value str">&quot;lat&quot;</span>].<span class="ruby-identifier">to_f</span>
279
- 35: <span class="ruby-identifier">l</span>.<span class="ruby-identifier">lon</span> = <span class="ruby-identifier">params</span>[<span class="ruby-value str">&quot;lon&quot;</span>].<span class="ruby-identifier">to_f</span>
280
- 36: <span class="ruby-keyword kw">when</span> <span class="ruby-value str">&quot;0&quot;</span>, <span class="ruby-value str">&quot;dms&quot;</span>
281
- 37: <span class="ruby-identifier">raise</span> <span class="ruby-value str">&quot;Invalid dms form&quot;</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">params</span>[<span class="ruby-value str">&quot;lat&quot;</span>] <span class="ruby-operator">=~</span> <span class="ruby-regexp re">/^([+-]?\d+)\.(\d+)\.(\d+\.\d+)$/</span>
282
- 38: <span class="ruby-identifier">l</span>.<span class="ruby-identifier">lat</span> = <span class="ruby-constant">Jpmobile</span><span class="ruby-operator">::</span><span class="ruby-constant">Position</span>.<span class="ruby-identifier">dms2deg</span>(<span class="ruby-identifier">$1</span>,<span class="ruby-identifier">$2</span>,<span class="ruby-identifier">$3</span>)
283
- 39: <span class="ruby-identifier">raise</span> <span class="ruby-value str">&quot;Invalid dms form&quot;</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">params</span>[<span class="ruby-value str">&quot;lon&quot;</span>] <span class="ruby-operator">=~</span> <span class="ruby-regexp re">/^([+-]?\d+)\.(\d+)\.(\d+\.\d+)$/</span>
284
- 40: <span class="ruby-identifier">l</span>.<span class="ruby-identifier">lon</span> = <span class="ruby-constant">Jpmobile</span><span class="ruby-operator">::</span><span class="ruby-constant">Position</span>.<span class="ruby-identifier">dms2deg</span>(<span class="ruby-identifier">$1</span>,<span class="ruby-identifier">$2</span>,<span class="ruby-identifier">$3</span>)
285
- 41: <span class="ruby-keyword kw">else</span>
286
- 42: <span class="ruby-keyword kw">return</span> <span class="ruby-ivar">@__posotion</span> = <span class="ruby-keyword kw">nil</span>
287
- 43: <span class="ruby-keyword kw">end</span>
288
- 44: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">params</span>[<span class="ruby-value str">&quot;datum&quot;</span>] <span class="ruby-operator">==</span> <span class="ruby-value str">&quot;1&quot;</span>
289
- 45: <span class="ruby-comment cmt"># ただし、params[&quot;datum&quot;]==&quot;tokyo&quot;のとき(簡易位置情報)のときは、</span>
290
- 46: <span class="ruby-comment cmt"># 実際にはWGS84系のデータが渡ってくる</span>
291
- 47: <span class="ruby-comment cmt"># http://www.au.kddi.com/ezfactory/tec/spec/eznavi.html</span>
292
- 48: <span class="ruby-identifier">l</span>.<span class="ruby-identifier">tokyo2wgs84!</span>
293
- 49: <span class="ruby-keyword kw">end</span>
294
- 50: <span class="ruby-keyword kw">return</span> <span class="ruby-ivar">@__posotion</span> = <span class="ruby-identifier">l</span>
295
- 51: <span class="ruby-keyword kw">end</span>
296
- </pre>
297
- </div>
298
- </div>
299
- </div>
300
-
301
- <div id="method-M000044" class="method-detail">
302
- <a name="M000044"></a>
303
-
304
- <div class="method-heading">
305
- <a href="#M000044" class="method-signature">
306
- <span class="method-name">subno</span><span class="method-args">()</span>
307
- </a>
308
- </div>
309
-
310
- <div class="method-description">
311
- <p>
312
- EZ番号(サブスクライバID)があれば返す。無ければ
313
- <tt>nil</tt> を返す。
314
- </p>
315
- <p><a class="source-toggle" href="#"
316
- onclick="toggleCode('M000044-source');return false;">[Source]</a></p>
317
- <div class="method-source-code" id="M000044-source">
318
- <pre>
319
- <span class="ruby-comment cmt"># File lib/jpmobile/mobile/au.rb, line 21</span>
320
- 21: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">subno</span>
321
- 22: <span class="ruby-ivar">@request</span>.<span class="ruby-identifier">env</span>[<span class="ruby-value str">&quot;HTTP_X_UP_SUBNO&quot;</span>]
322
- 23: <span class="ruby-keyword kw">end</span>
323
- </pre>
324
- </div>
325
- </div>
326
- </div>
327
-
328
- <div id="method-M000051" class="method-detail">
329
- <a name="M000051"></a>
330
-
331
- <div class="method-heading">
332
- <a href="#M000051" class="method-signature">
333
- <span class="method-name">supports_cookie?</span><span class="method-args">()</span>
334
- </a>
335
- </div>
336
-
337
- <div class="method-description">
338
- <p>
339
- cookieに対応しているか?
340
- </p>
341
- <p><a class="source-toggle" href="#"
342
- onclick="toggleCode('M000051-source');return false;">[Source]</a></p>
343
- <div class="method-source-code" id="M000051-source">
344
- <pre>
345
- <span class="ruby-comment cmt"># File lib/jpmobile/mobile/au.rb, line 91</span>
346
- 91: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">supports_cookie?</span>
347
- 92: <span class="ruby-keyword kw">true</span>
348
- 93: <span class="ruby-keyword kw">end</span>
349
- </pre>
350
- </div>
351
- </div>
352
- </div>
353
-
354
- <div id="method-M000050" class="method-detail">
355
- <a name="M000050"></a>
356
-
357
- <div class="method-heading">
358
- <a href="#M000050" class="method-signature">
359
- <span class="method-name">supports_gps?</span><span class="method-args">()</span>
360
- </a>
361
- </div>
362
-
363
- <div class="method-description">
364
- <p>
365
- GPS位置情報取得に対応している場合は <tt>true</tt>
366
- を返す。
367
- </p>
368
- <p><a class="source-toggle" href="#"
369
- onclick="toggleCode('M000050-source');return false;">[Source]</a></p>
370
- <div class="method-source-code" id="M000050-source">
371
- <pre>
372
- <span class="ruby-comment cmt"># File lib/jpmobile/mobile/au.rb, line 86</span>
373
- 86: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">supports_gps?</span>
374
- 87: <span class="ruby-operator">!</span> <span class="ruby-constant">GPS_UNSUPPORTED_DEVICE_ID</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">device_id</span>)
375
- 88: <span class="ruby-keyword kw">end</span>
376
- </pre>
377
- </div>
378
- </div>
379
- </div>
380
-
381
- <div id="method-M000049" class="method-detail">
382
- <a name="M000049"></a>
383
-
384
- <div class="method-heading">
385
- <a href="#M000049" class="method-signature">
386
- <span class="method-name">supports_location?</span><span class="method-args">()</span>
387
- </a>
388
- </div>
389
-
390
- <div class="method-description">
391
- <p>
392
- 簡易位置情報取得に対応している場合は <tt>true</tt>
393
- を返す。
394
- </p>
395
- <p><a class="source-toggle" href="#"
396
- onclick="toggleCode('M000049-source');return false;">[Source]</a></p>
397
- <div class="method-source-code" id="M000049-source">
398
- <pre>
399
- <span class="ruby-comment cmt"># File lib/jpmobile/mobile/au.rb, line 81</span>
400
- 81: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">supports_location?</span>
401
- 82: <span class="ruby-operator">!</span> <span class="ruby-constant">LOCATION_UNSUPPORTED_DEVICE_ID</span>.<span class="ruby-identifier">include?</span>(<span class="ruby-identifier">device_id</span>)
402
- 83: <span class="ruby-keyword kw">end</span>
403
- </pre>
404
- </div>
405
- </div>
406
- </div>
407
-
408
-
409
- </div>
410
-
411
-
412
- </div>
413
-
414
-
415
- <div id="validator-badges">
416
- <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
417
- </div>
418
-
419
- </body>
420
- </html>
@@ -1,138 +0,0 @@
1
- <?xml version="1.0" encoding=" UTF-8"?>
2
- <!DOCTYPE html
3
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
-
6
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
- <head>
8
- <title>Class: Jpmobile::Mobile::Ddipocket</title>
9
- <meta http-equiv="Content-Type" content="text/html; charset= UTF-8" />
10
- <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
12
- <script type="text/javascript">
13
- // <![CDATA[
14
-
15
- function popupCode( url ) {
16
- window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
17
- }
18
-
19
- function toggleCode( id ) {
20
- if ( document.getElementById )
21
- elem = document.getElementById( id );
22
- else if ( document.all )
23
- elem = eval( "document.all." + id );
24
- else
25
- return false;
26
-
27
- elemStyle = elem.style;
28
-
29
- if ( elemStyle.display != "block" ) {
30
- elemStyle.display = "block"
31
- } else {
32
- elemStyle.display = "none"
33
- }
34
-
35
- return true;
36
- }
37
-
38
- // Make codeblocks hidden by default
39
- document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
40
-
41
- // ]]>
42
- </script>
43
-
44
- </head>
45
- <body>
46
-
47
-
48
-
49
- <div id="classHeader">
50
- <table class="header-table">
51
- <tr class="top-aligned-row">
52
- <td><strong>Class</strong></td>
53
- <td class="class-name-in-header">Jpmobile::Mobile::Ddipocket</td>
54
- </tr>
55
- <tr class="top-aligned-row">
56
- <td><strong>In:</strong></td>
57
- <td>
58
- <a href="../../../files/lib/jpmobile/mobile/willcom_rb.html">
59
- lib/jpmobile/mobile/willcom.rb
60
- </a>
61
- <br />
62
- </td>
63
- </tr>
64
-
65
- <tr class="top-aligned-row">
66
- <td><strong>Parent:</strong></td>
67
- <td>
68
- <a href="Willcom.html">
69
- Willcom
70
- </a>
71
- </td>
72
- </tr>
73
- </table>
74
- </div>
75
- <!-- banner header -->
76
-
77
- <div id="bodyContent">
78
-
79
-
80
-
81
- <div id="contextContent">
82
-
83
- <div id="description">
84
- <h2>DDI-POCKET</h2>
85
- <p>
86
- スーパクラスは<a href="Willcom.html">Willcom</a>。
87
- </p>
88
-
89
- </div>
90
-
91
-
92
- </div>
93
-
94
-
95
- </div>
96
-
97
-
98
- <!-- if includes -->
99
-
100
- <div id="section">
101
-
102
-
103
- <div id="constants-list">
104
- <h3 class="section-bar">Constants</h3>
105
-
106
- <div class="name-list">
107
- <table summary="Constants">
108
- <tr class="top-aligned-row context-row">
109
- <td class="context-item-name">USER_AGENT_REGEXP</td>
110
- <td>=</td>
111
- <td class="context-item-value">/^Mozilla\/3.0\(DDIPOCKET/</td>
112
- <td width="3em">&nbsp;</td>
113
- <td class="context-item-desc">
114
- 対応するUser-Agentの正規表現
115
-
116
- </td>
117
- </tr>
118
- </table>
119
- </div>
120
- </div>
121
-
122
-
123
-
124
-
125
-
126
-
127
- <!-- if method_list -->
128
-
129
-
130
- </div>
131
-
132
-
133
- <div id="validator-badges">
134
- <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
135
- </div>
136
-
137
- </body>
138
- </html>