wwwjdic 13.0.1 → 14.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.
Files changed (97) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG +19 -1
  3. data/Gemfile +1 -1
  4. data/README.md +79 -73
  5. data/Rakefile +2 -2
  6. data/acknowledgements.md +2 -2
  7. data/authors.md +2 -2
  8. data/copyright.md +4 -4
  9. data/examples/basics.rb +1 -1
  10. data/examples/translate.rb +1 -1
  11. data/examples/uri.rb +1 -1
  12. data/html/CHANGELOG.html +28 -7
  13. data/html/COPYING_md.html +7 -6
  14. data/html/Gemfile.html +8 -7
  15. data/html/Object.html +7 -4
  16. data/html/README_md.html +34 -47
  17. data/html/Rakefile.html +10 -9
  18. data/html/WWWJDic.html +11 -8
  19. data/html/WWWJDic/ParsableDuckType.html +9 -6
  20. data/html/WWWJDic/Parser.html +9 -6
  21. data/html/WWWJDic/Parsers.html +7 -4
  22. data/html/WWWJDic/Parsers/Dict.html +8 -5
  23. data/html/WWWJDic/Parsers/Display.html +8 -5
  24. data/html/WWWJDic/Parsers/Key.html +8 -5
  25. data/html/WWWJDic/Parsers/Search.html +8 -5
  26. data/html/WWWJDic/Parsers/Server.html +8 -5
  27. data/html/WWWJDic/Splitter.html +8 -5
  28. data/html/WWWJDic/Utils.html +8 -5
  29. data/html/WWWJDic/Utils/Downloader.html +7 -4
  30. data/html/WWWJDic/Utils/Downloader/Downloader.html +7 -4
  31. data/html/WWWJDic/Utils/Raisers.html +23 -20
  32. data/html/WWWJDic/WWWJDic.html +14 -11
  33. data/html/acknowledgements_md.html +9 -8
  34. data/html/authors_md.html +9 -8
  35. data/html/copyright_md.html +198 -195
  36. data/html/created.rid +57 -58
  37. data/html/css/rdoc.css +35 -6
  38. data/html/index.html +34 -47
  39. data/html/js/darkfish.js +22 -99
  40. data/html/js/navigation.js +4 -40
  41. data/html/js/navigation.js.gz +0 -0
  42. data/html/js/search.js +32 -31
  43. data/html/js/search_index.js +1 -1
  44. data/html/js/search_index.js.gz +0 -0
  45. data/html/js/searcher.js +6 -6
  46. data/html/js/searcher.js.gz +0 -0
  47. data/html/table_of_contents.html +10 -10
  48. data/lib/wwwjdic.rb +4 -2
  49. data/lib/wwwjdic/application.rb +8 -8
  50. data/lib/wwwjdic/constants.rb +1 -1
  51. data/lib/wwwjdic/locales/de.yml +3 -1
  52. data/lib/wwwjdic/locales/en.yml +3 -1
  53. data/lib/wwwjdic/locales/es.yml +3 -1
  54. data/lib/wwwjdic/locales/fr.yml +3 -2
  55. data/lib/wwwjdic/locales/hu.yml +3 -2
  56. data/lib/wwwjdic/locales/it.yml +3 -2
  57. data/lib/wwwjdic/locales/ja.yml +3 -3
  58. data/lib/wwwjdic/locales/nl.yml +3 -1
  59. data/lib/wwwjdic/locales/ru.yml +3 -1
  60. data/lib/wwwjdic/locales/sl.yml +3 -1
  61. data/lib/wwwjdic/locales/sv.yml +3 -1
  62. data/lib/wwwjdic/parser.rb +3 -3
  63. data/lib/wwwjdic/parsers/dict.rb +2 -2
  64. data/lib/wwwjdic/parsers/display.rb +2 -2
  65. data/lib/wwwjdic/parsers/key.rb +2 -2
  66. data/lib/wwwjdic/parsers/search.rb +2 -2
  67. data/lib/wwwjdic/parsers/server.rb +2 -2
  68. data/lib/wwwjdic/utils/downloader.rb +2 -2
  69. data/lib/wwwjdic/utils/raisers.rb +4 -3
  70. data/lib/wwwjdic/utils/splitter.rb +2 -2
  71. data/lib/wwwjdic/version.rb +16 -8
  72. data/test/test_helper.rb +4 -1
  73. data/test/test_wwwjdic.rb +4 -4
  74. data/test/wwwjdic/locales/de.yml +1 -1
  75. data/test/wwwjdic/locales/en.yml +1 -1
  76. data/test/wwwjdic/locales/es.yml +1 -1
  77. data/test/wwwjdic/locales/fr.yml +1 -1
  78. data/test/wwwjdic/locales/hu.yml +1 -1
  79. data/test/wwwjdic/locales/it.yml +3 -3
  80. data/test/wwwjdic/locales/ja.yml +1 -1
  81. data/test/wwwjdic/locales/nl.yml +1 -1
  82. data/test/wwwjdic/locales/ru.yml +1 -1
  83. data/test/wwwjdic/locales/sl.yml +1 -1
  84. data/test/wwwjdic/locales/sv.yml +1 -1
  85. data/test/wwwjdic/locales/test_locales.rb +11 -11
  86. data/test/wwwjdic/parsers/test_dict.rb +4 -4
  87. data/test/wwwjdic/parsers/test_display.rb +4 -4
  88. data/test/wwwjdic/parsers/test_key.rb +3 -3
  89. data/test/wwwjdic/parsers/test_server.rb +4 -4
  90. data/test/wwwjdic/test_application.rb +30 -30
  91. data/test/wwwjdic/test_parsable_duck_type.rb +3 -3
  92. data/test/wwwjdic/utils/test_downloader.rb +1 -1
  93. data/test/wwwjdic/utils/test_raisers.rb +1 -1
  94. data/wwwjdic.gemspec +15 -14
  95. metadata +26 -28
  96. data/html/js/jquery.js +0 -4
  97. data/html/wwwjdic_gemspec.html +0 -161
