binaryparse 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- data/binaryparse.gemspec +17 -17
- data/examples/pms_input_2_test.rb +70 -0
- data/lib/blocker.rb +1 -1
- metadata +3 -66
- data/doc/binaryparse.chm +0 -0
- data/doc/bphelp.zip +0 -0
- data/doc/classes/BinaryBlocker/BitFieldEncoder.html +0 -328
- data/doc/classes/BinaryBlocker/Blocker.html +0 -168
- data/doc/classes/BinaryBlocker/CountedArrayEncoder.html +0 -347
- data/doc/classes/BinaryBlocker/Encoder.html +0 -526
- data/doc/classes/BinaryBlocker/FixedArrayEncoder.html +0 -278
- data/doc/classes/BinaryBlocker/FixedStringEncoder.html +0 -177
- data/doc/classes/BinaryBlocker/FixedUTF16StringEncoder.html +0 -229
- data/doc/classes/BinaryBlocker/GroupEncoder.html +0 -650
- data/doc/classes/BinaryBlocker/ListOfEncoder.html +0 -343
- data/doc/classes/BinaryBlocker/OneOfEncoder.html +0 -306
- data/doc/classes/BinaryBlocker/PackedDateEncoder.html +0 -220
- data/doc/classes/BinaryBlocker/PackedDateTimeEncoder.html +0 -220
- data/doc/classes/BinaryBlocker/PackedNumberEncoder.html +0 -231
- data/doc/classes/BinaryBlocker/SimpleEncoder.html +0 -284
- data/doc/classes/BinaryBlocker.html +0 -329
- data/doc/classes/BufferedIO.html +0 -324
- data/doc/classes/TestBlocker/BBDate.html +0 -120
- data/doc/classes/TestBlocker/BBList.html +0 -120
- data/doc/classes/TestBlocker/BBPacked.html +0 -120
- data/doc/classes/TestBlocker/BBString.html +0 -120
- data/doc/classes/TestBlocker/BBSub1.html +0 -120
- data/doc/classes/TestBlocker/BBSub2.html +0 -120
- data/doc/classes/TestBlocker/BBTest1.html +0 -120
- data/doc/classes/TestBlocker/BBTest2.html +0 -120
- data/doc/classes/TestBlocker/BBTest3.html +0 -120
- data/doc/classes/TestBlocker/BBTest4.html +0 -120
- data/doc/classes/TestBlocker/BBTest5.html +0 -120
- data/doc/classes/TestBlocker/BBTest6.html +0 -120
- data/doc/classes/TestBlocker/BBTest7.html +0 -120
- data/doc/classes/TestBlocker/BBTime.html +0 -120
- data/doc/classes/TestBlocker/BBUTF16.html +0 -120
- data/doc/classes/TestBlocker/ItemA.html +0 -120
- data/doc/classes/TestBlocker/ItemB.html +0 -120
- data/doc/classes/TestBlocker.html +0 -802
- data/doc/contents.hhc +0 -670
- data/doc/created.rid +0 -1
- data/doc/dot/f_0.dot +0 -208
- data/doc/dot/f_0.png +0 -0
- data/doc/dot/f_1.dot +0 -23
- data/doc/dot/f_1.png +0 -0
- data/doc/dot/f_2.dot +0 -32
- data/doc/dot/f_2.png +0 -0
- data/doc/dot/m_0_0.dot +0 -208
- data/doc/dot/m_0_0.png +0 -0
- data/doc/files/lib/blocker_rb.html +0 -144
- data/doc/files/lib/buffered_io_rb.html +0 -115
- data/doc/files/test/test_blocker_rb.html +0 -116
- data/doc/fr_class_index.html +0 -60
- data/doc/fr_file_index.html +0 -29
- data/doc/fr_method_index.html +0 -135
- data/doc/index.hhk +0 -599
- data/doc/index.html +0 -24
- data/doc/rdoc-style.css +0 -208
- data/doc/rdoc.hhp +0 -15
@@ -1,220 +0,0 @@
|
|
1
|
-
|
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: BinaryBlocker::PackedDateEncoder</title>
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
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">BinaryBlocker::PackedDateEncoder</td>
|
54
|
-
</tr>
|
55
|
-
<tr class="top-aligned-row">
|
56
|
-
<td><strong>In:</strong></td>
|
57
|
-
<td>
|
58
|
-
<a href="../../files/lib/blocker_rb.html">
|
59
|
-
lib/blocker.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="PackedNumberEncoder.html">
|
69
|
-
PackedNumberEncoder
|
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
|
-
<div id="diagram">
|
83
|
-
<map id="map" name="map">
|
84
|
-
<area shape="rect" coords="252,146,351,194" href="GroupEncoder.html" alt="GroupEncoder" />
|
85
|
-
<area shape="rect" coords="27,242,123,290" href="ListOfEncoder.html" alt="ListOfEncoder" />
|
86
|
-
<area shape="rect" coords="147,242,219,290" href="Blocker.html" alt="Blocker" />
|
87
|
-
<area shape="rect" coords="243,242,360,290" href="FixedArrayEncoder.html" alt="FixedArrayEncoder" />
|
88
|
-
<area shape="rect" coords="384,242,517,290" href="CountedArrayEncoder.html" alt="CountedArrayEncoder" />
|
89
|
-
<area shape="rect" coords="683,50,755,98" href="Encoder.html" alt="Encoder" />
|
90
|
-
<area shape="rect" coords="605,146,707,194" href="SimpleEncoder.html" alt="SimpleEncoder" />
|
91
|
-
<area shape="rect" coords="731,146,835,194" href="BitFieldEncoder.html" alt="BitFieldEncoder" />
|
92
|
-
<area shape="rect" coords="859,146,960,194" href="OneOfEncoder.html" alt="OneOfEncoder" />
|
93
|
-
<area shape="rect" coords="541,242,683,290" href="PackedNumberEncoder.html" alt="PackedNumberEncoder" />
|
94
|
-
<area shape="rect" coords="469,338,595,386" href="PackedDateEncoder.html" alt="PackedDateEncoder" />
|
95
|
-
<area shape="rect" coords="619,338,765,386" href="PackedDateTimeEncoder.html" alt="PackedDateTimeEncoder" />
|
96
|
-
<area shape="rect" coords="707,242,827,290" href="FixedStringEncoder.html" alt="FixedStringEncoder" />
|
97
|
-
<area shape="rect" coords="851,242,1005,290" href="FixedUTF16StringEncoder.html" alt="FixedUTF16StringEncoder" />
|
98
|
-
<area shape="rect" coords="16,16,1016,396" href="../BinaryBlocker.html" alt="BinaryBlocker" />
|
99
|
-
</map>
|
100
|
-
<img src="../../dot/m_0_0.png" usemap="#map" border="0" alt="Module: BinaryBlocker" />
|
101
|
-
</div>
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
</div>
|
106
|
-
|
107
|
-
<div id="method-list">
|
108
|
-
<h3 class="section-bar">Methods</h3>
|
109
|
-
|
110
|
-
<div class="name-list">
|
111
|
-
<a href="#M000056">initialize_options</a>
|
112
|
-
<a href="#M000057">internal_block</a>
|
113
|
-
<a href="#M000058">internal_deblock</a>
|
114
|
-
</div>
|
115
|
-
</div>
|
116
|
-
|
117
|
-
</div>
|
118
|
-
|
119
|
-
|
120
|
-
<!-- if includes -->
|
121
|
-
|
122
|
-
<div id="section">
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
<!-- if method_list -->
|
132
|
-
<div id="methods">
|
133
|
-
<h3 class="section-bar">Public Instance methods</h3>
|
134
|
-
|
135
|
-
<div id="method-M000056" class="method-detail">
|
136
|
-
<a name="M000056"></a>
|
137
|
-
|
138
|
-
<div class="method-heading">
|
139
|
-
<a href="#M000056" class="method-signature">
|
140
|
-
<span class="method-name">initialize_options</span><span class="method-args">(*opts)</span>
|
141
|
-
</a>
|
142
|
-
</div>
|
143
|
-
|
144
|
-
<div class="method-description">
|
145
|
-
<p><a class="source-toggle" href="#"
|
146
|
-
onclick="toggleCode('M000056-source');return false;">[Source]</a></p>
|
147
|
-
<div class="method-source-code" id="M000056-source">
|
148
|
-
<pre>
|
149
|
-
<span class="ruby-comment cmt"># File lib/blocker.rb, line 454</span>
|
150
|
-
454: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize_options</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">opts</span>)
|
151
|
-
455: <span class="ruby-keyword kw">super</span>
|
152
|
-
456: <span class="ruby-ivar">@opts</span>[<span class="ruby-identifier">:length</span>] = <span class="ruby-value">8</span>
|
153
|
-
457: <span class="ruby-keyword kw">end</span>
|
154
|
-
</pre>
|
155
|
-
</div>
|
156
|
-
</div>
|
157
|
-
</div>
|
158
|
-
|
159
|
-
<div id="method-M000057" class="method-detail">
|
160
|
-
<a name="M000057"></a>
|
161
|
-
|
162
|
-
<div class="method-heading">
|
163
|
-
<a href="#M000057" class="method-signature">
|
164
|
-
<span class="method-name">internal_block</span><span class="method-args">(val)</span>
|
165
|
-
</a>
|
166
|
-
</div>
|
167
|
-
|
168
|
-
<div class="method-description">
|
169
|
-
<p><a class="source-toggle" href="#"
|
170
|
-
onclick="toggleCode('M000057-source');return false;">[Source]</a></p>
|
171
|
-
<div class="method-source-code" id="M000057-source">
|
172
|
-
<pre>
|
173
|
-
<span class="ruby-comment cmt"># File lib/blocker.rb, line 459</span>
|
174
|
-
459: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">internal_block</span>(<span class="ruby-identifier">val</span>)
|
175
|
-
460: <span class="ruby-keyword kw">super</span> <span class="ruby-identifier">val</span>.<span class="ruby-identifier">year</span> <span class="ruby-operator">*</span> <span class="ruby-value">10000</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">val</span>.<span class="ruby-identifier">month</span> <span class="ruby-operator">*</span> <span class="ruby-value">100</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">val</span>.<span class="ruby-identifier">mday</span>
|
176
|
-
461: <span class="ruby-keyword kw">end</span>
|
177
|
-
</pre>
|
178
|
-
</div>
|
179
|
-
</div>
|
180
|
-
</div>
|
181
|
-
|
182
|
-
<div id="method-M000058" class="method-detail">
|
183
|
-
<a name="M000058"></a>
|
184
|
-
|
185
|
-
<div class="method-heading">
|
186
|
-
<a href="#M000058" class="method-signature">
|
187
|
-
<span class="method-name">internal_deblock</span><span class="method-args">(io)</span>
|
188
|
-
</a>
|
189
|
-
</div>
|
190
|
-
|
191
|
-
<div class="method-description">
|
192
|
-
<p><a class="source-toggle" href="#"
|
193
|
-
onclick="toggleCode('M000058-source');return false;">[Source]</a></p>
|
194
|
-
<div class="method-source-code" id="M000058-source">
|
195
|
-
<pre>
|
196
|
-
<span class="ruby-comment cmt"># File lib/blocker.rb, line 463</span>
|
197
|
-
463: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">internal_deblock</span>(<span class="ruby-identifier">io</span>)
|
198
|
-
464: <span class="ruby-identifier">buffer</span> = <span class="ruby-identifier">io</span>.<span class="ruby-identifier">read</span>(<span class="ruby-ivar">@bytes</span>)
|
199
|
-
465: <span class="ruby-identifier">result</span> = <span class="ruby-identifier">buffer</span>.<span class="ruby-identifier">unpack</span>(<span class="ruby-ivar">@format</span>)
|
200
|
-
466: <span class="ruby-identifier">year</span>, <span class="ruby-identifier">month</span>, <span class="ruby-identifier">day</span> = <span class="ruby-identifier">result</span>.<span class="ruby-identifier">first</span>.<span class="ruby-identifier">unpack</span>(<span class="ruby-value str">"A4A2A2"</span>).<span class="ruby-identifier">map</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">v</span><span class="ruby-operator">|</span> <span class="ruby-identifier">v</span>.<span class="ruby-identifier">to_i</span> }
|
201
|
-
467: <span class="ruby-constant">Date</span>.<span class="ruby-identifier">civil</span>(<span class="ruby-identifier">year</span>, <span class="ruby-identifier">month</span>, <span class="ruby-identifier">day</span>)
|
202
|
-
468: <span class="ruby-keyword kw">end</span>
|
203
|
-
</pre>
|
204
|
-
</div>
|
205
|
-
</div>
|
206
|
-
</div>
|
207
|
-
|
208
|
-
|
209
|
-
</div>
|
210
|
-
|
211
|
-
|
212
|
-
</div>
|
213
|
-
|
214
|
-
|
215
|
-
<div id="validator-badges">
|
216
|
-
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
217
|
-
</div>
|
218
|
-
|
219
|
-
</body>
|
220
|
-
</html>
|
@@ -1,220 +0,0 @@
|
|
1
|
-
|
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: BinaryBlocker::PackedDateTimeEncoder</title>
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
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">BinaryBlocker::PackedDateTimeEncoder</td>
|
54
|
-
</tr>
|
55
|
-
<tr class="top-aligned-row">
|
56
|
-
<td><strong>In:</strong></td>
|
57
|
-
<td>
|
58
|
-
<a href="../../files/lib/blocker_rb.html">
|
59
|
-
lib/blocker.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="PackedNumberEncoder.html">
|
69
|
-
PackedNumberEncoder
|
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
|
-
<div id="diagram">
|
83
|
-
<map id="map" name="map">
|
84
|
-
<area shape="rect" coords="252,146,351,194" href="GroupEncoder.html" alt="GroupEncoder" />
|
85
|
-
<area shape="rect" coords="27,242,123,290" href="ListOfEncoder.html" alt="ListOfEncoder" />
|
86
|
-
<area shape="rect" coords="147,242,219,290" href="Blocker.html" alt="Blocker" />
|
87
|
-
<area shape="rect" coords="243,242,360,290" href="FixedArrayEncoder.html" alt="FixedArrayEncoder" />
|
88
|
-
<area shape="rect" coords="384,242,517,290" href="CountedArrayEncoder.html" alt="CountedArrayEncoder" />
|
89
|
-
<area shape="rect" coords="683,50,755,98" href="Encoder.html" alt="Encoder" />
|
90
|
-
<area shape="rect" coords="605,146,707,194" href="SimpleEncoder.html" alt="SimpleEncoder" />
|
91
|
-
<area shape="rect" coords="731,146,835,194" href="BitFieldEncoder.html" alt="BitFieldEncoder" />
|
92
|
-
<area shape="rect" coords="859,146,960,194" href="OneOfEncoder.html" alt="OneOfEncoder" />
|
93
|
-
<area shape="rect" coords="541,242,683,290" href="PackedNumberEncoder.html" alt="PackedNumberEncoder" />
|
94
|
-
<area shape="rect" coords="469,338,595,386" href="PackedDateEncoder.html" alt="PackedDateEncoder" />
|
95
|
-
<area shape="rect" coords="619,338,765,386" href="PackedDateTimeEncoder.html" alt="PackedDateTimeEncoder" />
|
96
|
-
<area shape="rect" coords="707,242,827,290" href="FixedStringEncoder.html" alt="FixedStringEncoder" />
|
97
|
-
<area shape="rect" coords="851,242,1005,290" href="FixedUTF16StringEncoder.html" alt="FixedUTF16StringEncoder" />
|
98
|
-
<area shape="rect" coords="16,16,1016,396" href="../BinaryBlocker.html" alt="BinaryBlocker" />
|
99
|
-
</map>
|
100
|
-
<img src="../../dot/m_0_0.png" usemap="#map" border="0" alt="Module: BinaryBlocker" />
|
101
|
-
</div>
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
</div>
|
106
|
-
|
107
|
-
<div id="method-list">
|
108
|
-
<h3 class="section-bar">Methods</h3>
|
109
|
-
|
110
|
-
<div class="name-list">
|
111
|
-
<a href="#M000083">initialize_options</a>
|
112
|
-
<a href="#M000084">internal_block</a>
|
113
|
-
<a href="#M000085">internal_deblock</a>
|
114
|
-
</div>
|
115
|
-
</div>
|
116
|
-
|
117
|
-
</div>
|
118
|
-
|
119
|
-
|
120
|
-
<!-- if includes -->
|
121
|
-
|
122
|
-
<div id="section">
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
<!-- if method_list -->
|
132
|
-
<div id="methods">
|
133
|
-
<h3 class="section-bar">Public Instance methods</h3>
|
134
|
-
|
135
|
-
<div id="method-M000083" class="method-detail">
|
136
|
-
<a name="M000083"></a>
|
137
|
-
|
138
|
-
<div class="method-heading">
|
139
|
-
<a href="#M000083" class="method-signature">
|
140
|
-
<span class="method-name">initialize_options</span><span class="method-args">(*opts)</span>
|
141
|
-
</a>
|
142
|
-
</div>
|
143
|
-
|
144
|
-
<div class="method-description">
|
145
|
-
<p><a class="source-toggle" href="#"
|
146
|
-
onclick="toggleCode('M000083-source');return false;">[Source]</a></p>
|
147
|
-
<div class="method-source-code" id="M000083-source">
|
148
|
-
<pre>
|
149
|
-
<span class="ruby-comment cmt"># File lib/blocker.rb, line 474</span>
|
150
|
-
474: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize_options</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">opts</span>)
|
151
|
-
475: <span class="ruby-keyword kw">super</span>
|
152
|
-
476: <span class="ruby-ivar">@opts</span>[<span class="ruby-identifier">:length</span>] = <span class="ruby-value">14</span>
|
153
|
-
477: <span class="ruby-keyword kw">end</span>
|
154
|
-
</pre>
|
155
|
-
</div>
|
156
|
-
</div>
|
157
|
-
</div>
|
158
|
-
|
159
|
-
<div id="method-M000084" class="method-detail">
|
160
|
-
<a name="M000084"></a>
|
161
|
-
|
162
|
-
<div class="method-heading">
|
163
|
-
<a href="#M000084" class="method-signature">
|
164
|
-
<span class="method-name">internal_block</span><span class="method-args">(val)</span>
|
165
|
-
</a>
|
166
|
-
</div>
|
167
|
-
|
168
|
-
<div class="method-description">
|
169
|
-
<p><a class="source-toggle" href="#"
|
170
|
-
onclick="toggleCode('M000084-source');return false;">[Source]</a></p>
|
171
|
-
<div class="method-source-code" id="M000084-source">
|
172
|
-
<pre>
|
173
|
-
<span class="ruby-comment cmt"># File lib/blocker.rb, line 479</span>
|
174
|
-
479: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">internal_block</span>(<span class="ruby-identifier">val</span>)
|
175
|
-
480: <span class="ruby-keyword kw">super</span> <span class="ruby-identifier">sprintf</span>(<span class="ruby-value str">"%04d%02d%02d%02d%02d%02d"</span>, <span class="ruby-identifier">val</span>.<span class="ruby-identifier">year</span>, <span class="ruby-identifier">val</span>.<span class="ruby-identifier">month</span>, <span class="ruby-identifier">val</span>.<span class="ruby-identifier">mday</span>, <span class="ruby-identifier">val</span>.<span class="ruby-identifier">hour</span>, <span class="ruby-identifier">val</span>.<span class="ruby-identifier">min</span>, <span class="ruby-identifier">val</span>.<span class="ruby-identifier">sec</span>).<span class="ruby-identifier">to_i</span>
|
176
|
-
481: <span class="ruby-keyword kw">end</span>
|
177
|
-
</pre>
|
178
|
-
</div>
|
179
|
-
</div>
|
180
|
-
</div>
|
181
|
-
|
182
|
-
<div id="method-M000085" class="method-detail">
|
183
|
-
<a name="M000085"></a>
|
184
|
-
|
185
|
-
<div class="method-heading">
|
186
|
-
<a href="#M000085" class="method-signature">
|
187
|
-
<span class="method-name">internal_deblock</span><span class="method-args">(io)</span>
|
188
|
-
</a>
|
189
|
-
</div>
|
190
|
-
|
191
|
-
<div class="method-description">
|
192
|
-
<p><a class="source-toggle" href="#"
|
193
|
-
onclick="toggleCode('M000085-source');return false;">[Source]</a></p>
|
194
|
-
<div class="method-source-code" id="M000085-source">
|
195
|
-
<pre>
|
196
|
-
<span class="ruby-comment cmt"># File lib/blocker.rb, line 483</span>
|
197
|
-
483: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">internal_deblock</span>(<span class="ruby-identifier">io</span>)
|
198
|
-
484: <span class="ruby-identifier">buffer</span> = <span class="ruby-identifier">io</span>.<span class="ruby-identifier">read</span>(<span class="ruby-ivar">@bytes</span>)
|
199
|
-
485: <span class="ruby-identifier">result</span> = <span class="ruby-identifier">buffer</span>.<span class="ruby-identifier">unpack</span>(<span class="ruby-ivar">@format</span>)
|
200
|
-
486: <span class="ruby-identifier">year</span>, <span class="ruby-identifier">month</span>, <span class="ruby-identifier">day</span>, <span class="ruby-identifier">hour</span>, <span class="ruby-identifier">min</span>, <span class="ruby-identifier">sec</span> = <span class="ruby-identifier">result</span>.<span class="ruby-identifier">first</span>.<span class="ruby-identifier">unpack</span>(<span class="ruby-value str">"A4A2A2A2A2A2"</span>).<span class="ruby-identifier">map</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">v</span><span class="ruby-operator">|</span> <span class="ruby-identifier">v</span>.<span class="ruby-identifier">to_i</span> }
|
201
|
-
487: <span class="ruby-constant">Time</span>.<span class="ruby-identifier">local</span>(<span class="ruby-identifier">year</span>, <span class="ruby-identifier">month</span>, <span class="ruby-identifier">day</span>, <span class="ruby-identifier">hour</span>, <span class="ruby-identifier">min</span>, <span class="ruby-identifier">sec</span>)
|
202
|
-
488: <span class="ruby-keyword kw">end</span>
|
203
|
-
</pre>
|
204
|
-
</div>
|
205
|
-
</div>
|
206
|
-
</div>
|
207
|
-
|
208
|
-
|
209
|
-
</div>
|
210
|
-
|
211
|
-
|
212
|
-
</div>
|
213
|
-
|
214
|
-
|
215
|
-
<div id="validator-badges">
|
216
|
-
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
217
|
-
</div>
|
218
|
-
|
219
|
-
</body>
|
220
|
-
</html>
|