wwwjdic 13.0.0 → 16.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG +63 -1
- data/Gemfile +9 -1
- data/README.md +499 -225
- data/Rakefile +12 -3
- data/copyright.md +17 -29
- data/examples/basics.rb +55 -45
- data/examples/translate.rb +161 -86
- data/examples/uri.rb +50 -78
- data/html/CHANGELOG.html +80 -21
- data/html/COPYING_md.html +13 -24
- data/html/Gemfile.html +12 -21
- data/html/Object.html +810 -45
- data/html/README_md.html +309 -161
- data/html/Rakefile.html +15 -24
- data/html/WWWJDic.html +41 -81
- data/html/WWWJDic/ParsableDuckType.html +15 -34
- data/html/WWWJDic/Parser.html +25 -64
- data/html/WWWJDic/Parsers.html +8 -13
- data/html/WWWJDic/Parsers/Dict.html +29 -54
- data/html/WWWJDic/Parsers/Display.html +24 -47
- data/html/WWWJDic/Parsers/Key.html +25 -48
- data/html/WWWJDic/Parsers/Search.html +19 -38
- data/html/WWWJDic/Parsers/Server.html +24 -47
- data/html/WWWJDic/Splitter.html +49 -142
- data/html/WWWJDic/Utils.html +9 -14
- data/html/WWWJDic/Utils/Downloader.html +8 -13
- data/html/WWWJDic/Utils/Downloader/Downloader.html +29 -63
- data/html/WWWJDic/Utils/Raisers.html +21 -72
- data/html/WWWJDic/WWWJDic.html +131 -312
- data/html/copyright_md.html +206 -225
- data/html/created.rid +33 -58
- data/html/css/rdoc.css +35 -6
- data/html/index.html +301 -169
- data/html/js/darkfish.js +22 -99
- data/html/js/navigation.js +4 -40
- data/html/js/navigation.js.gz +0 -0
- data/html/js/search.js +32 -31
- data/html/js/search_index.js +1 -1
- data/html/js/search_index.js.gz +0 -0
- data/html/js/searcher.js +6 -6
- data/html/js/searcher.js.gz +0 -0
- data/html/table_of_contents.html +160 -197
- data/lib/wwwjdic.rb +16 -15
- data/lib/wwwjdic/application.rb +69 -36
- data/lib/wwwjdic/constants.rb +48 -10
- data/lib/wwwjdic/locales/de.yml +9 -4
- data/lib/wwwjdic/locales/en.yml +9 -4
- data/lib/wwwjdic/locales/es.yml +9 -4
- data/lib/wwwjdic/locales/fr.yml +9 -4
- data/lib/wwwjdic/locales/hu.yml +9 -4
- data/lib/wwwjdic/locales/it.yml +9 -4
- data/lib/wwwjdic/locales/ja.yml +11 -5
- data/lib/wwwjdic/locales/nl.yml +9 -4
- data/lib/wwwjdic/locales/ru.yml +9 -4
- data/lib/wwwjdic/locales/sl.yml +9 -4
- data/lib/wwwjdic/locales/sv.yml +9 -4
- data/lib/wwwjdic/parser.rb +15 -8
- data/lib/wwwjdic/parsers/dict.rb +13 -8
- data/lib/wwwjdic/parsers/display.rb +10 -3
- data/lib/wwwjdic/parsers/key.rb +11 -3
- data/lib/wwwjdic/parsers/search.rb +12 -3
- data/lib/wwwjdic/parsers/server.rb +10 -3
- data/lib/wwwjdic/utils/downloader.rb +27 -30
- data/lib/wwwjdic/utils/raisers.rb +14 -15
- data/lib/wwwjdic/utils/splitter.rb +33 -18
- data/lib/wwwjdic/version.rb +28 -20
- data/test/test_helper.rb +12 -1
- data/test/test_wwwjdic.rb +12 -4
- data/test/wwwjdic/locales/de.yml +9 -1
- data/test/wwwjdic/locales/en.yml +9 -1
- data/test/wwwjdic/locales/es.yml +9 -1
- data/test/wwwjdic/locales/fr.yml +9 -1
- data/test/wwwjdic/locales/hu.yml +9 -1
- data/test/wwwjdic/locales/it.yml +10 -1
- data/test/wwwjdic/locales/ja.yml +11 -2
- data/test/wwwjdic/locales/nl.yml +9 -1
- data/test/wwwjdic/locales/ru.yml +9 -1
- data/test/wwwjdic/locales/sl.yml +9 -1
- data/test/wwwjdic/locales/sv.yml +9 -1
- data/test/wwwjdic/locales/test_locales.rb +43 -24
- data/test/wwwjdic/parsers/test_dict.rb +67 -37
- data/test/wwwjdic/parsers/test_display.rb +13 -5
- data/test/wwwjdic/parsers/test_key.rb +12 -4
- data/test/wwwjdic/parsers/test_server.rb +13 -5
- data/test/wwwjdic/test_application.rb +201 -149
- data/test/wwwjdic/test_parsable_duck_type.rb +11 -6
- data/test/wwwjdic/utils/test_downloader.rb +9 -1
- data/test/wwwjdic/utils/test_raisers.rb +48 -29
- data/wwwjdic.gemspec +46 -26
- metadata +55 -43
- data/acknowledgements.md +0 -55
- data/authors.md +0 -67
- data/html/acknowledgements_md.html +0 -149
- data/html/authors_md.html +0 -181
- data/html/js/jquery.js +0 -4
- data/html/wwwjdic_gemspec.html +0 -161
data/html/created.rid
CHANGED
@@ -1,59 +1,34 @@
|
|
1
|
-
Mon,
|
2
|
-
CHANGELOG
|
1
|
+
Mon, 26 Jul 2021 10:48:17 +0200
|
2
|
+
CHANGELOG Tue, 05 Jan 2021 13:40:13 +0100
|
3
3
|
COPYING.md Mon, 25 Feb 2019 15:42:16 +0100
|
4
|
-
Gemfile
|
5
|
-
README.md Fri,
|
6
|
-
Rakefile
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
examples/
|
11
|
-
|
12
|
-
|
13
|
-
lib/wwwjdic/
|
14
|
-
lib/wwwjdic/
|
15
|
-
lib/wwwjdic/
|
16
|
-
lib/wwwjdic/
|
17
|
-
lib/wwwjdic/
|
18
|
-
lib/wwwjdic/
|
19
|
-
lib/wwwjdic/
|
20
|
-
lib/wwwjdic/
|
21
|
-
lib/wwwjdic/
|
22
|
-
lib/wwwjdic/
|
23
|
-
lib/wwwjdic
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
lib/wwwjdic/version.rb Mon, 06 May 2019 15:00:53 +0200
|
36
|
-
lib/wwwjdic.rb Tue, 23 Apr 2019 11:48:58 +0200
|
37
|
-
test/test_helper.rb Fri, 01 Mar 2019 14:50:11 +0100
|
38
|
-
test/test_wwwjdic.rb Fri, 01 Mar 2019 14:50:29 +0100
|
39
|
-
test/wwwjdic/locales/de.yml Tue, 23 Apr 2019 14:41:33 +0200
|
40
|
-
test/wwwjdic/locales/en.yml Tue, 23 Apr 2019 14:41:33 +0200
|
41
|
-
test/wwwjdic/locales/es.yml Tue, 23 Apr 2019 14:41:33 +0200
|
42
|
-
test/wwwjdic/locales/fr.yml Tue, 23 Apr 2019 14:41:33 +0200
|
43
|
-
test/wwwjdic/locales/hu.yml Tue, 23 Apr 2019 14:41:33 +0200
|
44
|
-
test/wwwjdic/locales/it.yml Tue, 23 Apr 2019 14:41:33 +0200
|
45
|
-
test/wwwjdic/locales/ja.yml Tue, 23 Apr 2019 14:41:33 +0200
|
46
|
-
test/wwwjdic/locales/nl.yml Tue, 23 Apr 2019 14:41:33 +0200
|
47
|
-
test/wwwjdic/locales/ru.yml Tue, 23 Apr 2019 14:41:33 +0200
|
48
|
-
test/wwwjdic/locales/sl.yml Tue, 23 Apr 2019 14:41:33 +0200
|
49
|
-
test/wwwjdic/locales/sv.yml Tue, 23 Apr 2019 14:41:33 +0200
|
50
|
-
test/wwwjdic/locales/test_locales.rb Fri, 01 Mar 2019 14:50:29 +0100
|
51
|
-
test/wwwjdic/parsers/test_dict.rb Tue, 23 Apr 2019 13:10:06 +0200
|
52
|
-
test/wwwjdic/parsers/test_display.rb Tue, 23 Apr 2019 13:10:06 +0200
|
53
|
-
test/wwwjdic/parsers/test_key.rb Tue, 23 Apr 2019 14:24:37 +0200
|
54
|
-
test/wwwjdic/parsers/test_server.rb Tue, 23 Apr 2019 13:10:06 +0200
|
55
|
-
test/wwwjdic/test_application.rb Tue, 23 Apr 2019 13:35:29 +0200
|
56
|
-
test/wwwjdic/test_parsable_duck_type.rb Tue, 23 Apr 2019 11:48:59 +0200
|
57
|
-
test/wwwjdic/utils/test_downloader.rb Fri, 01 Mar 2019 14:48:49 +0100
|
58
|
-
test/wwwjdic/utils/test_raisers.rb Fri, 01 Mar 2019 14:48:56 +0100
|
59
|
-
wwwjdic.gemspec Tue, 23 Apr 2019 11:48:58 +0200
|
4
|
+
Gemfile Thu, 07 Jan 2021 17:39:16 +0100
|
5
|
+
README.md Fri, 08 Jan 2021 09:28:43 +0100
|
6
|
+
Rakefile Thu, 07 Jan 2021 17:39:16 +0100
|
7
|
+
copyright.md Tue, 17 Nov 2020 12:20:01 +0100
|
8
|
+
examples/basics.rb Thu, 07 Jan 2021 17:39:32 +0100
|
9
|
+
examples/translate.rb Fri, 08 Jan 2021 08:48:15 +0100
|
10
|
+
examples/uri.rb Fri, 08 Jan 2021 08:48:48 +0100
|
11
|
+
lib/wwwjdic/application.rb Fri, 08 Jan 2021 09:13:31 +0100
|
12
|
+
lib/wwwjdic/constants.rb Thu, 07 Jan 2021 17:39:32 +0100
|
13
|
+
lib/wwwjdic/parser.rb Mon, 11 Jan 2021 10:27:43 +0100
|
14
|
+
lib/wwwjdic/parsers/dict.rb Thu, 07 Jan 2021 17:39:31 +0100
|
15
|
+
lib/wwwjdic/parsers/display.rb Thu, 07 Jan 2021 17:39:31 +0100
|
16
|
+
lib/wwwjdic/parsers/key.rb Mon, 01 Feb 2021 12:25:50 +0100
|
17
|
+
lib/wwwjdic/parsers/search.rb Thu, 07 Jan 2021 17:39:32 +0100
|
18
|
+
lib/wwwjdic/parsers/server.rb Thu, 07 Jan 2021 17:39:31 +0100
|
19
|
+
lib/wwwjdic/utils/downloader.rb Mon, 01 Feb 2021 11:01:58 +0100
|
20
|
+
lib/wwwjdic/utils/raisers.rb Thu, 07 Jan 2021 17:39:32 +0100
|
21
|
+
lib/wwwjdic/utils/splitter.rb Mon, 01 Feb 2021 12:27:49 +0100
|
22
|
+
lib/wwwjdic/version.rb Thu, 07 Jan 2021 17:39:31 +0100
|
23
|
+
lib/wwwjdic.rb Thu, 07 Jan 2021 17:39:31 +0100
|
24
|
+
test/test_helper.rb Thu, 07 Jan 2021 17:39:32 +0100
|
25
|
+
test/test_wwwjdic.rb Thu, 07 Jan 2021 17:39:31 +0100
|
26
|
+
test/wwwjdic/locales/test_locales.rb Tue, 19 Jan 2021 09:04:50 +0100
|
27
|
+
test/wwwjdic/parsers/test_dict.rb Tue, 19 Jan 2021 09:37:33 +0100
|
28
|
+
test/wwwjdic/parsers/test_display.rb Thu, 07 Jan 2021 17:39:31 +0100
|
29
|
+
test/wwwjdic/parsers/test_key.rb Thu, 07 Jan 2021 17:39:31 +0100
|
30
|
+
test/wwwjdic/parsers/test_server.rb Thu, 07 Jan 2021 17:39:31 +0100
|
31
|
+
test/wwwjdic/test_application.rb Mon, 01 Feb 2021 12:35:00 +0100
|
32
|
+
test/wwwjdic/test_parsable_duck_type.rb Thu, 07 Jan 2021 17:41:14 +0100
|
33
|
+
test/wwwjdic/utils/test_downloader.rb Thu, 07 Jan 2021 17:39:32 +0100
|
34
|
+
test/wwwjdic/utils/test_raisers.rb Tue, 19 Jan 2021 17:05:08 +0100
|
data/html/css/rdoc.css
CHANGED
@@ -9,6 +9,8 @@
|
|
9
9
|
/* vim: ft=css et sw=2 ts=2 sts=2 */
|
10
10
|
/* Base Green is: #6C8C22 */
|
11
11
|
|
12
|
+
.hide { display: none !important; }
|
13
|
+
|
12
14
|
* { padding: 0; margin: 0; }
|
13
15
|
|
14
16
|
body {
|
@@ -48,6 +50,16 @@ h6:hover span {
|
|
48
50
|
display: inline;
|
49
51
|
}
|
50
52
|
|
53
|
+
h1:target,
|
54
|
+
h2:target,
|
55
|
+
h3:target,
|
56
|
+
h4:target,
|
57
|
+
h5:target,
|
58
|
+
h6:target {
|
59
|
+
margin-left: -10px;
|
60
|
+
border-left: 10px solid #f1edba;
|
61
|
+
}
|
62
|
+
|
51
63
|
:link,
|
52
64
|
:visited {
|
53
65
|
color: #6C8C22;
|
@@ -62,6 +74,9 @@ h6:hover span {
|
|
62
74
|
code,
|
63
75
|
pre {
|
64
76
|
font-family: "Source Code Pro", Monaco, monospace;
|
77
|
+
background-color: rgba(27,31,35,0.05);
|
78
|
+
padding: 0em 0.2em;
|
79
|
+
border-radius: 0.2em;
|
65
80
|
}
|
66
81
|
|
67
82
|
/* @group Generic Classes */
|
@@ -91,7 +106,7 @@ pre {
|
|
91
106
|
|
92
107
|
.missing-docs {
|
93
108
|
font-size: 120%;
|
94
|
-
background: white url(images/wrench_orange.png) no-repeat 4px center;
|
109
|
+
background: white url(../images/wrench_orange.png) no-repeat 4px center;
|
95
110
|
color: #ccc;
|
96
111
|
line-height: 2em;
|
97
112
|
border: 1px solid #d00;
|
@@ -135,11 +150,11 @@ pre {
|
|
135
150
|
.table-of-contents li .toc-toggle {
|
136
151
|
width: 16px;
|
137
152
|
height: 16px;
|
138
|
-
background: url(images/add.png) no-repeat;
|
153
|
+
background: url(../images/add.png) no-repeat;
|
139
154
|
}
|
140
155
|
|
141
156
|
.table-of-contents li .toc-toggle.open {
|
142
|
-
background: url(images/delete.png) no-repeat;
|
157
|
+
background: url(../images/delete.png) no-repeat;
|
143
158
|
}
|
144
159
|
|
145
160
|
/* @end */
|
@@ -261,8 +276,13 @@ ul.link-list .type {
|
|
261
276
|
-webkit-border-radius: 5px;
|
262
277
|
}
|
263
278
|
|
279
|
+
dl.note-list dt {
|
280
|
+
float: left;
|
281
|
+
margin-right: 1em;
|
282
|
+
}
|
283
|
+
|
264
284
|
.calls-super {
|
265
|
-
background: url(images/arrow_up.png) no-repeat right center;
|
285
|
+
background: url(../images/arrow_up.png) no-repeat right center;
|
266
286
|
}
|
267
287
|
|
268
288
|
/* @end */
|
@@ -441,7 +461,16 @@ main header h3 {
|
|
441
461
|
/* @group Method Details */
|
442
462
|
|
443
463
|
main .method-source-code {
|
444
|
-
|
464
|
+
max-height: 0;
|
465
|
+
overflow: hidden;
|
466
|
+
transition-duration: 200ms;
|
467
|
+
transition-delay: 0ms;
|
468
|
+
transition-property: all;
|
469
|
+
transition-timing-function: ease-in-out;
|
470
|
+
}
|
471
|
+
|
472
|
+
main .method-source-code.active-menu {
|
473
|
+
max-height: 100vh;
|
445
474
|
}
|
446
475
|
|
447
476
|
main .method-description .method-calls-super {
|
@@ -479,7 +508,7 @@ main .method-click-advice {
|
|
479
508
|
visibility: hidden;
|
480
509
|
padding-right: 20px;
|
481
510
|
line-height: 20px;
|
482
|
-
background: url(images/zoom.png) no-repeat right top;
|
511
|
+
background: url(../images/zoom.png) no-repeat right top;
|
483
512
|
}
|
484
513
|
main .method-heading:hover .method-click-advice {
|
485
514
|
visibility: visible;
|
data/html/index.html
CHANGED
@@ -4,22 +4,23 @@
|
|
4
4
|
<head>
|
5
5
|
<meta charset="UTF-8">
|
6
6
|
|
7
|
-
<title>wwwjdic
|
7
|
+
<title>wwwjdic 16.0.0</title>
|
8
8
|
|
9
9
|
<script type="text/javascript">
|
10
10
|
var rdoc_rel_prefix = "./";
|
11
11
|
var index_rel_prefix = "./";
|
12
12
|
</script>
|
13
13
|
|
14
|
-
<script src="./js/
|
15
|
-
<script src="./js/
|
14
|
+
<script src="./js/navigation.js" defer></script>
|
15
|
+
<script src="./js/search.js" defer></script>
|
16
|
+
<script src="./js/search_index.js" defer></script>
|
17
|
+
<script src="./js/searcher.js" defer></script>
|
18
|
+
<script src="./js/darkfish.js" defer></script>
|
16
19
|
|
17
20
|
<link href="./css/fonts.css" rel="stylesheet">
|
18
21
|
<link href="./css/rdoc.css" rel="stylesheet">
|
19
22
|
|
20
23
|
|
21
|
-
|
22
|
-
|
23
24
|
<body id="top" role="document" class="file">
|
24
25
|
<nav role="navigation">
|
25
26
|
<div id="project-navigation">
|
@@ -54,29 +55,17 @@
|
|
54
55
|
</div>
|
55
56
|
|
56
57
|
<div id="project-metadata">
|
57
|
-
|
58
|
+
|
59
|
+
<div id="fileindex-section" class="nav-section">
|
58
60
|
<h3>Pages</h3>
|
59
61
|
|
60
62
|
<ul class="link-list">
|
61
|
-
|
62
63
|
<li><a href="./CHANGELOG.html">CHANGELOG</a>
|
63
|
-
|
64
64
|
<li><a href="./COPYING_md.html">COPYING</a>
|
65
|
-
|
66
65
|
<li><a href="./Gemfile.html">Gemfile</a>
|
67
|
-
|
68
66
|
<li><a href="./README_md.html">README</a>
|
69
|
-
|
70
67
|
<li><a href="./Rakefile.html">Rakefile</a>
|
71
|
-
|
72
|
-
<li><a href="./acknowledgements_md.html">acknowledgements</a>
|
73
|
-
|
74
|
-
<li><a href="./authors_md.html">authors</a>
|
75
|
-
|
76
68
|
<li><a href="./copyright_md.html">copyright</a>
|
77
|
-
|
78
|
-
<li><a href="./wwwjdic_gemspec.html">wwwjdic.gemspec</a>
|
79
|
-
|
80
69
|
</ul>
|
81
70
|
</div>
|
82
71
|
|
@@ -84,39 +73,22 @@
|
|
84
73
|
<h3>Class and Module Index</h3>
|
85
74
|
|
86
75
|
<ul class="link-list">
|
87
|
-
|
88
76
|
<li><a href="./Object.html">Object</a>
|
89
|
-
|
90
77
|
<li><a href="./WWWJDic.html">WWWJDic</a>
|
91
|
-
|
92
78
|
<li><a href="./WWWJDic/ParsableDuckType.html">WWWJDic::ParsableDuckType</a>
|
93
|
-
|
94
79
|
<li><a href="./WWWJDic/Parser.html">WWWJDic::Parser</a>
|
95
|
-
|
96
80
|
<li><a href="./WWWJDic/Parsers.html">WWWJDic::Parsers</a>
|
97
|
-
|
98
81
|
<li><a href="./WWWJDic/Parsers/Dict.html">WWWJDic::Parsers::Dict</a>
|
99
|
-
|
100
82
|
<li><a href="./WWWJDic/Parsers/Display.html">WWWJDic::Parsers::Display</a>
|
101
|
-
|
102
83
|
<li><a href="./WWWJDic/Parsers/Key.html">WWWJDic::Parsers::Key</a>
|
103
|
-
|
104
84
|
<li><a href="./WWWJDic/Parsers/Search.html">WWWJDic::Parsers::Search</a>
|
105
|
-
|
106
85
|
<li><a href="./WWWJDic/Parsers/Server.html">WWWJDic::Parsers::Server</a>
|
107
|
-
|
108
86
|
<li><a href="./WWWJDic/Splitter.html">WWWJDic::Splitter</a>
|
109
|
-
|
110
87
|
<li><a href="./WWWJDic/Utils.html">WWWJDic::Utils</a>
|
111
|
-
|
112
88
|
<li><a href="./WWWJDic/Utils/Downloader.html">WWWJDic::Utils::Downloader</a>
|
113
|
-
|
114
89
|
<li><a href="./WWWJDic/Utils/Downloader/Downloader.html">WWWJDic::Utils::Downloader::Downloader</a>
|
115
|
-
|
116
90
|
<li><a href="./WWWJDic/Utils/Raisers.html">WWWJDic::Utils::Raisers</a>
|
117
|
-
|
118
91
|
<li><a href="./WWWJDic/WWWJDic.html">WWWJDic::WWWJDic</a>
|
119
|
-
|
120
92
|
</ul>
|
121
93
|
</div>
|
122
94
|
|
@@ -128,7 +100,7 @@
|
|
128
100
|
<!--
|
129
101
|
wwwjdic
|
130
102
|
|
131
|
-
|
103
|
+
(C) 2014 Marco Bresciani
|
132
104
|
|
133
105
|
This file is part of wwwjdic.
|
134
106
|
|
@@ -144,68 +116,67 @@ more details.
|
|
144
116
|
|
145
117
|
You should have received a copy of the GNU General Public License along
|
146
118
|
with wwwjdic. If not, see <http://www.gnu.org/licenses/>.
|
147
|
-
-->
|
148
|
-
<h1 id="label-WWWJDic"><a href="WWWJDic.html"><code>WWWJDic</code></a><span><a href="#label-WWWJDic">¶</a> <a href="#top">↑</a></span></h1>
|
149
|
-
|
150
|
-
<p><img src="https://img.shields.io/gem/v/wwwjdic.svg?style=plastic"> <img src="https://img.shields.io/gem/dt/wwwjdic.svg?style=plastic"> <img src="https://img.shields.io/gem/dtv/wwwjdic.svg?style=plastic"> <img src="https://img.shields.io/gem/rt/wwwjdic.svg?style=plastic"> <img src="https://img.shields.io/gem/rd/wwwjdic.svg?style=plastic"> <img src="https://img.shields.io/librariesio/dependent-repos/rubygems/wwwjdic.svg?style=plastic"></p>
|
151
|
-
|
152
|
-
<p>Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani</p>
|
153
|
-
|
154
|
-
<p>This file is part of wwwjdic.</p>
|
155
|
-
|
156
|
-
<p>wwwjdic is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.</p>
|
157
|
-
|
158
|
-
<p>wwwjdic is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.</p>
|
159
|
-
|
160
|
-
<p>You should have received a copy of the GNU General Public License along with wwwjdic. If not, see <a href="http://www.gnu.org/licenses">www.gnu.org/licenses</a>/.</p>
|
161
|
-
|
162
|
-
<h2 id="label-Description">Description<span><a href="#label-Description">¶</a> <a href="#top">↑</a></span></h2>
|
163
|
-
|
164
|
-
<p>This gem uses <a href="WWWJDic.html"><code>WWWJDic</code></a> Backdoor Entry/API as described by <a href="http://www.csse.monash.edu.au/~jwb/wwwjdicinf.html#backdoor_tag">www.csse.monash.edu.au/~jwb/wwwjdicinf.html#backdoor_tag</a> to interact with <a href="WWWJDic.html"><code>WWWJDic</code></a> and translate to and from Japanese language.</p>
|
165
|
-
|
166
|
-
<p><a href="WWWJDic.html"><code>WWWJDic</code></a> is an online Japanese translation server made by Jim Breen and available at <a href="http://www.edrdg.org/cgi-bin/wwwjdic/wwwjdic?1C">www.edrdg.org/cgi-bin/wwwjdic/wwwjdic?1C</a> .</p>
|
167
119
|
|
168
|
-
|
120
|
+
SPDX-FileCopyrightText: 2014 Marco Bresciani
|
169
121
|
|
170
|
-
|
171
|
-
|
172
|
-
<
|
122
|
+
SPDX-License-Identifier: GFDL-1.3-or-later
|
123
|
+
-->
|
124
|
+
<h1 id="label-WWWJDic"><a href="WWWJDic.html"><code>WWWJDic</code></a><span><a href="#label-WWWJDic">¶</a> <a href="#top">↑</a></span></h1>
|
173
125
|
|
174
|
-
<p><
|
126
|
+
<p><img src="https://badgen.net/rubygems/n/wwwjdic"> <img src="https://badgen.net/rubygems/v/wwwjdic/latest"> <img src="https://badgen.net/rubygems/p/wwwjdic"></p>
|
175
127
|
|
176
|
-
<p>
|
128
|
+
<p><a href="https://github.com/RichardLitt/standard-readme"><img src="https://img.shields.io/badge/readme%20style-standard-brightgreen.svg?style=plastic"></a> <a href="https://github.com/rubocop-hq/rubocop"><img src="https://img.shields.io/badge/code_style-rubocop-brightgreen.svg"></a> <a href="https://api.reuse.software/info/git.fsfe.org/reuse/api"><img src="https://api.reuse.software/badge/git.fsfe.org/reuse/api"></a></p>
|
177
129
|
|
178
|
-
<
|
130
|
+
<p><img src="https://badgen.net/rubygems/dt/wwwjdic"> <img src="https://badgen.net/rubygems/dv/wwwjdic"></p>
|
179
131
|
|
180
|
-
<p
|
132
|
+
<p><img src="https://img.shields.io/gem/rt/wwwjdic.svg?style=plastic"> <img src="https://img.shields.io/gem/rd/wwwjdic.svg?style=plastic"> <img src="https://img.shields.io/librariesio/dependent-repos/rubygems/wwwjdic.svg?style=plastic"> <img src="https://img.shields.io/gem/u/MarcoBresciani?style=plastic"></p>
|
181
133
|
|
182
|
-
<
|
134
|
+
<p><img src="https://img.shields.io/security-headers?style=plastic&url=https%3A%2F%2Fsavannah.nongnu.org%2Fprojects%2Faamfp"> <img src="https://img.shields.io/hsts/preload/savannah.nongnu.org?style=plastic"> <img src="https://img.shields.io/mozilla-observatory/grade/savannah.nongnu.org?publish&style=plastic"> <img src="https://img.shields.io/website?style=plastic&url=https%3A%2F%2Fsavannah.nongnu.org%2Fprojects%2Faamfp"></p>
|
183
135
|
|
184
|
-
<p>
|
136
|
+
<p>This gem uses <a href="WWWJDic.html"><code>WWWJDic</code></a> Backdoor Entry/API to interact with <a href="WWWJDic.html"><code>WWWJDic</code></a> and translate to and from Japanese language.</p>
|
185
137
|
|
186
|
-
<
|
138
|
+
<p>This gem uses <a href="WWWJDic.html"><code>WWWJDic</code></a> Backdoor Entry/API as described by <a href="http://www.edrdg.org/wwwjdic/wwwjdicinf.html#backdoor_tag">www.edrdg.org/wwwjdic/wwwjdicinf.html#backdoor_tag</a> to interact with <a href="WWWJDic.html"><code>WWWJDic</code></a> and translate to and from Japanese language. <a href="WWWJDic.html"><code>WWWJDic</code></a> is an online Japanese translation server made by Jim Breen and available at <a href="http://www.edrdg.org/cgi-bin/wwwjdic/wwwjdic?1C">www.edrdg.org/cgi-bin/wwwjdic/wwwjdic?1C</a>. GNU GPLv3 license; source code available through anonymous checkout: <code>hg clone http://hg.savannah.nongnu.org/hgweb/wwwjdic/</code> or write me, and I'll send it. You can even decide to contribute to this little free software project by registering to Savannah and ask to be part of the <code>wwwjdic</code> project!</p>
|
187
139
|
|
188
|
-
<
|
140
|
+
<h2 id="label-Table+of+Contents">Table of Contents<span><a href="#label-Table+of+Contents">¶</a> <a href="#top">↑</a></span></h2>
|
141
|
+
<ul><li>
|
142
|
+
<p><a href="#background">Background</a></p>
|
143
|
+
</li><li>
|
144
|
+
<p><a href="#install">Install</a></p>
|
145
|
+
</li><li>
|
146
|
+
<p><a href="#savannah">Savannah</a></p>
|
147
|
+
</li><li>
|
148
|
+
<p><a href="#rubygems">RubyGems</a></p>
|
149
|
+
</li><li>
|
150
|
+
<p><a href="#usage">Usage</a></p>
|
151
|
+
</li><li>
|
152
|
+
<p><a href="#maintainers">Maintainers</a></p>
|
153
|
+
</li><li>
|
154
|
+
<p><a href="#thanks">Thanks</a></p>
|
155
|
+
</li><li>
|
156
|
+
<p><a href="#contributing">Contributing</a></p>
|
157
|
+
</li><li>
|
158
|
+
<p><a href="#license">License</a></p>
|
159
|
+
</li></ul>
|
189
160
|
|
190
|
-
<
|
161
|
+
<h2 id="label-Background">Background<span><a href="#label-Background">¶</a> <a href="#top">↑</a></span></h2>
|
191
162
|
|
192
|
-
<p>
|
163
|
+
<p>This gem uses <a href="WWWJDic.html"><code>WWWJDic</code></a> Backdoor Entry/API as described by <a href="http://www.edrdg.org/wwwjdic/wwwjdicinf.html#backdoor_tag">www.edrdg.org/wwwjdic/wwwjdicinf.html#backdoor_tag</a> to interact with <a href="WWWJDic.html"><code>WWWJDic</code></a> and translate to and from Japanese language.</p>
|
193
164
|
|
194
|
-
<
|
165
|
+
<p><a href="WWWJDic.html"><code>WWWJDic</code></a> is an online Japanese translation server made by Jim Breen and available at <a href="http://www.edrdg.org/cgi-bin/wwwjdic/wwwjdic?1C">www.edrdg.org/cgi-bin/wwwjdic/wwwjdic?1C</a>.</p>
|
195
166
|
|
196
|
-
<p>
|
167
|
+
<p>Jim Breen's Japanese Page lists this gem: <a href="http://nihongo.monash.edu/japanese.html#links_software">nihongo.monash.edu/japanese.html#links_software</a></p>
|
197
168
|
|
198
|
-
<p>
|
169
|
+
<p>GNU GPLv3 license; source code available through anonymous checkout: <code>hg clone http://hg.savannah.nongnu.org/hgweb/wwwjdic/</code> or write me, and I'll send it.</p>
|
199
170
|
|
200
|
-
<p>
|
171
|
+
<p>You can even decide to contribute to this little free software project by registering to Savannah and ask to be part of the <code>wwwjdic</code> project!</p>
|
201
172
|
|
202
|
-
<p>
|
173
|
+
<p>With great contributions from: Jim Breen, 新部裕, Jon Maken.</p>
|
203
174
|
|
204
|
-
<
|
175
|
+
<h2 id="label-Install">Install<span><a href="#label-Install">¶</a> <a href="#top">↑</a></span></h2>
|
205
176
|
|
206
|
-
<p
|
177
|
+
<p>RubyGems is the preferred easy install method for <a href="WWWJDic.html"><code>WWWJDic</code></a>. <a href="WWWJDic.html"><code>WWWJDic</code></a> should be installed via the <a href="http://rubyforge.org/projects/rubygems/">RubyGems</a> system. To get the latest version, simply enter the following into your command prompt: <code>gem install wwwjdic</code>.</p>
|
207
178
|
|
208
|
-
<
|
179
|
+
<p>Because <a href="WWWJDic.html"><code>WWWJDic</code></a> is pure Ruby, it should run pretty much anywhere, including Rubinius, JRuby, MacRuby, etc. Officially the support is for >= 2.7 YARV/KRI.</p>
|
209
180
|
|
210
181
|
<h4 id="label-Savannah">Savannah<span><a href="#label-Savannah">¶</a> <a href="#top">↑</a></span></h4>
|
211
182
|
<ul><li>
|
@@ -229,118 +200,281 @@ with wwwjdic. If not, see <http://www.gnu.org/licenses/>.
|
|
229
200
|
<p>Gem updates Atom Feed: <a href="https://rubygems.org/gems/wwwjdic/versions.atom">rubygems.org/gems/wwwjdic/versions.atom</a></p>
|
230
201
|
</li></ul>
|
231
202
|
|
232
|
-
<
|
233
|
-
|
234
|
-
<p>
|
235
|
-
</li><li>
|
236
|
-
<p>Jim Breen's Japanese Page: <a href="http://nihongo.monash.edu/japanese.html#links_software">nihongo.monash.edu/japanese.html#links_software</a></p>
|
237
|
-
</li><li>
|
238
|
-
<p>“An HTTP/HTTPS/FTP file downloader library/CLI based upon MiniPortile's HTTP implementation.” gist by Jon Maken: <a href="https://gist.github.com/jonforums/2202048">gist.github.com/jonforums/2202048</a>.</p>
|
239
|
-
</li></ul>
|
203
|
+
<h2 id="label-Usage">Usage<span><a href="#label-Usage">¶</a> <a href="#top">↑</a></span></h2>
|
204
|
+
|
205
|
+
<p>See <code>examples</code> folder. To run the examples just run <code>ruby</code>{EXAMPLE_NAME}<code>.rb</code>. Running the examples you'll see both the example description and correct code usage to perform such action. Here below there are the currently available examples: * The <code>basics.rb</code> example (run <code>ruby examples/basics.rb</code>) shows how to initialize and use a <a href="WWWJDic.html"><code>WWWJDic</code></a> object through the <code>breener</code> factory method; * The <code>uri.rb</code> example (run <code>ruby examples/uri.rb</code>) shows how to ask for different types of translation URIs at <a href="WWWJDic.html"><code>WWWJDic</code></a>, with all available options and configurations. * The <code>translate.rb</code> example (run <code>ruby examples/translate.rb</code>) shows how to ask for an actual translation through <a href="WWWJDic.html"><code>WWWJDic</code></a> Backdoor/API, with all available options and configurations. It will also show how to download such translation;</p>
|
240
206
|
|
241
|
-
<
|
207
|
+
<p>Using this API is pretty simple. First, remember that this API maintains a context, so you can save your preferred configuration of server, dictionary, output formats, … by assigning those value to your object. Get a reference to the <a href="WWWJDic.html"><code>WWWJDic</code></a> object, through its factory method, with <code>my_wwwjdic = WWWJDic::breener</code>. This will save a <a href="WWWJDic.html"><code>WWWJDic</code></a> instance in your <code>my_wwwjdic</code> object. At this point the object does contain a default configuration in terms of dictionary, server, …</p>
|
242
208
|
|
243
|
-
<p>
|
209
|
+
<p>You can take a look at the current status/configuration of your <code>my_wwwjdic</code> object using the <code>dictionary</code> method <code>my_wwwjdic.dictionary</code> that shows the dictionary currently in use (default is <code>Jpn-Eng General (EDICT)</code>), or using the <code>server</code> method <code>my_wwwjdic.server</code> that shows the dictionary server currently in use (default is <code>http://www.edrdg.org/cgi-bin/wwwjdic/wwwjdic.cgi?</code>).</p>
|
244
210
|
<ul><li>
|
245
|
-
<p
|
246
|
-
</li><li>
|
247
|
-
<p>The <code>uri.rb</code> example (run <code>ruby examples/uri.rb</code>) shows how to ask for translation URI at <a href="WWWJDic.html"><code>WWWJDic</code></a>, with all available options and configurations.</p>
|
248
|
-
</li><li>
|
249
|
-
<p>The <code>translate.rb</code> example (run <code>ruby examples/translate.rb</code>) shows how to ask for an actual translation through <a href="WWWJDic.html"><code>WWWJDic</code></a> Backdoor/API, with all available options and configurations. It will also show how to download such translation;</p>
|
211
|
+
<p><code>dictionary</code>: you can set your own dictionary through the same <code>dictionary</code> method, by assigning it one of the available dictionaries, either using the dictionary number, or the (exact) dictionary name.</p>
|
250
212
|
</li></ul>
|
251
213
|
|
252
|
-
<p
|
253
|
-
|
254
|
-
<
|
255
|
-
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
214
|
+
<p>| Number | Dictionary Name | |:——:|—————————| | 1 | Jpn-Eng General (EDICT) | | 2 | Japanese Names (ENAMDICT) | | 3 | Computing/Telecomms | | 4 | Life Sciences/Bio-Med | | 5 | Legal Terms | | 6 | Finance/Marketing | | 7 | Buddhism | | 8 | Miscellaneous | | 9 | Special Text-glossing | | A | Engineering/Science | | B | Linguistics | | C | River & Water Systems | | D | Automobile Industry | | E | Japanese Wordnet | | F | Work-in-progress File | | G | Japanese-German (WaDoku) | | H | Japanese-French | | I | Japanese-Russian | | J | Japanese-Swedish | | K | Japanese-Hungarian | | L | Japanese-Spanish | | M | Japanese-Dutch | | N | Japanese-Slovenian | | O | Japanese-Italian | | P | Untranslated | | Q | Combined Jpn-Eng | | R | Expanded Text-glossing |</p>
|
215
|
+
|
216
|
+
<p>For example, with <code>my_wwwjdic.dictionary = '7'</code> you set the <code>Buddhism</code> dictionary or with <code>my_wwwjdic.dictionary = 'Japanese Wordnet'</code> you just set the <code>Japanese Wordnet</code> one. Your <code>my_wwwjdic</code> object saves and maintains these values unless reset. * <code>server</code>: you can set your own server through the same <code>server</code> method, by assigning it one of the available servers. Using <code>my_wwwjdic.server = :edrdg</code> the library will use the main (default) URL at <a href="http://www.edrdg.org/cgi-bin/wwwjdic/wwwjdic.cgi">www.edrdg.org/cgi-bin/wwwjdic/wwwjdic.cgi</a>? for the dictionary server while instead using <code>my_wwwjdic.server = :monash</code> will use the URL <a href="http://nihongo.monash.edu/cgi-bin/wwwjdic">nihongo.monash.edu/cgi-bin/wwwjdic</a>? that relays on Monash University mirror. * <code>uri</code>: you can ask for a translation reference URL; that is not a translation by itself, but it's the full URL where to find the translation. * You can get the translation URL of a specific word using the command <code>my_wwwjdic.uri '</code>word<code>'</code> that returns the normal URL. * Then you can use the <code>my_wwwjdic.raw_uri '</code>word<code>'</code>, for the raw display format. The raw dictionary display option is useful for calls from other programs, smartphones, etc. It omits all header and footer information from the pages, and displays the unedited dictionary entries in EDICT and KANJIDIC format, one-per-line and encapsulated by <pre> … </pre>. In this option the output is always in UTF-8 coding. * the <code>my_wwwjdic.json_uri '</code>word<code>'</code> command, instead, returns the URL for translation of <code>word</code> in a JSON format as <code>{ "</code>word<code>: "</code>url<code>" }</code> with normal display format. * <code>translate</code>: you can, finaly, obviously ask for a specific translation using the configured parameters. * you can get a simple translation with the command <code>my_wwwjdic.translate 'word'</code>, that returns a string containing the web page content of the translation of <code>word</code> in the raw display format. It's equivalent to <code>my_wwwjdic.translate 'word', display: :raw</code>. * <code>my_wwwjdic.translate 'word', nil, filename</code>, regardless the <code>nil</code> (see it later), the third <code>filename</code> parameter is the name of the file where the translation will be saved into. Specifying this <code>filename</code> parameter, the translation will not be shown, but it will be saved in the specified file. * Another possible result for translation is to get it in JSON format also with the possibility to save it in a file: <code>my_wwwjdic.json_translate 'word'</code>, returns the JSON format of the translation: * The JSON will contain a field having the same name of the word to be translated that contains the URL of the translation from the reference dictionary server used. The URL is exatcly the same used to retrieve the translation and filling the resulting JSON. * The <code>title</code> field will contain the title of the translation page result. * The <code>translation</code> field will contain the raw translation as received from the server. * The <code>message</code> field will contain all the text that will possibly be included as error message in the translation. This means that if any <code><p></code> tag encloses some text, such text will be presented in this <code>message</code> field. * The <code>lines</code> field will contain an array of all the lines of the translation, that is: the <code>lines</code> field contains a split of the <code>translation</code> field using its existing <code>\n</code> characters. * The <code>content</code> field contains an array of JSON objects, each containing the formatted translation of each line: * a field with the name of the word asked for translation, containing the actual translation, first field of the translation in each line; * a <code>kana</code> field with the kana writing for the translation, as shown in brackets, in each line; * a <code>text</code> field containing the explanation associated to such translation; * a <code>meanings</code> field containing the different meaning associated to each line. The <code>/</code> characters mark the splitting point for each line.</p>
|
217
|
+
|
218
|
+
<pre>So, basically, the JSON will contain the whole raw translation, the
|
219
|
+
same translation split into different lines, when asked by the
|
220
|
+
translation itself, and each of those lines above split again into a
|
221
|
+
set of available meanings.
|
222
|
+
|
223
|
+
For the example translation above, the resulting JSON format is:
|
224
|
+
```json5
|
225
|
+
{
|
226
|
+
"word": "http://www.edrdg.org/cgi-bin/wwwjdic/wwwjdic.cgi?1ZDQword",
|
227
|
+
"title": "WWWJDIC: Word Display",
|
228
|
+
"translation": "伝言 [つてこと] /(n) (1) (See 伝言・でんごん) verbal message/word (from someone)/(n) (2) rumour/rumor/\n伝言 [でんごん] /(n,vs) verbal message/word (from someone)/(P)/\n一議 [いちぎ] /(n) word (opinion, objection)/\n言の葉 [ことのは;ことのえ] /(n) (1) (arch) word/(n) (2) (See 和歌) waka (classic Japanese poem, esp. a tanka)/\nワード /(n) (1) word/(n) (2) {comp} word/(n) (3) {comp} Word/Microsoft Word/(P)/\n語 [ご] /(n,n-suf) (1) language/(n,n-suf,ctr) (2) word/(P)/\n単語 [たんご] /(n,adj-no) {ling} word/vocabulary/(usually) single-character word/(P)/\n訪れ [おとずれ] /(n) (1) visit/call/(n) (2) arrival (e.g. of spring)/advent/coming/appearance/(n) (3) news/tidings/word/(P)/\n音沙汰;音さた [おとさた] /(n) news (from someone)/word/contact/\n言 [げん(P);こと] /(n) word/remark/statement/(P)/\n知らせ(P);報せ [しらせ] /(n) (1) (See お知らせ) news/word/tidings/notice/notification/information/(n) (2) omen/(P)/\n言葉(P);詞;辞 [ことば(P);けとば(言葉)(ok)] /(n) (1) (See 言語) language/dialect/(n) (2) (See 単語) word/words/phrase/term/expression/remark/(n) (3) speech/(manner of) speaking/(n) (4) learning to speak/language acquisition/(P)/",
|
229
|
+
"message": null,
|
230
|
+
"lines": [
|
231
|
+
"伝言 [つてこと] /(n) (1) (See 伝言・でんごん) verbal message/word (from someone)/(n) (2) rumour/rumor/",
|
232
|
+
"伝言 [でんごん] /(n,vs) verbal message/word (from someone)/(P)/",
|
233
|
+
"一議 [いちぎ] /(n) word (opinion, objection)/",
|
234
|
+
"言の葉 [ことのは;ことのえ] /(n) (1) (arch) word/(n) (2) (See 和歌) waka (classic Japanese poem, esp. a tanka)/",
|
235
|
+
"ワード /(n) (1) word/(n) (2) {comp} word/(n) (3) {comp} Word/Microsoft Word/(P)/",
|
236
|
+
"語 [ご] /(n,n-suf) (1) language/(n,n-suf,ctr) (2) word/(P)/",
|
237
|
+
"単語 [たんご] /(n,adj-no) {ling} word/vocabulary/(usually) single-character word/(P)/",
|
238
|
+
"訪れ [おとずれ] /(n) (1) visit/call/(n) (2) arrival (e.g. of spring)/advent/coming/appearance/(n) (3) news/tidings/word/(P)/",
|
239
|
+
"音沙汰;音さた [おとさた] /(n) news (from someone)/word/contact/",
|
240
|
+
"言 [げん(P);こと] /(n) word/remark/statement/(P)/",
|
241
|
+
"知らせ(P);報せ [しらせ] /(n) (1) (See お知らせ) news/word/tidings/notice/notification/information/(n) (2) omen/(P)/",
|
242
|
+
"言葉(P);詞;辞 [ことば(P);けとば(言葉)(ok)] /(n) (1) (See 言語) language/dialect/(n) (2) (See 単語) word/words/phrase/term/expression/remark/(n) (3) speech/(manner of) speaking/(n) (4) learning to speak/language acquisition/(P)/"
|
243
|
+
],
|
244
|
+
"content": [
|
245
|
+
{
|
246
|
+
"word": "伝言",
|
247
|
+
"kana": "つてこと",
|
248
|
+
"text": "(n)(1) (See 伝言・でんごん) verbal message/word (from someone)/(n) (2) rumour/rumor",
|
249
|
+
"meanings": [
|
250
|
+
"(n) (1) (See 伝言・でんごん) verbal message",
|
251
|
+
"word (from someone)",
|
252
|
+
"(n) (2) rumour",
|
253
|
+
"rumor"
|
254
|
+
]
|
255
|
+
},
|
256
|
+
{
|
257
|
+
"word": "伝言",
|
258
|
+
"kana": "でんごん",
|
259
|
+
"text": "(n,vs) verbal message/word (from someone)/(P)",
|
260
|
+
"meanings": [
|
261
|
+
"(n,vs) verbal message",
|
262
|
+
"word (from someone)",
|
263
|
+
"(P)"
|
264
|
+
]
|
265
|
+
},
|
266
|
+
{
|
267
|
+
"word": "一議",
|
268
|
+
"kana": "いちぎ",
|
269
|
+
"text": "(n) word (opinion, objection)"
|
270
|
+
},
|
271
|
+
{
|
272
|
+
"word": "言の葉",
|
273
|
+
"kana": "ことのは;ことのえ",
|
274
|
+
"text": "(n) (1) (arch) word/(n) (2) (See 和歌) waka (classic Japanese poem, esp. a tanka)",
|
275
|
+
"meanings": [
|
276
|
+
"(n) (1) (arch) word",
|
277
|
+
"(n) (2) (See 和歌) waka (classic Japanese poem, esp. a tanka)"
|
278
|
+
]
|
279
|
+
},
|
280
|
+
{
|
281
|
+
"kana": "ワード",
|
282
|
+
"word": "ワード",
|
283
|
+
"text": "(n) (1) word/(n) (2) {comp} word/(n) (3) {comp} Word/Microsoft Word/(P)",
|
284
|
+
"meanings": [
|
285
|
+
"(n) (1) word",
|
286
|
+
"(n) (2) {comp} word",
|
287
|
+
"(n) (3) {comp} Word",
|
288
|
+
"Microsoft Word",
|
289
|
+
"(P)"
|
290
|
+
]
|
291
|
+
},
|
292
|
+
{
|
293
|
+
"word": "語",
|
294
|
+
"kana": "ご",
|
295
|
+
"text": "(n,n-suf) (1) language/(n,n-suf,ctr) (2) word/(P)",
|
296
|
+
"meanings": [
|
297
|
+
"(n,n-suf) (1) language",
|
298
|
+
"(n,n-suf,ctr) (2) word",
|
299
|
+
"(P)"
|
300
|
+
]
|
301
|
+
},
|
302
|
+
{
|
303
|
+
"word": "単語",
|
304
|
+
"kana": "たんご",
|
305
|
+
"text": "(n,adj-no) {ling} word/vocabulary/(usually) single-character word/(P)",
|
306
|
+
"meanings": [
|
307
|
+
"(n,adj-no) {ling} word",
|
308
|
+
"vocabulary",
|
309
|
+
"(usually) single-character word",
|
310
|
+
"(P)"
|
311
|
+
]
|
312
|
+
},
|
313
|
+
{
|
314
|
+
"word": "訪れ",
|
315
|
+
"kana": "おとずれ",
|
316
|
+
"text": "(n) (1) visit/call/(n) (2) arrival (e.g. of spring)/advent/coming/appearance/(n) (3) news/tidings/word/(P)",
|
317
|
+
"meanings": [
|
318
|
+
"(n) (1) visit",
|
319
|
+
"call",
|
320
|
+
"(n) (2) arrival (e.g. of spring)",
|
321
|
+
"advent",
|
322
|
+
"coming",
|
323
|
+
"appearance",
|
324
|
+
"(n) (3) news",
|
325
|
+
"tidings",
|
326
|
+
"word",
|
327
|
+
"(P)"
|
328
|
+
]
|
329
|
+
},
|
330
|
+
{
|
331
|
+
"word": "音沙汰;音さた",
|
332
|
+
"kana": "おとさた",
|
333
|
+
"text": "(n) news (from someone)/word/contact",
|
334
|
+
"meanings": [
|
335
|
+
"(n) news (from someone)",
|
336
|
+
"word",
|
337
|
+
"contact"
|
338
|
+
]
|
339
|
+
},
|
340
|
+
{
|
341
|
+
"word": "言",
|
342
|
+
"kana": "げん(P);こと",
|
343
|
+
"text": "(n) word/remark/statement/(P)",
|
344
|
+
"meanings": [
|
345
|
+
"(n) word",
|
346
|
+
"remark",
|
347
|
+
"statement",
|
348
|
+
"(P)"
|
349
|
+
]
|
350
|
+
},
|
351
|
+
{
|
352
|
+
"word": "知らせ(P);報せ",
|
353
|
+
"kana": "しらせ",
|
354
|
+
"text": "(n) (1) (See お知らせ) news/word/tidings/notice/notification/information/(n) (2) omen/(P)",
|
355
|
+
"meanings": [
|
356
|
+
"(n) (1) (See お知らせ) news",
|
357
|
+
"word",
|
358
|
+
"tidings",
|
359
|
+
"notice",
|
360
|
+
"notification",
|
361
|
+
"information",
|
362
|
+
"(n) (2) omen",
|
363
|
+
"(P)"
|
364
|
+
]
|
365
|
+
},
|
366
|
+
{
|
367
|
+
"word": "言葉(P);詞;辞",
|
368
|
+
"kana": "ことば(P);けとば(言葉)(ok)",
|
369
|
+
"text": "(n) (1) (See 言語) language/dialect/(n) (2) (See 単語) word/words/phrase/term/expression/remark/(n) (3) speech/(manner of) speaking/(n) (4) learning to speak/language acquisition/(P)",
|
370
|
+
"meanings": [
|
371
|
+
"(n) (1) (See 言語) language",
|
372
|
+
"dialect",
|
373
|
+
"(n) (2) (See 単語) word",
|
374
|
+
"words",
|
375
|
+
"phrase",
|
376
|
+
"term",
|
377
|
+
"expression",
|
378
|
+
"remark",
|
379
|
+
"(n) (3) speech",
|
380
|
+
"(manner of) speaking",
|
381
|
+
"(n) (4) learning to speak",
|
382
|
+
"language acquisition",
|
383
|
+
"(P)"
|
384
|
+
]
|
385
|
+
}
|
386
|
+
]
|
387
|
+
}
|
388
|
+
```
|
389
|
+
Please note that the resulting JSON is not pretty-printed, as shown
|
390
|
+
here.</pre>
|
262
391
|
<ul><li>
|
263
|
-
<p>the <code>
|
264
|
-
|
265
|
-
<pre class="ruby"><span class="ruby-identifier">my_wwwjdic</span>.<span class="ruby-identifier">server</span> <span class="ruby-comment"># returns the default server URL http://www.csse.monash.edu.au/~jwb/cgi-bin/wwwjdic.cgi?</span>
|
266
|
-
<span class="ruby-identifier">my_wwwjdic</span>.<span class="ruby-identifier">to_s</span> <span class="ruby-comment"># contains the URL above</span>
|
267
|
-
|
268
|
-
<span class="ruby-comment"># this below is (again) the default configured server</span>
|
269
|
-
<span class="ruby-identifier">my_wwwjdic</span>.<span class="ruby-identifier">server</span> = <span class="ruby-value">:edrdg</span>
|
270
|
-
<span class="ruby-identifier">my_wwwjdic</span>.<span class="ruby-identifier">server</span> <span class="ruby-comment"># returns the URL http://www.edrdg.org/cgi-bin/wwwjdic/wwwjdic.cgi?</span>
|
271
|
-
<span class="ruby-identifier">my_wwwjdic</span>.<span class="ruby-identifier">to_s</span> <span class="ruby-comment"># contains the URL above</span>
|
272
|
-
|
273
|
-
<span class="ruby-comment"># this is the additional server</span>
|
274
|
-
<span class="ruby-identifier">my_wwwjdic</span>.<span class="ruby-identifier">server</span> = <span class="ruby-value">:monash</span>
|
275
|
-
<span class="ruby-identifier">my_wwwjdic</span>.<span class="ruby-identifier">server</span> <span class="ruby-comment"># returns the URL http://www.csse.monash.edu.au/~jwb/cgi-bin/wwwjdic.cgi?</span>
|
276
|
-
<span class="ruby-identifier">my_wwwjdic</span>.<span class="ruby-identifier">to_s</span> <span class="ruby-comment"># contains the URL above</span>
|
277
|
-
</pre>
|
278
|
-
</li><li>
|
279
|
-
<p>the default reference <code>dictionary</code> to use for translations. All currently available dictionaries strings can be used: <code>'1'</code>, <code>'2'</code>, <code>'3'</code>, <code>'4'</code>, <code>'5'</code>, <code>'6'</code>, <code>'7'</code>, <code>'8'</code>, <code>'9'</code>, <code>'A'</code>, <code>'B'</code>, <code>'C'</code>, <code>'D'</code>, <code>'E'</code>, <code>'F'</code>, <code>'G'</code>, <code>'H'</code>, <code>'I'</code>, <code>'J'</code>, <code>'K'</code>, <code>'L'</code>, <code>'M'</code>, <code>'N'</code>, <code>'O'</code>, <code>'P'</code>, <code>'Q'</code> and <code>'R'</code>. You can even use the whole (exact) dictionary strings as listed in the <a href="WWWJDic.html"><code>WWWJDic</code></a> HTML source code: <code>'Jpn-Eng General (EDICT)'</code>, <code>'Japanese Names (ENAMDICT)'</code>, <code>'Computing/Telecomms'</code>, <code>'Life Sciences/Bio-Med'</code>, <code>'Legal Terms'</code>, <code>'Finance/Marketing'</code>, <code>'Buddhism'</code>, <code>'Miscellaneous'</code>, <code>'Special Text-glossing'</code>, <code>'Engineering/Science'</code>, <code>'Linguistics'</code>, <code>'River & Water Systems'</code>, <code>'Automobile Industry'</code>, <code>'Japanese Wordnet'</code>, <code>'Work-in-progress File'</code>, <code>'Japanese-German (WaDoku)'</code>, <code>'Japanese-French'</code>, <code>'Japanese-Russian'</code>, <code>'Japanese-Swedish'</code>, <code>'Japanese-Hungarian'</code>, <code>'Japanese-Spanish'</code>, <code>'Japanese-Dutch'</code>, <code>'Japanese-Slovenian'</code>, <code>'Japanese-Italian'</code>, <code>'Untranslated'</code>, <code>'Combined Jpn-Eng'</code>, <code>'Expanded Text-glossing'</code>.</p>
|
392
|
+
<p>Now let's come to the second parameter of the methods above (set to <code>nil</code> in the examples), the arguments for the translation. The default is to translate to/from English/Japanese with normal display layout and no other specificities, except that the API automatically identifies Japanese or English and manages the romaji and so on. The returned URL is the default EDR&DG one, as required by Jim Breen himself. What if the user wants to customize something? The <code>args</code>, second parameter of all those methods above, is a dictionary (hash map) that allows specifying which parameters and to which values they shall be set.</p>
|
393
|
+
</li></ul>
|
280
394
|
|
281
|
-
<
|
395
|
+
<p>Valid parameters, and their values are: * <code>dict</code> parameter allows both numbers and (exact) strings to select dictionaries:</p>
|
396
|
+
|
397
|
+
<pre> | Number | Dictionary Name |
|
398
|
+
|:------:|---------------------------|
|
399
|
+
| 1 | Jpn-Eng General (EDICT) |
|
400
|
+
| 2 | Japanese Names (ENAMDICT) |
|
401
|
+
| 3 | Computing/Telecomms |
|
402
|
+
| 4 | Life Sciences/Bio-Med |
|
403
|
+
| 5 | Legal Terms |
|
404
|
+
| 6 | Finance/Marketing |
|
405
|
+
| 7 | Buddhism |
|
406
|
+
| 8 | Miscellaneous |
|
407
|
+
| 9 | Special Text-glossing |
|
408
|
+
| A | Engineering/Science |
|
409
|
+
| B | Linguistics |
|
410
|
+
| C | River & Water Systems |
|
411
|
+
| D | Automobile Industry |
|
412
|
+
| E | Japanese Wordnet |
|
413
|
+
| F | Work-in-progress File |
|
414
|
+
| G | Japanese-German (WaDoku) |
|
415
|
+
| H | Japanese-French |
|
416
|
+
| I | Japanese-Russian |
|
417
|
+
| J | Japanese-Swedish |
|
418
|
+
| K | Japanese-Hungarian |
|
419
|
+
| L | Japanese-Spanish |
|
420
|
+
| M | Japanese-Dutch |
|
421
|
+
| N | Japanese-Slovenian |
|
422
|
+
| O | Japanese-Italian |
|
423
|
+
| P | Untranslated |
|
424
|
+
| Q | Combined Jpn-Eng |
|
425
|
+
| R | Expanded Text-glossing |
|
426
|
+
|
427
|
+
* `display` parameter to select the final format of the referred
|
428
|
+
HTML page (either regular HTML or raw): `:regular`, `:raw`.
|
429
|
+
* `server` allows the user to select from the default URL (at
|
430
|
+
Electronic Dictionaries R&D Group) or the Monash university URL:
|
431
|
+
`:edrdg`, `:monash`.</pre>
|
432
|
+
|
433
|
+
<p>Some examples of these parameters' usage: * <code>my_wwwjdic.translate 'Sprache', dict: 'G', key: english</code>, this translates using the <code>F</code> dictionary, that is the German one * <code>my_wwwjdic.uri 'Sprache', dict: 'G'</code>, same as above, but returns the translation URL, instead * <code>my_wwwjdic.raw_uri 'Sprache', dict: 'G'</code>, same as above, but returns the translation URL with raw display, instead * <code>my_wwwjdic.uri 'Sprache', dict: 'G', display: raw</code></p>
|
434
|
+
|
435
|
+
<h2 id="label-Maintainers">Maintainers<span><a href="#label-Maintainers">¶</a> <a href="#top">↑</a></span></h2>
|
436
|
+
<ul><li>
|
437
|
+
<p><a href="https://savannah.nongnu.org/users/marcobresciani">Marco Bresciani</a></p>
|
438
|
+
</li></ul>
|
282
439
|
|
283
|
-
<
|
284
|
-
<
|
285
|
-
</
|
440
|
+
<h2 id="label-Thanks">Thanks<span><a href="#label-Thanks">¶</a> <a href="#top">↑</a></span></h2>
|
441
|
+
<ul><li>
|
442
|
+
<p><em>Contributor</em>: <a href="http://www.csse.monash.edu.au/~jwb/index.html">Jim Breen</a></p>
|
286
443
|
</li><li>
|
287
|
-
<p>
|
444
|
+
<p><em>Author</em>: <a href="mailto:jon.forums@gmail.com">Jon Maken</a>, <a href="https://gist.github.com/jonforums/2202048">An HTTP/HTTPS/FTP file downloader library/CLI based upon MiniPortile’s HTTP implementation.</a> About <em>An HTTP/HTTPS/FTP file downloader library/CLI based upon MiniPortile's HTTP implementation</em>, please note that “License: 3-clause BSD”. This license is GNU GPLv3 compatible according to <a href="http://www.gnu.org/licenses/license-list.en.html#ModifiedBSD">www.gnu.org/licenses/license-list.en.html#ModifiedBSD</a>.</p>
|
445
|
+
</li></ul>
|
288
446
|
|
289
|
-
<
|
447
|
+
<p>FSIJ理事会の理事長、<a href="mailto:gniibe@fsij.org">新部裕</a>さんの日本語の翻訳。 Japanese translation by <a href="mailto:gniibe@fsij.org">Yutaka Niibe</a>, President of Free Software Initiative of Japan.</p>
|
290
448
|
|
291
|
-
<
|
449
|
+
<p>Thanks to Łukasz Niemier for his suggestions on possible improvements.</p>
|
292
450
|
|
293
|
-
<
|
294
|
-
</pre>
|
295
|
-
</li><li>
|
296
|
-
<p>Then, instead of the pure URL to reference the <a href="WWWJDic.html"><code>WWWJDic</code></a> site, you can retrieve the actual translation itself or save it to a file:</p>
|
451
|
+
<h2 id="label-Contributing">Contributing<span><a href="#label-Contributing">¶</a> <a href="#top">↑</a></span></h2>
|
297
452
|
|
298
|
-
<
|
453
|
+
<p><a href="WWWJDic.html"><code>WWWJDic</code></a> tries to follow semantic versioning (see <a href="http://semver.org">semver.org</a>/). There may be backward incompatible changes each time minor version number changes, but that any tiny version number change should be bug fixes and internal changes only. Be sure to read the <code>CHANGELOG</code> each time we cut a new release and lock your gems accordingly.</p>
|
299
454
|
|
300
|
-
<
|
301
|
-
</pre>
|
302
|
-
</li><li>
|
303
|
-
<p>Another possible result for translation is to get it in JSON format also with the possibility to save it in a file.</p>
|
455
|
+
<p>RDoc documentation available in the <code>html</code> folder.</p>
|
304
456
|
|
305
|
-
<
|
306
|
-
</pre>
|
457
|
+
<p>The easiest way to get help with <a href="WWWJDic.html"><code>WWWJDic</code></a> is to post a message to the mailing list: <code>http://lists.nongnu.org/mailman/listinfo/wwwjdic-users</code></p>
|
307
458
|
|
308
|
-
<p>
|
459
|
+
<p>Feel free to post any question there, developers are responsive and will be happy to help you figure out how to use <a href="WWWJDic.html"><code>WWWJDic</code></a>, or help you determine whether it's the right tool for the task you are working on.</p>
|
309
460
|
|
310
|
-
<
|
311
|
-
word : translation uri for raw display format
|
312
|
-
'title' : title (extracted from <br>TITLE<br> tags in raw display format)
|
313
|
-
'translation' : translation content (extracted from <pre>TRANSLATION</pre> raw display format
|
314
|
-
'message' : possible error message or result (extracted from <p>MESSAGE\n raw display format
|
315
|
-
}</pre>
|
316
|
-
</li><li>
|
317
|
-
<p>Now let's come to the second parameter of the methods above (set to <code>nil</code> in the examples), the arguments for the translation. The default is to translate to/from English/Japanese with normal display layout and no other specificities, except that the API automatically identifies Japanese or English and manages the romaji and so on. The returned URL is the default EDR&DG one. What if the user wants to customize something? The <code>args</code>, second parameter of all those methods above, is a dictionary (hash map) that allows to specify which parameters and to which values they shall be set.</p>
|
461
|
+
<p>Please make your posts to the list as specific as possible, including code samples and output where relevant. Do not post any information that should not be shared publicly, and be sure to reduce your example code as much as possible so that those who are responding to your question can more easily see what the issue might be.</p>
|
318
462
|
|
319
|
-
<p>
|
320
|
-
<ul><li>
|
321
|
-
<p><code>dict</code> parameter allows both numbers and (exact) strings to select dictionaries: <code>'1'</code>, <code>'2'</code>, <code>'3'</code>, <code>'4'</code>, <code>'5'</code>, <code>'6'</code>, <code>'7'</code>, <code>'8'</code>, <code>'9'</code>, <code>'A'</code>, <code>'B'</code>, <code>'C'</code>, <code>'D'</code>, <code>'E'</code>, <code>'F'</code>, <code>'G'</code>, <code>'H'</code>, <code>'I'</code>, <code>'J'</code>, <code>'K'</code>, <code>'L'</code>, <code>'M'</code>, <code>'N'</code>, <code>'O'</code>, <code>'P'</code>, <code>'Q'</code>, and <code>'R'</code>, together with the full (exact) strings <code>'Jpn-Eng General (EDICT)'</code>, <code>'Japanese Names (ENAMDICT)'</code>, <code>'Computing/Telecomms'</code>, <code>'Life Sciences/Bio-Med'</code>, <code>'Legal Terms'</code>, <code>'Finance/Marketing'</code>, <code>'Buddhism'</code>, <code>'Miscellaneous'</code>, <code>'Special Text-glossing'</code>, <code>'Engineering/Science'</code>, <code>'Linguistics'</code>, <code>'River & Water Systems'</code>, <code>'Automobile Industry'</code>, <code>'Japanese Wordnet'</code>, <code>'Work-in-progress File'</code>, <code>'Japanese-German (WaDoku)'</code>, <code>'Japanese-French'</code>, <code>'Japanese-Russian'</code>, <code>'Japanese-Swedish'</code>, <code>'Japanese-Hungarian'</code>, <code>'Japanese-Spanish'</code>, <code>'Japanese-Dutch'</code>, <code>'Japanese-Slovenian'</code>, <code>'Japanese-Italian'</code>, <code>'Untranslated'</code>, <code>'Combined Jpn-Eng'</code> and <code>'Expanded Text-glossing'</code>.</p>
|
322
|
-
</li><li>
|
323
|
-
<p><code>display</code> parameter to select the final format of the referred HTML page (either regular HTML or raw): <code>:regular</code>, <code>:raw</code>.</p>
|
324
|
-
</li><li>
|
325
|
-
<p><code>server</code> allows the user to select from the default URL (at Electronic Dictionaries R&D Group) or the Monash university URL: <code>:edrdg</code>, <code>:monash</code>.</p>
|
326
|
-
</li></ul>
|
463
|
+
<p>If you've found a bug, want to submit a patch, or have a feature request, please enter a ticket into our bug tracker: <code>https://savannah.nongnu.org/bugs/?func=additem&group=wwwjdic</code></p>
|
327
464
|
|
328
|
-
<p>
|
465
|
+
<p>We strongly encourage adding bug reports with failing tests or at least a reduced example that demonstrates the problem.</p>
|
329
466
|
|
330
|
-
<
|
467
|
+
<p>Similarly, patches should include tests, API documentation, and an update to the manual where relevant. Feel free to clone early though and participate in the project, if you just want some feedback, or a code review before preparing your code to be merged.</p>
|
331
468
|
|
332
|
-
|
469
|
+
<p>If you are unsure about whether you've found a bug, or want to check to see whether we'd be interested in the feature you want to add before you start working on it, feel free to post to our mailing list.</p>
|
333
470
|
|
334
|
-
|
471
|
+
<h2 id="label-License">License<span><a href="#label-License">¶</a> <a href="#top">↑</a></span></h2>
|
335
472
|
|
336
|
-
|
337
|
-
</pre>
|
338
|
-
</li></ul>
|
339
|
-
<hr>
|
473
|
+
<p>SPDX-FileCopyrightText: 2014 Marco Bresciani</p>
|
340
474
|
|
341
|
-
<p>
|
475
|
+
<p>SPDX-License-Identifier: GFDL-1.3-or-later</p>
|
342
476
|
|
343
|
-
<p>
|
477
|
+
<p>(C) 2014 Marco Bresciani</p>
|
344
478
|
|
345
479
|
<p>This file is part of wwwjdic.</p>
|
346
480
|
|
@@ -350,14 +484,12 @@ with wwwjdic. If not, see <http://www.gnu.org/licenses/>.
|
|
350
484
|
|
351
485
|
<p>You should have received a copy of the GNU General Public License along with wwwjdic. If not, see <a href="http://www.gnu.org/licenses">www.gnu.org/licenses</a>/.</p>
|
352
486
|
|
353
|
-
|
354
487
|
</main>
|
355
488
|
|
356
489
|
|
357
|
-
|
358
490
|
<footer id="validator-badges" role="contentinfo">
|
359
491
|
<p><a href="https://validator.w3.org/check/referer">Validate</a>
|
360
|
-
<p>Generated by <a href="https://ruby.github.io/rdoc/">RDoc</a> 6.
|
492
|
+
<p>Generated by <a href="https://ruby.github.io/rdoc/">RDoc</a> 6.3.0.
|
361
493
|
<p>Based on <a href="http://deveiate.org/projects/Darkfish-RDoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
|
362
494
|
</footer>
|
363
495
|
|