eymiha_util 1.0.1 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/gem_package.rb +1 -1
- data/html/classes/Eymiha.html +150 -158
- data/html/classes/Eymiha/BaseEnvelope.html +203 -203
- data/html/classes/Eymiha/BaseEnvelope.src/M000015.html +17 -19
- data/html/classes/Eymiha/BaseEnvelope.src/M000016.html +19 -17
- data/html/classes/Eymiha/{Envelope.src/M000051.html → BaseEnvelope.src/M000017.html} +17 -17
- data/html/classes/Eymiha/EasyLog.html +272 -245
- data/html/classes/Eymiha/EasyLog.src/M000001.html +15 -15
- data/html/classes/Eymiha/EasyLog.src/M000002.html +15 -15
- data/html/classes/Eymiha/EasyLog.src/M000003.html +15 -15
- data/html/classes/Eymiha/EasyLog.src/M000004.html +15 -15
- data/html/classes/Eymiha/{StringMapFormat.src/M000025.html → EasyLog.src/M000005.html} +17 -16
- data/html/classes/Eymiha/EasyLogFormatter.html +191 -191
- data/html/classes/Eymiha/EasyLogFormatter.src/M000018.html +20 -17
- data/html/classes/Eymiha/EasyLogFormatter.src/M000019.html +17 -17
- data/html/classes/Eymiha/EasyLogFormatter.src/M000020.html +20 -0
- data/html/classes/Eymiha/EasyLogger.html +246 -217
- data/html/classes/Eymiha/EasyLogger.src/{M000032.html → M000024.html} +15 -15
- data/html/classes/Eymiha/EasyLogger.src/{M000033.html → M000025.html} +17 -17
- data/html/classes/Eymiha/EasyLogger.src/{M000034.html → M000026.html} +15 -15
- data/html/classes/Eymiha/EasyLogger.src/M000027.html +18 -0
- data/html/classes/Eymiha/Enum.html +110 -110
- data/html/classes/Eymiha/Envelope.html +328 -328
- data/html/classes/Eymiha/{BaseEnvelope.src/M000014.html → Envelope.src/M000037.html} +18 -17
- data/html/classes/Eymiha/Envelope.src/{M000045.html → M000038.html} +15 -15
- data/html/classes/Eymiha/Envelope.src/{M000046.html → M000039.html} +15 -15
- data/html/classes/Eymiha/Envelope.src/{M000047.html → M000040.html} +15 -15
- data/html/classes/Eymiha/Envelope.src/{M000048.html → M000041.html} +15 -15
- data/html/classes/Eymiha/Envelope.src/{M000049.html → M000042.html} +15 -15
- data/html/classes/Eymiha/Envelope.src/M000044.html +17 -18
- data/html/classes/Eymiha/EnvelopeException.html +118 -118
- data/html/classes/Eymiha/ForwardReference.html +203 -203
- data/html/classes/Eymiha/ForwardReference.src/{M000054.html → M000045.html} +20 -20
- data/html/classes/Eymiha/ForwardReference.src/{M000055.html → M000046.html} +17 -17
- data/html/classes/Eymiha/ForwardReferencer.html +180 -180
- data/html/classes/Eymiha/ForwardReferencing.html +319 -319
- data/html/classes/Eymiha/ForwardReferencing.src/M000006.html +19 -19
- data/html/classes/Eymiha/ForwardReferencing.src/M000007.html +19 -19
- data/html/classes/Eymiha/ForwardReferencing.src/M000008.html +19 -31
- data/html/classes/Eymiha/ForwardReferencing.src/M000009.html +31 -17
- data/html/classes/Eymiha/ForwardReferencing.src/M000010.html +17 -24
- data/html/classes/Eymiha/ForwardReferencing.src/M000011.html +24 -17
- data/html/classes/Eymiha/ForwardReferencing.src/M000012.html +17 -17
- data/html/classes/Eymiha/ForwardReferencing.src/M000013.html +17 -17
- data/html/classes/Eymiha/ForwardReferencing.src/M000014.html +18 -0
- data/html/classes/Eymiha/Histogram.html +324 -324
- data/html/classes/Eymiha/Histogram.src/M000028.html +19 -0
- data/html/classes/Eymiha/Histogram.src/M000029.html +21 -0
- data/html/classes/Eymiha/Histogram.src/{M000037.html → M000030.html} +15 -15
- data/html/classes/Eymiha/Histogram.src/{M000038.html → M000031.html} +15 -15
- data/html/classes/Eymiha/Histogram.src/{M000039.html → M000032.html} +15 -15
- data/html/classes/Eymiha/Histogram.src/{M000040.html → M000033.html} +15 -15
- data/html/classes/Eymiha/Histogram.src/{M000041.html → M000034.html} +15 -15
- data/html/classes/Eymiha/Histogram.src/M000035.html +19 -18
- data/html/classes/Eymiha/Histogram.src/M000036.html +23 -20
- data/html/classes/Eymiha/HistogramException.html +117 -117
- data/html/classes/Eymiha/MethodicHash.html +221 -221
- data/html/classes/Eymiha/MethodicHash.src/{M000026.html → M000021.html} +15 -15
- data/html/classes/Eymiha/MethodicHash.src/{M000027.html → M000022.html} +15 -15
- data/html/classes/Eymiha/MethodicHash.src/{M000028.html → M000023.html} +15 -15
- data/html/created.rid +1 -1
- data/html/files/lib/eymiha/util/easylog_rb.html +115 -115
- data/html/files/lib/eymiha/util/enum_rb.html +122 -122
- data/html/files/lib/eymiha/util/envelope_rb.html +108 -108
- data/html/files/lib/eymiha/util/forward_referencing_rb.html +117 -117
- data/html/files/lib/eymiha/util/histogram_rb.html +108 -108
- data/html/files/lib/eymiha/util/methodic_hash_rb.html +100 -100
- data/html/files/lib/eymiha/util_rb.html +112 -112
- data/html/fr_class_index.html +39 -43
- data/html/fr_file_index.html +32 -33
- data/html/fr_method_index.html +71 -80
- data/html/index.html +23 -23
- data/html/rdoc-style.css +207 -207
- data/lib/eymiha/util/easylog.rb +59 -14
- data/test/tc_easylog.rb +200 -0
- metadata +75 -86
- data/html/classes/Eymiha/EasyLogFormatter.src/M000017.html +0 -21
- data/html/classes/Eymiha/ForwardReferencing.src/M000005.html +0 -20
- data/html/classes/Eymiha/Histogram.src/M000042.html +0 -20
- data/html/classes/Eymiha/Histogram.src/M000043.html +0 -24
- data/html/classes/Eymiha/StringMap.html +0 -184
- data/html/classes/Eymiha/StringMap.src/M000029.html +0 -18
- data/html/classes/Eymiha/StringMap.src/M000030.html +0 -18
- data/html/classes/Eymiha/StringMap.src/M000031.html +0 -18
- data/html/classes/Eymiha/StringMapException.html +0 -111
- data/html/classes/Eymiha/StringMapFormat.html +0 -227
- data/html/classes/Eymiha/StringMapFormat.src/M000020.html +0 -20
- data/html/classes/Eymiha/StringMapFormat.src/M000021.html +0 -19
- data/html/classes/Eymiha/StringMapFormat.src/M000022.html +0 -18
- data/html/classes/Eymiha/StringMapFormat.src/M000023.html +0 -22
- data/html/classes/Eymiha/StringMapFormat.src/M000024.html +0 -19
- data/html/classes/Eymiha/StringMapFormatItem.html +0 -156
- data/html/classes/Eymiha/StringMapFormatItem.src/M000052.html +0 -21
- data/html/classes/Eymiha/StringMapFormatItem.src/M000053.html +0 -18
- data/html/files/lib/eymiha/util/string_map_rb.html +0 -101
- data/lib/eymiha/util/string_map.rb +0 -78
@@ -1,18 +1,21 @@
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-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>
|
7
|
-
<head>
|
8
|
-
<title>
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
-
<link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
-
</head>
|
12
|
-
<body class="standalone-code">
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/eymiha/util/easylog.rb, line
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">
|
15
|
-
<span class="ruby-
|
16
|
-
|
17
|
-
</
|
1
|
+
<?xml version="1.0" encoding="iso-8859-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>
|
7
|
+
<head>
|
8
|
+
<title>new (Eymiha::EasyLogFormatter)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/eymiha/util/easylog.rb, line 15</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">subsecond_precision</span> = <span class="ruby-keyword kw">nil</span>)
|
15
|
+
<span class="ruby-keyword kw">super</span>()
|
16
|
+
<span class="ruby-ivar">@AppLogFormat</span> = <span class="ruby-value str">"%s %-5s %s\n"</span>
|
17
|
+
<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">datetime_format</span> = <span class="ruby-value str">"%m/%d/%y %H:%M:%S."</span>
|
18
|
+
<span class="ruby-ivar">@usecs</span> = <span class="ruby-identifier">subsecond_precision</span> <span class="ruby-operator">||</span> <span class="ruby-constant">Time</span>.<span class="ruby-identifier">subsecond_precision</span>
|
19
|
+
<span class="ruby-keyword kw">end</span></pre>
|
20
|
+
</body>
|
18
21
|
</html>
|
@@ -1,18 +1,18 @@
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-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>
|
7
|
-
<head>
|
8
|
-
<title>
|
9
|
-
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
-
<link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
-
</head>
|
12
|
-
<body class="standalone-code">
|
13
|
-
<pre><span class="ruby-comment cmt"># File lib/eymiha/util/easylog.rb, line
|
14
|
-
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">
|
15
|
-
<span class="ruby-
|
16
|
-
<span class="ruby-keyword kw">end</span></pre>
|
17
|
-
</body>
|
1
|
+
<?xml version="1.0" encoding="iso-8859-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>
|
7
|
+
<head>
|
8
|
+
<title>format_datetime (Eymiha::EasyLogFormatter)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/eymiha/util/easylog.rb, line 25</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">format_datetime</span>(<span class="ruby-identifier">time</span>)
|
15
|
+
<span class="ruby-identifier">time</span>.<span class="ruby-identifier">strftime</span>(<span class="ruby-identifier">datetime_format</span>) <span class="ruby-operator"><<</span> (<span class="ruby-value str">"%06d"</span> <span class="ruby-operator">%</span> <span class="ruby-identifier">time</span>.<span class="ruby-identifier">usec</span>)[<span class="ruby-value">0</span>,<span class="ruby-ivar">@usecs</span>]
|
16
|
+
<span class="ruby-keyword kw">end</span></pre>
|
17
|
+
</body>
|
18
18
|
</html>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-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>
|
7
|
+
<head>
|
8
|
+
<title>call (Eymiha::EasyLogFormatter)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/eymiha/util/easylog.rb, line 31</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">call</span>(<span class="ruby-identifier">severity</span>, <span class="ruby-identifier">time</span>, <span class="ruby-identifier">progname</span>, <span class="ruby-identifier">msg</span>)
|
15
|
+
(<span class="ruby-identifier">msg</span> <span class="ruby-operator">==</span> <span class="ruby-value str">""</span>) <span class="ruby-operator">?</span>
|
16
|
+
<span class="ruby-value str">"\n"</span> <span class="ruby-operator">:</span>
|
17
|
+
(<span class="ruby-ivar">@AppLogFormat</span> <span class="ruby-operator">%</span> [<span class="ruby-identifier">format_datetime</span>(<span class="ruby-identifier">time</span>), <span class="ruby-identifier">severity</span>, <span class="ruby-identifier">msg2str</span>(<span class="ruby-identifier">msg</span>)])
|
18
|
+
<span class="ruby-keyword kw">end</span></pre>
|
19
|
+
</body>
|
20
|
+
</html>
|
@@ -1,218 +1,247 @@
|
|
1
|
-
<?xml version="1.0" encoding="iso-8859-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: Eymiha::EasyLogger</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">Eymiha::EasyLogger</td>
|
54
|
-
</tr>
|
55
|
-
<tr class="top-aligned-row">
|
56
|
-
<td><strong>In:</strong></td>
|
57
|
-
<td>
|
58
|
-
<a href="../../files/lib/eymiha/util/easylog_rb.html">
|
59
|
-
lib/eymiha/util/easylog.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
|
-
Logger
|
69
|
-
</td>
|
70
|
-
</tr>
|
71
|
-
</table>
|
72
|
-
</div>
|
73
|
-
<!-- banner header -->
|
74
|
-
|
75
|
-
<div id="bodyContent">
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
<div id="contextContent">
|
80
|
-
|
81
|
-
<div id="description">
|
82
|
-
<p>
|
83
|
-
Primarily, <a href="EasyLogger.html">EasyLogger</a> provides a convienient
|
84
|
-
interface to the Logger at the class
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
</
|
91
|
-
|
92
|
-
|
93
|
-
methods
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
</div>
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
<div class="method-
|
185
|
-
<
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
</div>
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
<
|
214
|
-
|
215
|
-
</
|
216
|
-
|
217
|
-
</body>
|
1
|
+
<?xml version="1.0" encoding="iso-8859-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: Eymiha::EasyLogger</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">Eymiha::EasyLogger</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../../files/lib/eymiha/util/easylog_rb.html">
|
59
|
+
lib/eymiha/util/easylog.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
|
+
Logger
|
69
|
+
</td>
|
70
|
+
</tr>
|
71
|
+
</table>
|
72
|
+
</div>
|
73
|
+
<!-- banner header -->
|
74
|
+
|
75
|
+
<div id="bodyContent">
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
<div id="contextContent">
|
80
|
+
|
81
|
+
<div id="description">
|
82
|
+
<p>
|
83
|
+
Primarily, <a href="EasyLogger.html">EasyLogger</a> provides a convienient
|
84
|
+
interface to the Logger at the class <a
|
85
|
+
href="EasyLogger.html#M000027">level</a>. The class contains a
|
86
|
+
"default" instance of Logger to which the class methods send
|
87
|
+
their log messages. By convention, the first instance created is made the
|
88
|
+
default, however this can be changed. Of course, instances may be used
|
89
|
+
directly for logging if desired. Instances format their log entries using
|
90
|
+
an <a href="EasyLogFormatter.html">EasyLogFormatter</a>.
|
91
|
+
</p>
|
92
|
+
<p>
|
93
|
+
Five class methods are built that have the same names as the instance
|
94
|
+
methods: debug, info, warn, error and fatal. Their arguments are different,
|
95
|
+
however, being the message to be logged and optionally, one or more Loggers
|
96
|
+
to log the message. If no Loggers are passed, the default is used, and if
|
97
|
+
that is nil,no logging takes place.
|
98
|
+
</p>
|
99
|
+
<p>
|
100
|
+
Two other convenience class methods for each of the five Logger severities
|
101
|
+
are also provided for checking and adjusting the threshold levels of the
|
102
|
+
default logger. The debug?, info?, warn?, error? and fatal? methods return
|
103
|
+
true if a message at that <a href="EasyLogger.html#M000027">level</a> will
|
104
|
+
be reported by the default logger. Respectively, the level_debug,
|
105
|
+
level_info, level_warn, level_error and level_fatal methods will set the
|
106
|
+
threshold of the default logger to pass only messages at or above the
|
107
|
+
selected severity.
|
108
|
+
</p>
|
109
|
+
|
110
|
+
</div>
|
111
|
+
|
112
|
+
|
113
|
+
</div>
|
114
|
+
|
115
|
+
<div id="method-list">
|
116
|
+
<h3 class="section-bar">Methods</h3>
|
117
|
+
|
118
|
+
<div class="name-list">
|
119
|
+
<a href="#M000025">change_logger</a>
|
120
|
+
<a href="#M000026">finish_logging</a>
|
121
|
+
<a href="#M000027">level</a>
|
122
|
+
<a href="#M000024">new</a>
|
123
|
+
</div>
|
124
|
+
</div>
|
125
|
+
|
126
|
+
</div>
|
127
|
+
|
128
|
+
|
129
|
+
<!-- if includes -->
|
130
|
+
|
131
|
+
<div id="section">
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
|
136
|
+
|
137
|
+
<div id="attribute-list">
|
138
|
+
<h3 class="section-bar">Attributes</h3>
|
139
|
+
|
140
|
+
<div class="name-list">
|
141
|
+
<table>
|
142
|
+
<tr class="top-aligned-row context-row">
|
143
|
+
<td class="context-item-name">classify</td>
|
144
|
+
<td class="context-item-value"> [RW] </td>
|
145
|
+
<td class="context-item-desc"></td>
|
146
|
+
</tr>
|
147
|
+
</table>
|
148
|
+
</div>
|
149
|
+
</div>
|
150
|
+
|
151
|
+
|
152
|
+
|
153
|
+
<!-- if method_list -->
|
154
|
+
<div id="methods">
|
155
|
+
<h3 class="section-bar">Public Class methods</h3>
|
156
|
+
|
157
|
+
<div id="method-M000025" class="method-detail">
|
158
|
+
<a name="M000025"></a>
|
159
|
+
|
160
|
+
<div class="method-heading">
|
161
|
+
<a href="EasyLogger.src/M000025.html" target="Code" class="method-signature"
|
162
|
+
onclick="popupCode('EasyLogger.src/M000025.html');return false;">
|
163
|
+
<span class="method-name">change_logger</span><span class="method-args">(logger)</span>
|
164
|
+
</a>
|
165
|
+
</div>
|
166
|
+
|
167
|
+
<div class="method-description">
|
168
|
+
<p>
|
169
|
+
Changes the default logger to the given logger.
|
170
|
+
</p>
|
171
|
+
</div>
|
172
|
+
</div>
|
173
|
+
|
174
|
+
<div id="method-M000026" class="method-detail">
|
175
|
+
<a name="M000026"></a>
|
176
|
+
|
177
|
+
<div class="method-heading">
|
178
|
+
<a href="EasyLogger.src/M000026.html" target="Code" class="method-signature"
|
179
|
+
onclick="popupCode('EasyLogger.src/M000026.html');return false;">
|
180
|
+
<span class="method-name">finish_logging</span><span class="method-args">()</span>
|
181
|
+
</a>
|
182
|
+
</div>
|
183
|
+
|
184
|
+
<div class="method-description">
|
185
|
+
<p>
|
186
|
+
Sets the default logger to nil, indicating that further logging by the
|
187
|
+
class through the default logger mechanism is disabled.
|
188
|
+
</p>
|
189
|
+
</div>
|
190
|
+
</div>
|
191
|
+
|
192
|
+
<div id="method-M000027" class="method-detail">
|
193
|
+
<a name="M000027"></a>
|
194
|
+
|
195
|
+
<div class="method-heading">
|
196
|
+
<a href="EasyLogger.src/M000027.html" target="Code" class="method-signature"
|
197
|
+
onclick="popupCode('EasyLogger.src/M000027.html');return false;">
|
198
|
+
<span class="method-name">level</span><span class="method-args">()</span>
|
199
|
+
</a>
|
200
|
+
</div>
|
201
|
+
|
202
|
+
<div class="method-description">
|
203
|
+
<p>
|
204
|
+
Returns the threshold of the default logger if it exists, otherwise nil.
|
205
|
+
</p>
|
206
|
+
</div>
|
207
|
+
</div>
|
208
|
+
|
209
|
+
<div id="method-M000024" class="method-detail">
|
210
|
+
<a name="M000024"></a>
|
211
|
+
|
212
|
+
<div class="method-heading">
|
213
|
+
<a href="EasyLogger.src/M000024.html" target="Code" class="method-signature"
|
214
|
+
onclick="popupCode('EasyLogger.src/M000024.html');return false;">
|
215
|
+
<span class="method-name">new</span><span class="method-args">(logdev, shift_age = 'weekly', shift_size = 1048576,
|
218
216
|
subsecond_precision = nil)</span>
|
217
|
+
</a>
|
218
|
+
</div>
|
219
|
+
|
220
|
+
<div class="method-description">
|
221
|
+
<p>
|
222
|
+
Creates a <a href="EasyLogger.html#M000024">new</a> <a
|
223
|
+
href="EasyLogger.html">EasyLogger</a> instance. Logging is recorded through
|
224
|
+
the given logdev, either an IO stream or to a file when logdev is a String
|
225
|
+
containing its filename. Shift age is either the number of log files to
|
226
|
+
keep, or the frequency of rotation. Shift size is the maximum logfile size,
|
227
|
+
applicable when shift age is a number. Subsecond precision is the number of
|
228
|
+
decimal places that express fractional seconds. If this is the first
|
229
|
+
instance being created, it is remembered and used by the logging methods at
|
230
|
+
the class <a href="EasyLogger.html#M000027">level</a> as the default
|
231
|
+
logger.
|
232
|
+
</p>
|
233
|
+
</div>
|
234
|
+
</div>
|
235
|
+
|
236
|
+
|
237
|
+
</div>
|
238
|
+
|
239
|
+
|
240
|
+
</div>
|
241
|
+
|
242
|
+
|
243
|
+
<div id="validator-badges">
|
244
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
245
|
+
</div>
|
246
|
+
|
247
|
+
</body>
|
219
248
|
</html>
|