@@ -10,10 +10,8 @@ Navigation = new function() {
10
10
  this.initNavigation = function() {
11
11
  var _this = this;
12
12
 
13
- $(document).keydown(function(e) {
13
+ document.addEventListener('keydown', function(e) {
14
14
  _this.onkeydown(e);
15
- }).keyup(function(e) {
16
- _this.onkeyup(e);
17
15
  });
18
16
 
19
17
  this.navigationActive = true;
@@ -21,20 +19,6 @@ Navigation = new function() {
21
19
 
22
20
  this.setNavigationActive = function(state) {
23
21
  this.navigationActive = state;
24
- this.clearMoveTimeout();
25
- }
26
-
27
- this.onkeyup = function(e) {
28
- if (!this.navigationActive) return;
29
-
30
- switch(e.keyCode) {
31
- case 37: //Event.KEY_LEFT:
32
- case 38: //Event.KEY_UP:
33
- case 39: //Event.KEY_RIGHT:
34
- case 40: //Event.KEY_DOWN:
35
- this.clearMoveTimeout();
36
- break;
37
- }
38
22
  }
39
23
 
40
24
  this.onkeydown = function(e) {
@@ -46,7 +30,6 @@ Navigation = new function() {
46
30
  case 38: //Event.KEY_UP:
47
31
  if (e.keyCode == 38 || e.ctrlKey) {
48
32
  if (this.moveUp()) e.preventDefault();
49
- this.startMoveTimeout(false);
50
33
  }
51
34
  break;
52
35
  case 39: //Event.KEY_RIGHT:
@@ -55,33 +38,14 @@ Navigation = new function() {
55
38
  case 40: //Event.KEY_DOWN:
56
39
  if (e.keyCode == 40 || e.ctrlKey) {
57
40
  if (this.moveDown()) e.preventDefault();
58
- this.startMoveTimeout(true);
59
41
  }
60
42
  break;
61
43
  case 13: //Event.KEY_RETURN:
62
- if (this.$current) e.preventDefault();
63
- this.select(this.$current);
44
+ if (this.current) e.preventDefault();
45
+ this.select(this.current);
64
46
  break;
65
47
  }
66
- if (e.ctrlKey && e.shiftKey) this.select(this.$current);
67
- }
68
-
69
- this.clearMoveTimeout = function() {
70
- clearTimeout(this.moveTimeout);
71
- this.moveTimeout = null;
72
- }
73
-
74
- this.startMoveTimeout = function(isDown) {
75
- if (!$.browser.mozilla && !$.browser.opera) return;
76
- if (this.moveTimeout) this.clearMoveTimeout();
77
- var _this = this;
78
-
79
- var go = function() {
80
- if (!_this.moveTimeout) return;
81
- _this[isDown ? 'moveDown' : 'moveUp']();
82
- _this.moveTimeout = setTimeout(go, 100);
83
- }
84
- this.moveTimeout = setTimeout(go, 200);
48
+ if (e.ctrlKey && e.shiftKey) this.select(this.current);
85
49
  }
86
50
 
87
51
  this.moveRight = function() {
Binary file
@@ -1,29 +1,29 @@
1
1
  Search = function(data, input, result) {
2
2
  this.data = data;
3
- this.$input = $(input);
4
- this.$result = $(result);
3
+ this.input = input;
4
+ this.result = result;
5
5
 
6
- this.$current = null;
7
- this.$view = this.$result.parent();
6
+ this.current = null;
7
+ this.view = this.result.parentNode;
8
8
  this.searcher = new Searcher(data.index);
9
9
  this.init();
10
10
  }
11
11
 
12
- Search.prototype = $.extend({}, Navigation, new function() {
12
+ Search.prototype = Object.assign({}, Navigation, new function() {
13
13
  var suid = 1;
14
14
 
15
15
  this.init = function() {
16
16
  var _this = this;
17
17
  var observer = function(e) {
18
- switch(e.originalEvent.keyCode) {
18
+ switch(e.keyCode) {
19
19
  case 38: // Event.KEY_UP
20
20
  case 40: // Event.KEY_DOWN
21
21
  return;
22
22
  }
23
- _this.search(_this.$input[0].value);
23
+ _this.search(_this.input.value);
24
24
  };
25
- this.$input.keyup(observer);
26
- this.$input.click(observer); // mac's clear field
25
+ this.input.addEventListener('keyup', observer);
26
+ this.input.addEventListener('click', observer); // mac's clear field
27
27
 
28
28
  this.searcher.ready(function(results, isLast) {
29
29
  _this.addResults(results, isLast);
@@ -34,7 +34,7 @@ Search.prototype = $.extend({}, Navigation, new function() {
34
34
  }
35
35
 
36
36
  this.search = function(value, selectFirstMatch) {
37
- value = jQuery.trim(value).toLowerCase();
37
+ value = value.trim().toLowerCase();
38
38
  if (value) {
39
39
  this.setNavigationActive(true);
40
40
  } else {
@@ -43,23 +43,23 @@ Search.prototype = $.extend({}, Navigation, new function() {
43
43
 
44
44
  if (value == '') {
45
45
  this.lastQuery = value;
46
- this.$result.empty();
47
- this.$result.attr('aria-expanded', 'false');
46
+ this.result.innerHTML = '';
47
+ this.result.setAttribute('aria-expanded', 'false');
48
48
  this.setNavigationActive(false);
49
49
  } else if (value != this.lastQuery) {
50
50
  this.lastQuery = value;
51
- this.$result.attr('aria-busy', 'true');
52
- this.$result.attr('aria-expanded', 'true');
51
+ this.result.setAttribute('aria-busy', 'true');
52
+ this.result.setAttribute('aria-expanded', 'true');
53
53
  this.firstRun = true;
54
54
  this.searcher.find(value);
55
55
  }
56
56
  }
57
57
 
58
58
  this.addResults = function(results, isLast) {
59
- var target = this.$result.get(0);
59
+ var target = this.result;
60
60
  if (this.firstRun && (results.length > 0 || isLast)) {
61
- this.$current = null;
62
- this.$result.empty();
61
+ this.current = null;
62
+ this.result.innerHTML = '';
63
63
  }
64
64
 
65
65
  for (var i=0, l = results.length; i < l; i++) {
@@ -70,25 +70,26 @@ Search.prototype = $.extend({}, Navigation, new function() {
70
70
 
71
71
  if (this.firstRun && results.length > 0) {
72
72
  this.firstRun = false;
73
- this.$current = $(target.firstChild);
74
- this.$current.addClass('search-selected');
73
+ this.current = target.firstChild;
74
+ this.current.classList.add('search-selected');
75
75
  }
76
- if (jQuery.browser.msie) this.$element[0].className += '';
76
+ //TODO: ECMAScript
77
+ //if (jQuery.browser.msie) this.$element[0].className += '';
77
78
 
78
- if (isLast) this.$result.attr('aria-busy', 'false');
79
+ if (isLast) this.result.setAttribute('aria-busy', 'false');
79
80
  }
80
81
 
81
82
  this.move = function(isDown) {
82
- if (!this.$current) return;
83
- var $next = this.$current[isDown ? 'next' : 'prev']();
84
- if ($next.length) {
85
- this.$current.removeClass('search-selected');
86
- $next.addClass('search-selected');
87
- this.$input.attr('aria-activedescendant', $next.attr('id'));
88
- this.scrollIntoView($next[0], this.$view[0]);
89
- this.$current = $next;
90
- this.$input.val($next[0].firstChild.firstChild.text);
91
- this.$input.select();
83
+ if (!this.current) return;
84
+ var next = isDown ? this.current.nextElementSibling : this.current.previousElementSibling;
85
+ if (next) {
86
+ this.current.classList.remove('search-selected');
87
+ next.classList.add('search-selected');
88
+ this.input.setAttribute('aria-activedescendant', next.getAttribute('id'));
89
+ this.scrollIntoView(next, this.view);
90
+ this.current = next;
91
+ this.input.value = next.firstChild.firstChild.text;
92
+ this.input.select();
92
93
  }
93
94
  return true;
94
95
  }
@@ -1 +1 @@
1
- var search_data = {"index":{"searchIndex":["object","wwwjdic","parsableducktype","parser","parsers","dict","display","key","search","server","splitter","utils","downloader","downloader","raisers","wwwjdic","breener()","content()","dictionary()","dictionary=()","download_file()","json_translate()","json_uri()","lines()","load_yaml_file()","message()","new()","new()","new()","parse()","parse()","parse()","parse()","parse()","parse()","raiser_array()","raiser_downcase()","raiser_to_i()","raw_uri()","reset()","server()","server=()","test_parsable_duck_type()","title()","to_s()","translate()","translation()","uri()","changelog","copying","gemfile","readme","rakefile","acknowledgements","authors","copyright","wwwjdic.gemspec"],"longSearchIndex":["object","wwwjdic","wwwjdic::parsableducktype","wwwjdic::parser","wwwjdic::parsers","wwwjdic::parsers::dict","wwwjdic::parsers::display","wwwjdic::parsers::key","wwwjdic::parsers::search","wwwjdic::parsers::server","wwwjdic::splitter","wwwjdic::utils","wwwjdic::utils::downloader","wwwjdic::utils::downloader::downloader","wwwjdic::utils::raisers","wwwjdic::wwwjdic","wwwjdic::breener()","wwwjdic::splitter#content()","wwwjdic::wwwjdic#dictionary()","wwwjdic::wwwjdic#dictionary=()","wwwjdic::utils::downloader::downloader::download_file()","wwwjdic::wwwjdic#json_translate()","wwwjdic::wwwjdic#json_uri()","wwwjdic::splitter#lines()","object#load_yaml_file()","wwwjdic::splitter#message()","wwwjdic::parser::new()","wwwjdic::splitter::new()","wwwjdic::wwwjdic::new()","wwwjdic::parser#parse()","wwwjdic::parsers::dict#parse()","wwwjdic::parsers::display#parse()","wwwjdic::parsers::key#parse()","wwwjdic::parsers::search#parse()","wwwjdic::parsers::server#parse()","wwwjdic::utils::raisers#raiser_array()","wwwjdic::utils::raisers#raiser_downcase()","wwwjdic::utils::raisers#raiser_to_i()","wwwjdic::wwwjdic#raw_uri()","wwwjdic::wwwjdic#reset()","wwwjdic::wwwjdic#server()","wwwjdic::wwwjdic#server=()","wwwjdic::parsableducktype#test_parsable_duck_type()","wwwjdic::splitter#title()","wwwjdic::wwwjdic#to_s()","wwwjdic::wwwjdic#translate()","wwwjdic::splitter#translation()","wwwjdic::wwwjdic#uri()","","","","","","","","",""],"info":[["Object","","Object.html","",""],["WWWJDic","","WWWJDic.html","","<p>Author &mdash; Marco Bresciani\n<p>Copyright &mdash; Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani\n<p>License … &mdash; "],["WWWJDic::ParsableDuckType","","WWWJDic/ParsableDuckType.html","","<p>This module represents the parsable duck type element for testing purposes.\n<p>Author &mdash; Marco Bresciani\n<p>Copyright … &mdash; "],["WWWJDic::Parser","","WWWJDic/Parser.html","","<p>This class is a simple utility that is used to parse and filter parameters for wwwjdic.\n<p>Author &mdash; Marco Bresciani …\n"],["WWWJDic::Parsers","","WWWJDic/Parsers.html","",""],["WWWJDic::Parsers::Dict","","WWWJDic/Parsers/Dict.html","","<p>This class is an implementation of the Parsable duck type that checks the dictionary type. The only needed …\n"],["WWWJDic::Parsers::Display","","WWWJDic/Parsers/Display.html","","<p>This class is an implementation of the Parsable duck type that checks the display type. The only needed …\n"],["WWWJDic::Parsers::Key","","WWWJDic/Parsers/Key.html","","<p>This class is an implementation of the Parsable duck type that checks the display type. The only needed …\n"],["WWWJDic::Parsers::Search","","WWWJDic/Parsers/Search.html","","<p>This class is an implementation of the Parsable duck type that checks the display type. The only needed …\n"],["WWWJDic::Parsers::Server","","WWWJDic/Parsers/Server.html","","<p>This class is an implementation of the Parsable duck type that checks the display type. The only needed …\n"],["WWWJDic::Splitter","","WWWJDic/Splitter.html","","<p>This class is a simple API to interact with WWWJDic Backboor Entry/API.\n<p>Author &mdash; Marco Bresciani\n<p>Copyright … &mdash; "],["WWWJDic::Utils","","WWWJDic/Utils.html","","<p>This module is a simple collection of useful things and methods that I prefer to keep as DRYer as possible. …\n"],["WWWJDic::Utils::Downloader","","WWWJDic/Utils/Downloader.html","","<p>This module is a simple wrapper container for Peter R. Marreck&#39;s gist.\n<p>Author &mdash; Jon Maken\n<p>License &mdash; 3-clause …\n"],["WWWJDic::Utils::Downloader::Downloader","","WWWJDic/Utils/Downloader/Downloader.html","","<p>!/usr/bin/env ruby\n\n<pre>An HTTP/HTTPS/FTP file downloader library/CLI based upon\nMiniPortile&#39;s HTTP implementation. ...</pre>\n"],["WWWJDic::Utils::Raisers","","WWWJDic/Utils/Raisers.html","","<p>This module contains some utility method to raise errors according to (possibly) common conditions.\n<p>Author … &mdash; "],["WWWJDic::WWWJDic","","WWWJDic/WWWJDic.html","","<p>This class is a simple API to interact with WWWJDic Backboor Entry/API.\n<p>Author &mdash; Marco Bresciani\n<p>Copyright … &mdash; "],["breener","WWWJDic","WWWJDic.html#method-c-breener","()","<p>Creates a new WWWJDic object (from the verb &#39;to Breen&#39;… :) ).\n<p>Usage &mdash; <p><code>new_wwwjdic = WWWJDic::breener</code> …\n\n"],["content","WWWJDic::Splitter","WWWJDic/Splitter.html#method-i-content","()",""],["dictionary","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-dictionary","()","<p>Return the default used dictionary string, if any.\n<p>Returns &mdash; a String with the dictionary full name.\n\n"],["dictionary=","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-dictionary-3D","(dict)","<p>Configure the default used dictionary using either code/number or (exact) string.\n<p>Usage &mdash; &lt;tt&gt;new_wwwjdic.dictionary= …\n"],["download_file","WWWJDic::Utils::Downloader::Downloader","WWWJDic/Utils/Downloader/Downloader.html#method-c-download_file","(url, full_path, count = 3)",""],["json_translate","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-json_translate","(word = nil, args = {}, filename = nil)","<p>Save a file, with specified <code>filename</code>, that contains the current wwwjdic configuration, in JSON format. …\n"],["json_uri","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-json_uri","(word = nil, args = {})","<p>Create the reference uri for a <code>word</code> translation, according to specified parameters, with JSON output. …\n"],["lines","WWWJDic::Splitter","WWWJDic/Splitter.html#method-i-lines","()",""],["load_yaml_file","Object","Object.html#method-i-load_yaml_file","(locale)",""],["message","WWWJDic::Splitter","WWWJDic/Splitter.html#method-i-message","()",""],["new","WWWJDic::Parser","WWWJDic/Parser.html#method-c-new","(args = {})",""],["new","WWWJDic::Splitter","WWWJDic/Splitter.html#method-c-new","(translation)","<p>Creates a <code>Splitter</code> object.\n<p>Usage &mdash; <code>new_splitter = Splitter.new translation_content</code>\n<p>Returns &mdash; a <code>Splitter</code> object. …\n"],["new","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-c-new","(parser)","<p>Creates a <code>WWWJDic</code> object. This constructor should be used through the WWWJDic::breener method only.\n<p>Usage … &mdash; "],["parse","WWWJDic::Parser","WWWJDic/Parser.html#method-i-parse","(method = nil, value = nil)","<p>Provides the duck type for a generic parsing object.\n"],["parse","WWWJDic::Parsers::Dict","WWWJDic/Parsers/Dict.html#method-i-parse","(value = '1')","<p>The parsable duck type interface to every parser usage.\n"],["parse","WWWJDic::Parsers::Display","WWWJDic/Parsers/Display.html#method-i-parse","(value = :display)","<p>The parsable duck type interface to every parser usage.\n"],["parse","WWWJDic::Parsers::Key","WWWJDic/Parsers/Key.html#method-i-parse","(value = :exact)","<p>The parsable duck type interface to every parser usage.\n"],["parse","WWWJDic::Parsers::Search","WWWJDic/Parsers/Search.html#method-i-parse","(value = '')","<p>The parsable duck type interface to every parser usage.\n"],["parse","WWWJDic::Parsers::Server","WWWJDic/Parsers/Server.html#method-i-parse","(value = :edrdg)","<p>The parsable duck type interface to every parser usage.\n"],["raiser_array","WWWJDic::Utils::Raisers","WWWJDic/Utils/Raisers.html#method-i-raiser_array","(name = 'error.value', value = nil, array = nil)","<p>Raises an <code>ArgumentError</code> according to parameters, unless the <code>array</code> contains the exact <code>value</code>.\n"],["raiser_downcase","WWWJDic::Utils::Raisers","WWWJDic/Utils/Raisers.html#method-i-raiser_downcase","(name = 'error.value', value = nil, array = nil)","<p>Raises an <code>ArgumentError</code> according to parameters, unless the <code>array</code> contains a downcased <code>value</code>.\n"],["raiser_to_i","WWWJDic::Utils::Raisers","WWWJDic/Utils/Raisers.html#method-i-raiser_to_i","(name = 'error.value', value = nil, array = nil)","<p>Raises an <code>ArgumentError</code> according to parameters, unless the <code>array</code> contains the number of the <code>value</code>.\n"],["raw_uri","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-raw_uri","(word = nil, args = {})","<p>Create the reference uri for a <code>word</code> translation, according to specified parameters, overriding for raw …\n"],["reset","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-reset","()","<p>Restores the original status cleaning up the (possibly) previously saved URIs restoring the default …\n"],["server","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-server","()","<p>Return the selected server URI\n<p>Returns &mdash; a String with the dictionary full name.\n\n"],["server=","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-server-3D","(server = :edrdg)","<p>Store the Backdoor Entry/API server name, default to EDRDG.Org (:edrdg) instead of Monash (:monash). …\n"],["test_parsable_duck_type","WWWJDic::ParsableDuckType","WWWJDic/ParsableDuckType.html#method-i-test_parsable_duck_type","()","<p>The method that tests the parsable duck type interface and its <code>parse</code> method.\n"],["title","WWWJDic::Splitter","WWWJDic/Splitter.html#method-i-title","()",""],["to_s","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-to_s","()",""],["translate","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-translate","(word = nil, args = {}, filename = nil)","<p>Save a file, with specified <code>filename</code>, that contains the current wwwjdic configuration. Uses the internal …\n"],["translation","WWWJDic::Splitter","WWWJDic/Splitter.html#method-i-translation","()",""],["uri","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-uri","(word = nil, args = {})","<p>Create the reference uri for a <code>word</code> translation, according to specified parameters.\n<p>Usage &mdash; &lt;tt&gt;new_wwwjdic.uri …\n\n"],["CHANGELOG","","CHANGELOG.html","","<p>Version 13.0.1\n\n<pre>* PATCH updating gem dependencies.\n* IN PROGRESS: translation example.\n* IN PROGRESS: restoring ...</pre>\n"],["COPYING","","COPYING_md.html","","<p>GNU GENERAL PUBLIC LICENSE\n<p>Version 3, 29 June 2007\n<p>Copyright (C) 2007 Free Software Foundation, Inc.\nfsf.org ...\n"],["Gemfile","","Gemfile.html","","<p># wwwjdic # Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani # # This file is part of …\n"],["README","","README_md.html","","<p>WWWJDic\n<p><img src=\"https://img.shields.io/gem/v/wwwjdic.svg?style=plastic\">\n<img src=\"https://img.shields.io/gem/dt/wwwjdic.svg?style=plastic\"> ...\n"],["Rakefile","","Rakefile.html","","<p># wwwjdic # Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani # # This file is part of …\n"],["acknowledgements","","acknowledgements_md.html","","<p>Acknowledgements\n<p>FSIJ理事会の理事長、新部裕さんの日本語の翻訳。 Japanese translation by\nYutaka Niibe, President of Free Software ...\n"],["authors","","authors_md.html","","<p>Project and gem owned by\n<p><em>Author</em>: Marco Bresciani\n\n<p>Authors list (in appearing order)\n"],["copyright","","copyright_md.html","","<p>Copyright Notes\n<p>2019-02-26 update.\n<p>wwwjdic\n"],["wwwjdic.gemspec","","wwwjdic_gemspec.html","","<p># wwwjdic # Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani # # This file is part of …\n"]]}}
1
+ var search_data = {"index":{"searchIndex":["object","wwwjdic","parsableducktype","parser","parsers","dict","display","key","search","server","splitter","utils","downloader","downloader","raisers","wwwjdic","breener()","content()","dictionary()","dictionary=()","download_file()","json_translate()","json_uri()","lines()","load_yaml_file()","message()","new()","new()","new()","parse()","parse()","parse()","parse()","parse()","parse()","raiser_array()","raiser_downcase()","raiser_to_i()","raw_uri()","reset()","server()","server=()","test_parsable_duck_type()","title()","to_s()","translate()","translation()","uri()","changelog","copying","gemfile","readme","rakefile","acknowledgements","authors","copyright"],"longSearchIndex":["object","wwwjdic","wwwjdic::parsableducktype","wwwjdic::parser","wwwjdic::parsers","wwwjdic::parsers::dict","wwwjdic::parsers::display","wwwjdic::parsers::key","wwwjdic::parsers::search","wwwjdic::parsers::server","wwwjdic::splitter","wwwjdic::utils","wwwjdic::utils::downloader","wwwjdic::utils::downloader::downloader","wwwjdic::utils::raisers","wwwjdic::wwwjdic","wwwjdic::breener()","wwwjdic::splitter#content()","wwwjdic::wwwjdic#dictionary()","wwwjdic::wwwjdic#dictionary=()","wwwjdic::utils::downloader::downloader::download_file()","wwwjdic::wwwjdic#json_translate()","wwwjdic::wwwjdic#json_uri()","wwwjdic::splitter#lines()","object#load_yaml_file()","wwwjdic::splitter#message()","wwwjdic::parser::new()","wwwjdic::splitter::new()","wwwjdic::wwwjdic::new()","wwwjdic::parser#parse()","wwwjdic::parsers::dict#parse()","wwwjdic::parsers::display#parse()","wwwjdic::parsers::key#parse()","wwwjdic::parsers::search#parse()","wwwjdic::parsers::server#parse()","wwwjdic::utils::raisers#raiser_array()","wwwjdic::utils::raisers#raiser_downcase()","wwwjdic::utils::raisers#raiser_to_i()","wwwjdic::wwwjdic#raw_uri()","wwwjdic::wwwjdic#reset()","wwwjdic::wwwjdic#server()","wwwjdic::wwwjdic#server=()","wwwjdic::parsableducktype#test_parsable_duck_type()","wwwjdic::splitter#title()","wwwjdic::wwwjdic#to_s()","wwwjdic::wwwjdic#translate()","wwwjdic::splitter#translation()","wwwjdic::wwwjdic#uri()","","","","","","","",""],"info":[["Object","","Object.html","",""],["WWWJDic","","WWWJDic.html","","<p>Author &mdash; Marco Bresciani\n<p>Copyright &mdash; Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani …\n"],["WWWJDic::ParsableDuckType","","WWWJDic/ParsableDuckType.html","","<p>This module represents the parsable duck type element for testing purposes.\n<p>Author &mdash; Marco Bresciani\n<p>Copyright … &mdash; "],["WWWJDic::Parser","","WWWJDic/Parser.html","","<p>This class is a simple utility that is used to parse and filter parameters for wwwjdic.\n<p>Author &mdash; Marco Bresciani …\n"],["WWWJDic::Parsers","","WWWJDic/Parsers.html","",""],["WWWJDic::Parsers::Dict","","WWWJDic/Parsers/Dict.html","","<p>This class is an implementation of the Parsable duck type that checks the dictionary type. The only needed …\n"],["WWWJDic::Parsers::Display","","WWWJDic/Parsers/Display.html","","<p>This class is an implementation of the Parsable duck type that checks the display type. The only needed …\n"],["WWWJDic::Parsers::Key","","WWWJDic/Parsers/Key.html","","<p>This class is an implementation of the Parsable duck type that checks the display type. The only needed …\n"],["WWWJDic::Parsers::Search","","WWWJDic/Parsers/Search.html","","<p>This class is an implementation of the Parsable duck type that checks the display type. The only needed …\n"],["WWWJDic::Parsers::Server","","WWWJDic/Parsers/Server.html","","<p>This class is an implementation of the Parsable duck type that checks the display type. The only needed …\n"],["WWWJDic::Splitter","","WWWJDic/Splitter.html","","<p>This class is a simple API to interact with WWWJDic Backboor Entry/API.\n<p>Author &mdash; Marco Bresciani\n<p>Copyright … &mdash; "],["WWWJDic::Utils","","WWWJDic/Utils.html","","<p>This module is a simple collection of useful things and methods that I prefer to keep as DRYer as possible. …\n"],["WWWJDic::Utils::Downloader","","WWWJDic/Utils/Downloader.html","","<p>This module is a simple wrapper container for Peter R. Marreck&#39;s gist.\n<p>Author &mdash; Jon Maken\n<p>License &mdash; 3-clause …\n"],["WWWJDic::Utils::Downloader::Downloader","","WWWJDic/Utils/Downloader/Downloader.html","","<p>!/usr/bin/env ruby\n\n<pre>An HTTP/HTTPS/FTP file downloader library/CLI based upon\nMiniPortile&#39;s HTTP implementation. ...</pre>\n"],["WWWJDic::Utils::Raisers","","WWWJDic/Utils/Raisers.html","","<p>This module contains some utility method to raise errors according to (possibly) common conditions.\n<p>Author … &mdash; "],["WWWJDic::WWWJDic","","WWWJDic/WWWJDic.html","","<p>This class is a simple API to interact with WWWJDic Backboor Entry/API.\n<p>Author &mdash; Marco Bresciani\n<p>Copyright … &mdash; "],["breener","WWWJDic","WWWJDic.html#method-c-breener","()","<p>Creates a new WWWJDic object (from the verb &#39;to Breen&#39;… :) ).\n<p>Usage &mdash; <p><code>new_wwwjdic = WWWJDic::breener</code> …\n\n"],["content","WWWJDic::Splitter","WWWJDic/Splitter.html#method-i-content","()",""],["dictionary","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-dictionary","()","<p>Return the default used dictionary string, if any.\n<p>Returns &mdash; a String with the dictionary full name.\n\n"],["dictionary=","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-dictionary-3D","(dict)","<p>Configure the default used dictionary using either code/number or (exact) string.\n<p>Usage &mdash; &lt;tt&gt;new_wwwjdic.dictionary= …\n"],["download_file","WWWJDic::Utils::Downloader::Downloader","WWWJDic/Utils/Downloader/Downloader.html#method-c-download_file","(url, full_path, count = 3)",""],["json_translate","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-json_translate","(word = nil, args = {}, filename = nil)","<p>Save a file, with specified <code>filename</code>, that contains the current wwwjdic configuration, in JSON format. …\n"],["json_uri","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-json_uri","(word = nil, args = {})","<p>Create the reference uri for a <code>word</code> translation, according to specified parameters, with JSON output. …\n"],["lines","WWWJDic::Splitter","WWWJDic/Splitter.html#method-i-lines","()",""],["load_yaml_file","Object","Object.html#method-i-load_yaml_file","(locale)",""],["message","WWWJDic::Splitter","WWWJDic/Splitter.html#method-i-message","()",""],["new","WWWJDic::Parser","WWWJDic/Parser.html#method-c-new","(args = {})",""],["new","WWWJDic::Splitter","WWWJDic/Splitter.html#method-c-new","(translation)","<p>Creates a <code>Splitter</code> object.\n<p>Usage &mdash; <code>new_splitter = Splitter.new translation_content</code>\n<p>Returns &mdash; a <code>Splitter</code> object. …\n"],["new","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-c-new","(parser)","<p>Creates a <code>WWWJDic</code> object. This constructor should be used through the WWWJDic::breener method only.\n<p>Usage … &mdash; "],["parse","WWWJDic::Parser","WWWJDic/Parser.html#method-i-parse","(method = nil, value = nil)","<p>Provides the duck type for a generic parsing object.\n"],["parse","WWWJDic::Parsers::Dict","WWWJDic/Parsers/Dict.html#method-i-parse","(value = '1')","<p>The parsable duck type interface to every parser usage.\n"],["parse","WWWJDic::Parsers::Display","WWWJDic/Parsers/Display.html#method-i-parse","(value = :display)","<p>The parsable duck type interface to every parser usage.\n"],["parse","WWWJDic::Parsers::Key","WWWJDic/Parsers/Key.html#method-i-parse","(value = :exact)","<p>The parsable duck type interface to every parser usage.\n"],["parse","WWWJDic::Parsers::Search","WWWJDic/Parsers/Search.html#method-i-parse","(value = '')","<p>The parsable duck type interface to every parser usage.\n"],["parse","WWWJDic::Parsers::Server","WWWJDic/Parsers/Server.html#method-i-parse","(value = :edrdg)","<p>The parsable duck type interface to every parser usage.\n"],["raiser_array","WWWJDic::Utils::Raisers","WWWJDic/Utils/Raisers.html#method-i-raiser_array","(name = 'error.value', value = nil, array = nil)","<p>Raises an <code>ArgumentError</code> according to parameters, unless the <code>array</code> contains the exact <code>value</code>.\n"],["raiser_downcase","WWWJDic::Utils::Raisers","WWWJDic/Utils/Raisers.html#method-i-raiser_downcase","(name = 'error.value', value = nil, array = nil)","<p>Raises an <code>ArgumentError</code> according to parameters, unless the <code>array</code> contains a downcased <code>value</code>.\n"],["raiser_to_i","WWWJDic::Utils::Raisers","WWWJDic/Utils/Raisers.html#method-i-raiser_to_i","(name = 'error.value', value = nil, array = nil)","<p>Raises an <code>ArgumentError</code> according to parameters, unless the <code>array</code> contains the number of the <code>value</code>.\n"],["raw_uri","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-raw_uri","(word = nil, args = {})","<p>Create the reference uri for a <code>word</code> translation, according to specified parameters, overriding for raw …\n"],["reset","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-reset","()","<p>Restores the original status cleaning up the (possibly) previously saved URIs restoring the default …\n"],["server","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-server","()","<p>Return the selected server URI\n<p>Returns &mdash; a String with the dictionary full name.\n\n"],["server=","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-server-3D","(server = :edrdg)","<p>Store the Backdoor Entry/API server name, default to EDRDG.Org (:edrdg) instead of Monash (:monash). …\n"],["test_parsable_duck_type","WWWJDic::ParsableDuckType","WWWJDic/ParsableDuckType.html#method-i-test_parsable_duck_type","()","<p>The method that tests the parsable duck type interface and its <code>parse</code> method.\n"],["title","WWWJDic::Splitter","WWWJDic/Splitter.html#method-i-title","()",""],["to_s","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-to_s","()",""],["translate","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-translate","(word = nil, args = {}, filename = nil)","<p>Save a file, with specified <code>filename</code>, that contains the current wwwjdic configuration. Uses the internal …\n"],["translation","WWWJDic::Splitter","WWWJDic/Splitter.html#method-i-translation","()",""],["uri","WWWJDic::WWWJDic","WWWJDic/WWWJDic.html#method-i-uri","(word = nil, args = {})","<p>Create the reference uri for a <code>word</code> translation, according to specified parameters.\n<p>Usage &mdash; &lt;tt&gt;new_wwwjdic.uri …\n\n"],["CHANGELOG","","CHANGELOG.html","","<p>Version 14.0.0\n\n<pre>* MAJOR update from Ruby &#39;~&gt; 2.6&#39; to Ruby &#39;~&gt; 2.7&#39;.\n* MINOR update IntelliJ IDEA (RubyGem) ...</pre>\n"],["COPYING","","COPYING_md.html","","<p>GNU GENERAL PUBLIC LICENSE\n<p>Version 3, 29 June 2007\n<p>Copyright (C) 2007 Free Software Foundation, Inc.\nfsf.org ...\n"],["Gemfile","","Gemfile.html","","<p># wwwjdic # Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani # # This file is part …\n"],["README","","README_md.html","","<p>WWWJDic\n<p><img src=\"https://img.shields.io/gem/v/wwwjdic.svg?style=plastic\">\n<img src=\"https://img.shields.io/gem/dt/wwwjdic.svg?style=plastic\"> ...\n"],["Rakefile","","Rakefile.html","","<p># wwwjdic # Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani # # This file is part …\n"],["acknowledgements","","acknowledgements_md.html","","<p>Acknowledgements\n<p>FSIJ理事会の理事長、新部裕さんの日本語の翻訳。 Japanese translation by\nYutaka Niibe, President of Free Software ...\n"],["authors","","authors_md.html","","<p>Project and gem owned by\n<p><em>Author</em>: Marco Bresciani\n\n<p>Authors list (in appearing order)\n"],["copyright","","copyright_md.html","","<p>Copyright Notes\n<p>2020-03-12 update.\n<p>wwwjdic\n"]]}}
Binary file
@@ -51,20 +51,20 @@ Searcher.prototype = new function() {
51
51
 
52
52
  /* ----- Utilities ------ */
53
53
  function splitQuery(query) {
54
- return jQuery.grep(query.split(/(\s+|::?|\(\)?)/), function(string) {
54
+ return query.split(/(\s+|::?|\(\)?)/).filter(function(string) {
55
55
  return string.match(/\S/);
56
56
  });
57
57
  }
58
58
 
59
59
  function buildRegexps(queries) {
60
- return jQuery.map(queries, function(query) {
60
+ return queries.map(function(query) {
61
61
  return new RegExp(query.replace(/(.)/g, '([$1])([^$1]*?)'), 'i');
62
62
  });
63
63
  }
64
64
 
65
65
  function buildHilighters(queries) {
66
- return jQuery.map(queries, function(query) {
67
- return jQuery.map(query.split(''), function(l, i) {
66
+ return queries.map(function(query) {
67
+ return query.split('').map(function(l, i) {
68
68
  return '\u0001$' + (i*2+1) + '\u0002$' + (i*2+2);
69
69
  }).join('');
70
70
  });
@@ -221,9 +221,9 @@ Searcher.prototype = new function() {
221
221
  }
222
222
 
223
223
  function triggerResults(results, isLast) {
224
- jQuery.each(this.handlers, function(i, fn) {
224
+ this.handlers.forEach(function(fn) {
225
225
  fn.call(this, results, isLast)
226
- })
226
+ });
227
227
  }
228
228
  }
229
229
 
Binary file
@@ -4,15 +4,18 @@
4
4
  <head>
5
5
  <meta charset="UTF-8">
6
6
 
7
- <title>Table of Contents - wwwjdic 13.0.1</title>
7
+ <title>Table of Contents - wwwjdic 14.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/jquery.js"></script>
15
- <script src="./js/darkfish.js"></script>
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">
@@ -22,7 +25,7 @@
22
25
 
23
26
  <body id="top" class="table-of-contents">
24
27
  <main role="main">
25
- <h1 class="class">Table of Contents - wwwjdic 13.0.1</h1>
28
+ <h1 class="class">Table of Contents - wwwjdic 14.0.0</h1>
26
29
 
27
30
 
28
31
 
@@ -34,6 +37,8 @@
34
37
 
35
38
  <ul>
36
39
 
40
+ <li><a href="CHANGELOG.html#label-Version+14.0.0">Version 14.0.0</a>
41
+
37
42
  <li><a href="CHANGELOG.html#label-Version+13.0.1">Version 13.0.1</a>
38
43
 
39
44
  <li><a href="CHANGELOG.html#label-Version+13.0.0">Version 13.0.0</a>
@@ -275,11 +280,6 @@
275
280
 
276
281
  </li>
277
282
 
278
- <li class="file">
279
- <a href="wwwjdic_gemspec.html">wwwjdic.gemspec</a>
280
-
281
- </li>
282
-
283
283
  </ul>
284
284
 
285
285
 
@@ -537,7 +537,7 @@
537
537
 
538
538
  <footer id="validator-badges" role="contentinfo">
539
539
  <p><a href="https://validator.w3.org/check/referer">Validate</a>
540
- <p>Generated by <a href="https://ruby.github.io/rdoc/">RDoc</a> 6.1.1.
540
+ <p>Generated by <a href="https://ruby.github.io/rdoc/">RDoc</a> 6.2.1.
541
541
  <p>Based on <a href="http://deveiate.org/projects/Darkfish-RDoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
542
542
  </footer>
543
543
 
@@ -1,5 +1,6 @@
1
+ #--
1
2
  # wwwjdic
2
- # Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
3
+ # Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
3
4
  #
4
5
  # This file is part of wwwjdic.
5
6
  #
@@ -15,6 +16,7 @@
15
16
  #
16
17
  # You should have received a copy of the GNU General Public License
17
18
  # along with wwwjdic. If not, see <http://www.gnu.org/licenses/>.
19
+ #++
18
20
 
19
21
  require 'digest/md5'
20
22
  require 'i18n'
@@ -29,7 +31,7 @@ require_relative 'wwwjdic/parsers/search'
29
31
  require_relative 'wwwjdic/parsers/server'
30
32
 
31
33
  # Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
32
- # Copyright:: Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
34
+ # Copyright:: Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
33
35
  # License:: GNU General Public License version 3
34
36
  module WWWJDic
35
37
 
@@ -1,6 +1,6 @@
1
1
  #--
2
2
  # wwwjdic
3
- # Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
3
+ # Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
4
4
  #
5
5
  # This file is part of wwwjdic.
6
6
  #
@@ -29,7 +29,7 @@ module WWWJDic
29
29
  # This class is a simple API to interact with WWWJDic Backboor
30
30
  # Entry/API.
31
31
  # Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
32
- # Copyright:: Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
32
+ # Copyright:: Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
33
33
  # License:: GNU General Public License version 3
34
34
  class WWWJDic
35
35
 
@@ -55,7 +55,7 @@ module WWWJDic
55
55
  raise ArgumentError, I18n.t('error.param', value: word) if word.empty?
56
56
  raise ArgumentError, I18n.t('error.param', value: args) unless args.keys.to_set.proper_subset? Set.new(ALLOWED_PARAMS)
57
57
 
58
- params = Hash.new
58
+ params = {}
59
59
  params[:search] = word
60
60
  @defaults[:search] = word
61
61
 
@@ -74,7 +74,7 @@ module WWWJDic
74
74
  #
75
75
  # Usage:: <tt>new_wwwjdic.raw_uri word
76
76
  def raw_uri(word = nil, args = {})
77
- args = Hash.new if args.nil?
77
+ args = {} if args.nil?
78
78
  args[:display] = :raw
79
79
  uri(word, args)
80
80
  end
@@ -86,7 +86,7 @@ module WWWJDic
86
86
  def json_uri(word = nil, args = {})
87
87
  an_uri = uri(word, args)
88
88
 
89
- result = Hash.new
89
+ result = {}
90
90
  result[word] = an_uri
91
91
 
92
92
  result.to_json
@@ -117,7 +117,7 @@ module WWWJDic
117
117
  def json_translate(word = nil, args = {}, filename = nil)
118
118
  translation = translate(word, args)
119
119
 
120
- a_hash = Hash.new
120
+ a_hash = {}
121
121
  a_hash[word.to_sym] = raw_uri(word, args)
122
122
 
123
123
  the_splitter = Splitter.new translation
@@ -133,7 +133,7 @@ module WWWJDic
133
133
 
134
134
  result = a_hash.to_json
135
135
 
136
- File.open(filename, 'w+') {|f| f << JSON.pretty_generate(a_hash)} unless filename.nil?
136
+ File.open(filename, 'w+') { |f| f << JSON.pretty_generate(a_hash) } unless filename.nil?
137
137
 
138
138
  result
139
139
  end
@@ -180,7 +180,7 @@ module WWWJDic
180
180
  # Restores the original status cleaning up the (possibly) previously
181
181
  # saved URIs restoring the default +to_s+.
182
182
  def reset
183
- @defaults = Hash.new
183
+ @defaults = {}
184
184
  @defaults[:dict] = '1'
185
185
  @defaults[:display] = :regular
186
186
 
@@ -1,6 +1,6 @@
1
1
  #--
2
2
  # wwwjdic
3
- # Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
3
+ # Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
4
4
  #
5
5
  # This file is part of wwwjdic.
6
6
  #
@@ -1,5 +1,6 @@
1
+ #--
1
2
  # wwwjdic
2
- # Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
3
+ # Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
3
4
  #
4
5
  # This file is part of wwwjdic.
5
6
  #
@@ -15,6 +16,7 @@
15
16
  #
16
17
  # You should have received a copy of the GNU General Public License
17
18
  # along with wwwjdic. If not, see <http://www.gnu.org/licenses/>.
19
+ #++
18
20
 
19
21
  de:
20
22
  error:
@@ -1,5 +1,6 @@
1
+ #--
1
2
  # wwwjdic
2
- # Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
3
+ # Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
3
4
  #
4
5
  # This file is part of wwwjdic.
5
6
  #
@@ -15,6 +16,7 @@
15
16
  #
16
17
  # You should have received a copy of the GNU General Public License
17
18
  # along with wwwjdic. If not, see <http://www.gnu.org/licenses/>.
19
+ #++
18
20
 
19
21
  en:
20
22
  error:
@@ -1,5 +1,6 @@
1
+ #--
1
2
  # wwwjdic
2
- # Copyright © 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
3
+ # Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
3
4
  #
4
5
  # This file is part of wwwjdic.
5
6
  #
@@ -15,6 +16,7 @@
15
16
  #
16
17
  # You should have received a copy of the GNU General Public License
17
18
  # along with wwwjdic. If not, see <http://www.gnu.org/licenses/>.
19
+ #++
18
20
 
19
21
  es:
20
22
  error: