iqvoc 3.5.3 → 3.5.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (229) hide show
  1. data/CHANGELOG.md +11 -2
  2. data/Gemfile +4 -6
  3. data/Gemfile.lock +4 -31
  4. data/README.md +1 -1
  5. data/app/assets/javascripts/iqvoc/iqvoc.js +10 -2
  6. data/app/controllers/application_controller.rb +1 -1
  7. data/app/controllers/collections_controller.rb +5 -5
  8. data/app/controllers/concepts/versions_controller.rb +1 -1
  9. data/app/controllers/concepts_controller.rb +7 -8
  10. data/app/controllers/dashboard_controller.rb +1 -1
  11. data/app/controllers/instance_configuration_controller.rb +8 -2
  12. data/app/controllers/rdf_controller.rb +19 -9
  13. data/app/controllers/user_sessions_controller.rb +1 -1
  14. data/app/helpers/application_helper.rb +19 -0
  15. data/app/helpers/dashboard_helper.rb +2 -2
  16. data/app/helpers/rdf_helper.rb +3 -1
  17. data/app/helpers/search_results_helper.rb +1 -1
  18. data/app/models/collection/member/base.rb +1 -1
  19. data/app/models/concept/base.rb +32 -10
  20. data/app/models/concept/skos/scheme.rb +46 -0
  21. data/app/models/labeling/skos/base.rb +3 -3
  22. data/app/models/note/skos/base.rb +1 -1
  23. data/app/models/note/skos/change_note.rb +2 -2
  24. data/app/models/search_extension.rb +1 -1
  25. data/app/models/user.rb +1 -1
  26. data/app/views/concepts/_base_data.html.erb +8 -0
  27. data/app/views/concepts/index.iqrdf +5 -5
  28. data/app/views/layouts/application.html.erb +3 -1
  29. data/app/views/partials/concept/relation/_edit_base.html.erb +2 -2
  30. data/app/views/partials/concept/relation/skos/broader/_mono.html.erb +4 -1
  31. data/app/views/partials/concept/relation/skos/broader/_poly.html.erb +5 -1
  32. data/app/views/rdf/scheme.iqrdf +9 -0
  33. data/config/application.rb +1 -1
  34. data/config/engine.rb +4 -4
  35. data/config/initializers/secret_token_configurator.rb +2 -2
  36. data/config/locales/activerecord.de.yml +13 -0
  37. data/config/locales/activerecord.en.yml +13 -0
  38. data/config/locales/de.yml +3 -0
  39. data/config/locales/en.yml +3 -0
  40. data/config/routes.rb +3 -2
  41. data/db/migrate/20120201120736_add_top_term_to_concepts.rb +7 -0
  42. data/db/schema.rb +2 -1
  43. data/iqvoc.gemspec +1 -1
  44. data/lib/debug.rb +34 -8
  45. data/lib/iqvoc/ability.rb +1 -2
  46. data/lib/iqvoc/configuration/collection.rb +2 -2
  47. data/lib/iqvoc/configuration/concept.rb +10 -5
  48. data/lib/iqvoc/configuration/core.rb +45 -8
  49. data/lib/iqvoc/configuration/label.rb +1 -1
  50. data/lib/iqvoc/controller_extensions.rb +3 -2
  51. data/lib/iqvoc/version.rb +1 -1
  52. data/lib/iqvoc.rb +1 -1
  53. data/lib/tasks/heroku.rake +2 -2
  54. data/test/factories.rb +2 -1
  55. data/test/integration/concept_scheme_test.rb +38 -0
  56. data/test/integration/search_test.rb +4 -4
  57. data/test/integration/tree_test.rb +4 -2
  58. data/test/integration_test_helper.rb +7 -5
  59. data/test/unit/concept_test.rb +1 -1
  60. data/test/unit/instance_configuration_test.rb +7 -7
  61. data/test/unit/skos_import_test.rb +2 -2
  62. metadata +23 -185
  63. data/app/views/layouts/_navigation.html.erb +0 -32
  64. data/config/blazing.rb +0 -36
  65. data/public/assets/ajax-loader-5c1bf2208bffabddfb583013023b2b11.gif +0 -0
  66. data/public/assets/ajax-loader.gif +0 -0
  67. data/public/assets/arrow_down-e1f4aacd91274ce8d4db40d8b4ad781f.gif +0 -0
  68. data/public/assets/arrow_down.gif +0 -0
  69. data/public/assets/arrow_up-a48d7a55002e97f1b70e0e957edf3964.gif +0 -0
  70. data/public/assets/arrow_up.gif +0 -0
  71. data/public/assets/back-ffd41b7924770324ead91a4eb51604f6.png +0 -0
  72. data/public/assets/back.png +0 -0
  73. data/public/assets/blueprint/ie-d2ff4b1cc209dc6b08716b5e0098e106.css +0 -36
  74. data/public/assets/blueprint/ie-d2ff4b1cc209dc6b08716b5e0098e106.css.gz +0 -0
  75. data/public/assets/blueprint/ie.css +0 -36
  76. data/public/assets/blueprint/ie.css.gz +0 -0
  77. data/public/assets/blueprint/print-799a53ff649d9f14baf5f5fe643d04c4.css +0 -30
  78. data/public/assets/blueprint/print-799a53ff649d9f14baf5f5fe643d04c4.css.gz +0 -0
  79. data/public/assets/blueprint/print.css +0 -30
  80. data/public/assets/blueprint/print.css.gz +0 -0
  81. data/public/assets/blueprint/screen-d721f98ceac371a9294fc6f091ca1cb5.css +0 -259
  82. data/public/assets/blueprint/screen-d721f98ceac371a9294fc6f091ca1cb5.css.gz +0 -0
  83. data/public/assets/blueprint/screen.css +0 -259
  84. data/public/assets/blueprint/screen.css.gz +0 -0
  85. data/public/assets/branch-c950c8ac69ee2f753f86a75d944aa976.png +0 -0
  86. data/public/assets/branch.png +0 -0
  87. data/public/assets/categ-e1e1a5958017a5586456895785298c89.png +0 -0
  88. data/public/assets/categ.png +0 -0
  89. data/public/assets/categ_open-de616238db93a0645b4c4a2cdd4eece4.png +0 -0
  90. data/public/assets/categ_open.png +0 -0
  91. data/public/assets/excanvas-1f8c36f3578409126862b5c17e59b9bd.js +0 -14
  92. data/public/assets/excanvas-1f8c36f3578409126862b5c17e59b9bd.js.gz +0 -0
  93. data/public/assets/excanvas.js +0 -14
  94. data/public/assets/excanvas.js.gz +0 -0
  95. data/public/assets/file-48364459f087292aafa11168442bde71.gif +0 -0
  96. data/public/assets/file.gif +0 -0
  97. data/public/assets/folder-7e0f370ab3fcca5deab89784db42da4a.gif +0 -0
  98. data/public/assets/folder-closed-cb6c847cac4dea2cb59c98ecfc76b8ae.gif +0 -0
  99. data/public/assets/folder-closed.gif +0 -0
  100. data/public/assets/folder.gif +0 -0
  101. data/public/assets/footer-ea48e7e96122c8ab345da8ff67f29838.png +0 -0
  102. data/public/assets/footer.png +0 -0
  103. data/public/assets/go_there-ee7df641e73ef83e43180dbc07c40540.png +0 -0
  104. data/public/assets/go_there.png +0 -0
  105. data/public/assets/header_long-5c7970b5911f94433a696ae87918ecb0.png +0 -0
  106. data/public/assets/header_long.png +0 -0
  107. data/public/assets/iqvoc/ie_fixes-7797396e9cd2f32961f56af18bacd33a.css +0 -7
  108. data/public/assets/iqvoc/ie_fixes-7797396e9cd2f32961f56af18bacd33a.css.gz +0 -0
  109. data/public/assets/iqvoc/ie_fixes.css +0 -7
  110. data/public/assets/iqvoc/ie_fixes.css.gz +0 -0
  111. data/public/assets/iqvoc/visualization-49b198ac7d8bc15fa13eafc528e96081.js +0 -4
  112. data/public/assets/iqvoc/visualization-49b198ac7d8bc15fa13eafc528e96081.js.gz +0 -0
  113. data/public/assets/iqvoc/visualization.js +0 -4
  114. data/public/assets/iqvoc/visualization.js.gz +0 -0
  115. data/public/assets/iqvoc-ff2c5252d9877c38297164984d4a7a55.png +0 -0
  116. data/public/assets/iqvoc.png +0 -0
  117. data/public/assets/jit_rgraph-63bc6fa01820d73bb4076f2f62493e66.js +0 -25
  118. data/public/assets/jit_rgraph-63bc6fa01820d73bb4076f2f62493e66.js.gz +0 -0
  119. data/public/assets/jit_rgraph.js +0 -25
  120. data/public/assets/jit_rgraph.js.gz +0 -0
  121. data/public/assets/jquery-ui/ui-bg_flat_0_aaaaaa_40x100-951e2a65945b93d3f69c1994e5672f39.png +0 -0
  122. data/public/assets/jquery-ui/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
  123. data/public/assets/jquery-ui/ui-bg_flat_55_fbec88_40x100-befbc2de63b9556a093c0a5bb2e08a95.png +0 -0
  124. data/public/assets/jquery-ui/ui-bg_flat_55_fbec88_40x100.png +0 -0
  125. data/public/assets/jquery-ui/ui-bg_glass_75_d0e5f5_1x400-faa3341c6543985d2c94bd65e36bd6d8.png +0 -0
  126. data/public/assets/jquery-ui/ui-bg_glass_75_d0e5f5_1x400.png +0 -0
  127. data/public/assets/jquery-ui/ui-bg_glass_85_dfeffc_1x400-df1d30b336ee1530edc334458abd2417.png +0 -0
  128. data/public/assets/jquery-ui/ui-bg_glass_85_dfeffc_1x400.png +0 -0
  129. data/public/assets/jquery-ui/ui-bg_glass_95_fef1ec_1x400-5767880afddd9b98f4b4cfd43a09947b.png +0 -0
  130. data/public/assets/jquery-ui/ui-bg_glass_95_fef1ec_1x400.png +0 -0
  131. data/public/assets/jquery-ui/ui-bg_gloss-wave_55_5c9ccc_500x100-c563cdeeac0f1479b69e36b21d785ac4.png +0 -0
  132. data/public/assets/jquery-ui/ui-bg_gloss-wave_55_5c9ccc_500x100.png +0 -0
  133. data/public/assets/jquery-ui/ui-bg_inset-hard_100_f5f8f9_1x100-b837a3b8315a7ff270664ce469f2e6d7.png +0 -0
  134. data/public/assets/jquery-ui/ui-bg_inset-hard_100_f5f8f9_1x100.png +0 -0
  135. data/public/assets/jquery-ui/ui-bg_inset-hard_100_fcfdfd_1x100-b5d3cda0e6142534937f71cf4438e28a.png +0 -0
  136. data/public/assets/jquery-ui/ui-bg_inset-hard_100_fcfdfd_1x100.png +0 -0
  137. data/public/assets/jquery-ui/ui-icons_217bc0_256x240-14e62c24f88d00f227d88e5b16406eec.png +0 -0
  138. data/public/assets/jquery-ui/ui-icons_217bc0_256x240.png +0 -0
  139. data/public/assets/jquery-ui/ui-icons_2e83ff_256x240-c15e521f58d397c2fa31f4214f92a399.png +0 -0
  140. data/public/assets/jquery-ui/ui-icons_2e83ff_256x240.png +0 -0
  141. data/public/assets/jquery-ui/ui-icons_469bdd_256x240-aceccf3311e1b369e71a4ac629953d61.png +0 -0
  142. data/public/assets/jquery-ui/ui-icons_469bdd_256x240.png +0 -0
  143. data/public/assets/jquery-ui/ui-icons_6da8d5_256x240-18148340aba4ce354c9d52c5aa2f5c0c.png +0 -0
  144. data/public/assets/jquery-ui/ui-icons_6da8d5_256x240.png +0 -0
  145. data/public/assets/jquery-ui/ui-icons_cd0a0a_256x240-279edbd373e73b1ecd1ea7a6ba19750d.png +0 -0
  146. data/public/assets/jquery-ui/ui-icons_cd0a0a_256x240.png +0 -0
  147. data/public/assets/jquery-ui/ui-icons_d8e7f3_256x240-732b446e2e1d4f4fec4277e2632a9adf.png +0 -0
  148. data/public/assets/jquery-ui/ui-icons_d8e7f3_256x240.png +0 -0
  149. data/public/assets/jquery-ui/ui-icons_f9bd01_256x240-1ee933e5956743f5607f2075ed21fac5.png +0 -0
  150. data/public/assets/jquery-ui/ui-icons_f9bd01_256x240.png +0 -0
  151. data/public/assets/json2-fdda51ffce29dd4cb684dc7bd0aede01.js +0 -157
  152. data/public/assets/json2-fdda51ffce29dd4cb684dc7bd0aede01.js.gz +0 -0
  153. data/public/assets/json2.js +0 -157
  154. data/public/assets/json2.js.gz +0 -0
  155. data/public/assets/leaf_end-2ac151e8d7b4928bacb557f96cb5b517.png +0 -0
  156. data/public/assets/leaf_end.png +0 -0
  157. data/public/assets/leaf_end_filled-cdb0eb9ce60425bf0a1fd12226e502eb.png +0 -0
  158. data/public/assets/leaf_end_filled.png +0 -0
  159. data/public/assets/leaf_mid-966f99acaeaddfaedb6b602eb1eed7e0.png +0 -0
  160. data/public/assets/leaf_mid.png +0 -0
  161. data/public/assets/leaf_mid_filled-fecf059c72a649fe77052a886fb030d5.png +0 -0
  162. data/public/assets/leaf_mid_filled.png +0 -0
  163. data/public/assets/leaf_nothing-e8b5532117e55a184d93e8bf66afa20a.png +0 -0
  164. data/public/assets/leaf_nothing.png +0 -0
  165. data/public/assets/leaf_only-e4fe523e451ad9dea6bba08b44cf8039.png +0 -0
  166. data/public/assets/leaf_only.png +0 -0
  167. data/public/assets/leaf_only_filled-7b9a97903759b89facd5fb2e03ba14d1.png +0 -0
  168. data/public/assets/leaf_only_filled.png +0 -0
  169. data/public/assets/leaf_top-61fbce4d3adf2235964e828647a52149.png +0 -0
  170. data/public/assets/leaf_top.png +0 -0
  171. data/public/assets/leaf_top_filled-003d96425167d3b74e63eb75e12d163e.png +0 -0
  172. data/public/assets/leaf_top_filled.png +0 -0
  173. data/public/assets/manifest-c08ebf92c2ea89fbce8705f984a7c604.css +0 -1139
  174. data/public/assets/manifest-c08ebf92c2ea89fbce8705f984a7c604.css.gz +0 -0
  175. data/public/assets/manifest-c6d880245ce63929a5842e48cb7c65f2.js +0 -21
  176. data/public/assets/manifest-c6d880245ce63929a5842e48cb7c65f2.js.gz +0 -0
  177. data/public/assets/manifest.css +0 -1139
  178. data/public/assets/manifest.css.gz +0 -0
  179. data/public/assets/manifest.js +0 -21
  180. data/public/assets/manifest.js.gz +0 -0
  181. data/public/assets/manifest.yml +0 -73
  182. data/public/assets/minus-633f45b71e7552c36214c9d81fce94b0.gif +0 -0
  183. data/public/assets/minus.gif +0 -0
  184. data/public/assets/nothing-19b9650c540a8776b047d6dde27687b0.png +0 -0
  185. data/public/assets/nothing.png +0 -0
  186. data/public/assets/ok-96195c6d50075a63cbdfa11818301f56.png +0 -0
  187. data/public/assets/ok.png +0 -0
  188. data/public/assets/plus-dd3920a86d5ea72497854d875c6afc00.gif +0 -0
  189. data/public/assets/plus.gif +0 -0
  190. data/public/assets/rdf_flyer-b2cc2d8b2a537a9c74b39450f8e6b16f.gif +0 -0
  191. data/public/assets/rdf_flyer.gif +0 -0
  192. data/public/assets/red_arrow-875d1bca1c4b97ec82635af86032a024.png +0 -0
  193. data/public/assets/red_arrow.png +0 -0
  194. data/public/assets/shadow-2975795dc944082531617a0c3ad2da70.png +0 -0
  195. data/public/assets/shadow.png +0 -0
  196. data/public/assets/spinner-0b76e32ff4e68b1e8789b4d0fe991cd7.gif +0 -0
  197. data/public/assets/spinner.gif +0 -0
  198. data/public/assets/tokenizer_delete-94c9b41ce566e499de2090b552e0d167.png +0 -0
  199. data/public/assets/tokenizer_delete.png +0 -0
  200. data/public/assets/tokenizer_pencile-b508830af36466f05620d83c544b22ff.png +0 -0
  201. data/public/assets/tokenizer_pencile.png +0 -0
  202. data/public/assets/tokenizer_show-152443b9a6c0b058cfb51c51f567116f.png +0 -0
  203. data/public/assets/tokenizer_show.png +0 -0
  204. data/public/assets/top_01-fab0825c0529e87fddf883074490dc19.png +0 -0
  205. data/public/assets/top_01.png +0 -0
  206. data/public/assets/treeview-black-116394dbf5afda75949a9925de790795.gif +0 -0
  207. data/public/assets/treeview-black-line-142d898d1f095b3cec1a5dd204daae0d.gif +0 -0
  208. data/public/assets/treeview-black-line.gif +0 -0
  209. data/public/assets/treeview-black.gif +0 -0
  210. data/public/assets/treeview-default-01747815c9007458fc391092548255f8.gif +0 -0
  211. data/public/assets/treeview-default-line-9aecef4278b9e684f18f3c52e3607f80.gif +0 -0
  212. data/public/assets/treeview-default-line.gif +0 -0
  213. data/public/assets/treeview-default.gif +0 -0
  214. data/public/assets/treeview-famfamfam-c5f86a8a52aa48e87b4bd58878c81ad8.gif +0 -0
  215. data/public/assets/treeview-famfamfam-line-897ce097b7d84700985608f22e2403c3.gif +0 -0
  216. data/public/assets/treeview-famfamfam-line.gif +0 -0
  217. data/public/assets/treeview-famfamfam.gif +0 -0
  218. data/public/assets/treeview-gray-56089927c44332a8375be41ab13130c8.gif +0 -0
  219. data/public/assets/treeview-gray-line-d4be395725623b1f39a0964fa479774e.gif +0 -0
  220. data/public/assets/treeview-gray-line.gif +0 -0
  221. data/public/assets/treeview-gray.gif +0 -0
  222. data/public/assets/treeview-red-cb4ed4e5654d76aef755e5c55b63e91c.gif +0 -0
  223. data/public/assets/treeview-red-line-fdf843bbfba11d00897c7971dff7e806.gif +0 -0
  224. data/public/assets/treeview-red-line.gif +0 -0
  225. data/public/assets/treeview-red.gif +0 -0
  226. data/public/assets/trunk-5686782333e8b4c7e4468c452fb52cec.png +0 -0
  227. data/public/assets/trunk.png +0 -0
  228. data/public/assets/unfinished-1cb6bae22a5b855f4b51cb03a1cce928.png +0 -0
  229. data/public/assets/unfinished.png +0 -0
@@ -1,157 +0,0 @@
1
- /*
2
- http://www.JSON.org/json2.js
3
- 2011-10-19
4
-
5
- Public Domain.
6
-
7
- NO WARRANTY EXPRESSED OR IMPLIED. USE AT YOUR OWN RISK.
8
-
9
- See http://www.JSON.org/js.html
10
-
11
-
12
- This code should be minified before deployment.
13
- See http://javascript.crockford.com/jsmin.html
14
-
15
- USE YOUR OWN COPY. IT IS EXTREMELY UNWISE TO LOAD CODE FROM SERVERS YOU DO
16
- NOT CONTROL.
17
-
18
-
19
- This file creates a global JSON object containing two methods: stringify
20
- and parse.
21
-
22
- JSON.stringify(value, replacer, space)
23
- value any JavaScript value, usually an object or array.
24
-
25
- replacer an optional parameter that determines how object
26
- values are stringified for objects. It can be a
27
- function or an array of strings.
28
-
29
- space an optional parameter that specifies the indentation
30
- of nested structures. If it is omitted, the text will
31
- be packed without extra whitespace. If it is a number,
32
- it will specify the number of spaces to indent at each
33
- level. If it is a string (such as '\t' or ' '),
34
- it contains the characters used to indent at each level.
35
-
36
- This method produces a JSON text from a JavaScript value.
37
-
38
- When an object value is found, if the object contains a toJSON
39
- method, its toJSON method will be called and the result will be
40
- stringified. A toJSON method does not serialize: it returns the
41
- value represented by the name/value pair that should be serialized,
42
- or undefined if nothing should be serialized. The toJSON method
43
- will be passed the key associated with the value, and this will be
44
- bound to the value
45
-
46
- For example, this would serialize Dates as ISO strings.
47
-
48
- Date.prototype.toJSON = function (key) {
49
- function f(n) {
50
- // Format integers to have at least two digits.
51
- return n < 10 ? '0' + n : n;
52
- }
53
-
54
- return this.getUTCFullYear() + '-' +
55
- f(this.getUTCMonth() + 1) + '-' +
56
- f(this.getUTCDate()) + 'T' +
57
- f(this.getUTCHours()) + ':' +
58
- f(this.getUTCMinutes()) + ':' +
59
- f(this.getUTCSeconds()) + 'Z';
60
- };
61
-
62
- You can provide an optional replacer method. It will be passed the
63
- key and value of each member, with this bound to the containing
64
- object. The value that is returned from your method will be
65
- serialized. If your method returns undefined, then the member will
66
- be excluded from the serialization.
67
-
68
- If the replacer parameter is an array of strings, then it will be
69
- used to select the members to be serialized. It filters the results
70
- such that only members with keys listed in the replacer array are
71
- stringified.
72
-
73
- Values that do not have JSON representations, such as undefined or
74
- functions, will not be serialized. Such values in objects will be
75
- dropped; in arrays they will be replaced with null. You can use
76
- a replacer function to replace those with JSON values.
77
- JSON.stringify(undefined) returns undefined.
78
-
79
- The optional space parameter produces a stringification of the
80
- value that is filled with line breaks and indentation to make it
81
- easier to read.
82
-
83
- If the space parameter is a non-empty string, then that string will
84
- be used for indentation. If the space parameter is a number, then
85
- the indentation will be that many spaces.
86
-
87
- Example:
88
-
89
- text = JSON.stringify(['e', {pluribus: 'unum'}]);
90
- // text is '["e",{"pluribus":"unum"}]'
91
-
92
-
93
- text = JSON.stringify(['e', {pluribus: 'unum'}], null, '\t');
94
- // text is '[\n\t"e",\n\t{\n\t\t"pluribus": "unum"\n\t}\n]'
95
-
96
- text = JSON.stringify([new Date()], function (key, value) {
97
- return this[key] instanceof Date ?
98
- 'Date(' + this[key] + ')' : value;
99
- });
100
- // text is '["Date(---current time---)"]'
101
-
102
-
103
- JSON.parse(text, reviver)
104
- This method parses a JSON text to produce an object or array.
105
- It can throw a SyntaxError exception.
106
-
107
- The optional reviver parameter is a function that can filter and
108
- transform the results. It receives each of the keys and values,
109
- and its return value is used instead of the original value.
110
- If it returns what it received, then the structure is not modified.
111
- If it returns undefined then the member is deleted.
112
-
113
- Example:
114
-
115
- // Parse the text. Values that look like ISO date strings will
116
- // be converted to Date objects.
117
-
118
- myData = JSON.parse(text, function (key, value) {
119
- var a;
120
- if (typeof value === 'string') {
121
- a =
122
- /^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2}(?:\.\d*)?)Z$/.exec(value);
123
- if (a) {
124
- return new Date(Date.UTC(+a[1], +a[2] - 1, +a[3], +a[4],
125
- +a[5], +a[6]));
126
- }
127
- }
128
- return value;
129
- });
130
-
131
- myData = JSON.parse('["Date(09/09/2001)"]', function (key, value) {
132
- var d;
133
- if (typeof value === 'string' &&
134
- value.slice(0, 5) === 'Date(' &&
135
- value.slice(-1) === ')') {
136
- d = new Date(value.slice(5, -1));
137
- if (d) {
138
- return d;
139
- }
140
- }
141
- return value;
142
- });
143
-
144
-
145
- This is a reference implementation. You are free to copy, modify, or
146
- redistribute.
147
- */
148
- /*jslint evil: true, regexp: true */
149
- /*members "", "\b", "\t", "\n", "\f", "\r", "\"", JSON, "\\", apply,
150
- call, charCodeAt, getUTCDate, getUTCFullYear, getUTCHours,
151
- getUTCMinutes, getUTCMonth, getUTCSeconds, hasOwnProperty, join,
152
- lastIndex, length, parse, prototype, push, replace, slice, stringify,
153
- test, toJSON, toString, valueOf
154
- */
155
- // Create a JSON object only if one does not already exist. We create the
156
- // methods in a closure to avoid creating global variables.
157
- var JSON;JSON||(JSON={}),function(){function f(a){return a<10?"0"+a:a}function quote(a){return escapable.lastIndex=0,escapable.test(a)?'"'+a.replace(escapable,function(a){var b=meta[a];return typeof b=="string"?b:"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+a+'"'}function str(a,b){var c,d,e,f,g=gap,h,i=b[a];i&&typeof i=="object"&&typeof i.toJSON=="function"&&(i=i.toJSON(a)),typeof rep=="function"&&(i=rep.call(b,a,i));switch(typeof i){case"string":return quote(i);case"number":return isFinite(i)?String(i):"null";case"boolean":case"null":return String(i);case"object":if(!i)return"null";gap+=indent,h=[];if(Object.prototype.toString.apply(i)==="[object Array]"){f=i.length;for(c=0;c<f;c+=1)h[c]=str(c,i)||"null";return e=h.length===0?"[]":gap?"[\n"+gap+h.join(",\n"+gap)+"\n"+g+"]":"["+h.join(",")+"]",gap=g,e}if(rep&&typeof rep=="object"){f=rep.length;for(c=0;c<f;c+=1)typeof rep[c]=="string"&&(d=rep[c],e=str(d,i),e&&h.push(quote(d)+(gap?": ":":")+e))}else for(d in i)Object.prototype.hasOwnProperty.call(i,d)&&(e=str(d,i),e&&h.push(quote(d)+(gap?": ":":")+e));return e=h.length===0?"{}":gap?"{\n"+gap+h.join(",\n"+gap)+"\n"+g+"}":"{"+h.join(",")+"}",gap=g,e}}"use strict",typeof Date.prototype.toJSON!="function"&&(Date.prototype.toJSON=function(a){return isFinite(this.valueOf())?this.getUTCFullYear()+"-"+f(this.getUTCMonth()+1)+"-"+f(this.getUTCDate())+"T"+f(this.getUTCHours())+":"+f(this.getUTCMinutes())+":"+f(this.getUTCSeconds())+"Z":null},String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(a){return this.valueOf()});var cx=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,escapable=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,gap,indent,meta={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},rep;typeof JSON.stringify!="function"&&(JSON.stringify=function(a,b,c){var d;gap="",indent="";if(typeof c=="number")for(d=0;d<c;d+=1)indent+=" ";else typeof c=="string"&&(indent=c);rep=b;if(!b||typeof b=="function"||typeof b=="object"&&typeof b.length=="number")return str("",{"":a});throw new Error("JSON.stringify")}),typeof JSON.parse!="function"&&(JSON.parse=function(text,reviver){function walk(a,b){var c,d,e=a[b];if(e&&typeof e=="object")for(c in e)Object.prototype.hasOwnProperty.call(e,c)&&(d=walk(e,c),d!==undefined?e[c]=d:delete e[c]);return reviver.call(a,b,e)}var j;text=String(text),cx.lastIndex=0,cx.test(text)&&(text=text.replace(cx,function(a){return"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)}));if(/^[\],:{}\s]*$/.test(text.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return j=eval("("+text+")"),typeof reviver=="function"?walk({"":j},""):j;throw new SyntaxError("JSON.parse")})}()
@@ -1,157 +0,0 @@
1
- /*
2
- http://www.JSON.org/json2.js
3
- 2011-10-19
4
-
5
- Public Domain.
6
-
7
- NO WARRANTY EXPRESSED OR IMPLIED. USE AT YOUR OWN RISK.
8
-
9
- See http://www.JSON.org/js.html
10
-
11
-
12
- This code should be minified before deployment.
13
- See http://javascript.crockford.com/jsmin.html
14
-
15
- USE YOUR OWN COPY. IT IS EXTREMELY UNWISE TO LOAD CODE FROM SERVERS YOU DO
16
- NOT CONTROL.
17
-
18
-
19
- This file creates a global JSON object containing two methods: stringify
20
- and parse.
21
-
22
- JSON.stringify(value, replacer, space)
23
- value any JavaScript value, usually an object or array.
24
-
25
- replacer an optional parameter that determines how object
26
- values are stringified for objects. It can be a
27
- function or an array of strings.
28
-
29
- space an optional parameter that specifies the indentation
30
- of nested structures. If it is omitted, the text will
31
- be packed without extra whitespace. If it is a number,
32
- it will specify the number of spaces to indent at each
33
- level. If it is a string (such as '\t' or '&nbsp;'),
34
- it contains the characters used to indent at each level.
35
-
36
- This method produces a JSON text from a JavaScript value.
37
-
38
- When an object value is found, if the object contains a toJSON
39
- method, its toJSON method will be called and the result will be
40
- stringified. A toJSON method does not serialize: it returns the
41
- value represented by the name/value pair that should be serialized,
42
- or undefined if nothing should be serialized. The toJSON method
43
- will be passed the key associated with the value, and this will be
44
- bound to the value
45
-
46
- For example, this would serialize Dates as ISO strings.
47
-
48
- Date.prototype.toJSON = function (key) {
49
- function f(n) {
50
- // Format integers to have at least two digits.
51
- return n < 10 ? '0' + n : n;
52
- }
53
-
54
- return this.getUTCFullYear() + '-' +
55
- f(this.getUTCMonth() + 1) + '-' +
56
- f(this.getUTCDate()) + 'T' +
57
- f(this.getUTCHours()) + ':' +
58
- f(this.getUTCMinutes()) + ':' +
59
- f(this.getUTCSeconds()) + 'Z';
60
- };
61
-
62
- You can provide an optional replacer method. It will be passed the
63
- key and value of each member, with this bound to the containing
64
- object. The value that is returned from your method will be
65
- serialized. If your method returns undefined, then the member will
66
- be excluded from the serialization.
67
-
68
- If the replacer parameter is an array of strings, then it will be
69
- used to select the members to be serialized. It filters the results
70
- such that only members with keys listed in the replacer array are
71
- stringified.
72
-
73
- Values that do not have JSON representations, such as undefined or
74
- functions, will not be serialized. Such values in objects will be
75
- dropped; in arrays they will be replaced with null. You can use
76
- a replacer function to replace those with JSON values.
77
- JSON.stringify(undefined) returns undefined.
78
-
79
- The optional space parameter produces a stringification of the
80
- value that is filled with line breaks and indentation to make it
81
- easier to read.
82
-
83
- If the space parameter is a non-empty string, then that string will
84
- be used for indentation. If the space parameter is a number, then
85
- the indentation will be that many spaces.
86
-
87
- Example:
88
-
89
- text = JSON.stringify(['e', {pluribus: 'unum'}]);
90
- // text is '["e",{"pluribus":"unum"}]'
91
-
92
-
93
- text = JSON.stringify(['e', {pluribus: 'unum'}], null, '\t');
94
- // text is '[\n\t"e",\n\t{\n\t\t"pluribus": "unum"\n\t}\n]'
95
-
96
- text = JSON.stringify([new Date()], function (key, value) {
97
- return this[key] instanceof Date ?
98
- 'Date(' + this[key] + ')' : value;
99
- });
100
- // text is '["Date(---current time---)"]'
101
-
102
-
103
- JSON.parse(text, reviver)
104
- This method parses a JSON text to produce an object or array.
105
- It can throw a SyntaxError exception.
106
-
107
- The optional reviver parameter is a function that can filter and
108
- transform the results. It receives each of the keys and values,
109
- and its return value is used instead of the original value.
110
- If it returns what it received, then the structure is not modified.
111
- If it returns undefined then the member is deleted.
112
-
113
- Example:
114
-
115
- // Parse the text. Values that look like ISO date strings will
116
- // be converted to Date objects.
117
-
118
- myData = JSON.parse(text, function (key, value) {
119
- var a;
120
- if (typeof value === 'string') {
121
- a =
122
- /^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2}(?:\.\d*)?)Z$/.exec(value);
123
- if (a) {
124
- return new Date(Date.UTC(+a[1], +a[2] - 1, +a[3], +a[4],
125
- +a[5], +a[6]));
126
- }
127
- }
128
- return value;
129
- });
130
-
131
- myData = JSON.parse('["Date(09/09/2001)"]', function (key, value) {
132
- var d;
133
- if (typeof value === 'string' &&
134
- value.slice(0, 5) === 'Date(' &&
135
- value.slice(-1) === ')') {
136
- d = new Date(value.slice(5, -1));
137
- if (d) {
138
- return d;
139
- }
140
- }
141
- return value;
142
- });
143
-
144
-
145
- This is a reference implementation. You are free to copy, modify, or
146
- redistribute.
147
- */
148
- /*jslint evil: true, regexp: true */
149
- /*members "", "\b", "\t", "\n", "\f", "\r", "\"", JSON, "\\", apply,
150
- call, charCodeAt, getUTCDate, getUTCFullYear, getUTCHours,
151
- getUTCMinutes, getUTCMonth, getUTCSeconds, hasOwnProperty, join,
152
- lastIndex, length, parse, prototype, push, replace, slice, stringify,
153
- test, toJSON, toString, valueOf
154
- */
155
- // Create a JSON object only if one does not already exist. We create the
156
- // methods in a closure to avoid creating global variables.
157
- var JSON;JSON||(JSON={}),function(){function f(a){return a<10?"0"+a:a}function quote(a){return escapable.lastIndex=0,escapable.test(a)?'"'+a.replace(escapable,function(a){var b=meta[a];return typeof b=="string"?b:"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+a+'"'}function str(a,b){var c,d,e,f,g=gap,h,i=b[a];i&&typeof i=="object"&&typeof i.toJSON=="function"&&(i=i.toJSON(a)),typeof rep=="function"&&(i=rep.call(b,a,i));switch(typeof i){case"string":return quote(i);case"number":return isFinite(i)?String(i):"null";case"boolean":case"null":return String(i);case"object":if(!i)return"null";gap+=indent,h=[];if(Object.prototype.toString.apply(i)==="[object Array]"){f=i.length;for(c=0;c<f;c+=1)h[c]=str(c,i)||"null";return e=h.length===0?"[]":gap?"[\n"+gap+h.join(",\n"+gap)+"\n"+g+"]":"["+h.join(",")+"]",gap=g,e}if(rep&&typeof rep=="object"){f=rep.length;for(c=0;c<f;c+=1)typeof rep[c]=="string"&&(d=rep[c],e=str(d,i),e&&h.push(quote(d)+(gap?": ":":")+e))}else for(d in i)Object.prototype.hasOwnProperty.call(i,d)&&(e=str(d,i),e&&h.push(quote(d)+(gap?": ":":")+e));return e=h.length===0?"{}":gap?"{\n"+gap+h.join(",\n"+gap)+"\n"+g+"}":"{"+h.join(",")+"}",gap=g,e}}"use strict",typeof Date.prototype.toJSON!="function"&&(Date.prototype.toJSON=function(a){return isFinite(this.valueOf())?this.getUTCFullYear()+"-"+f(this.getUTCMonth()+1)+"-"+f(this.getUTCDate())+"T"+f(this.getUTCHours())+":"+f(this.getUTCMinutes())+":"+f(this.getUTCSeconds())+"Z":null},String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(a){return this.valueOf()});var cx=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,escapable=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,gap,indent,meta={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},rep;typeof JSON.stringify!="function"&&(JSON.stringify=function(a,b,c){var d;gap="",indent="";if(typeof c=="number")for(d=0;d<c;d+=1)indent+=" ";else typeof c=="string"&&(indent=c);rep=b;if(!b||typeof b=="function"||typeof b=="object"&&typeof b.length=="number")return str("",{"":a});throw new Error("JSON.stringify")}),typeof JSON.parse!="function"&&(JSON.parse=function(text,reviver){function walk(a,b){var c,d,e=a[b];if(e&&typeof e=="object")for(c in e)Object.prototype.hasOwnProperty.call(e,c)&&(d=walk(e,c),d!==undefined?e[c]=d:delete e[c]);return reviver.call(a,b,e)}var j;text=String(text),cx.lastIndex=0,cx.test(text)&&(text=text.replace(cx,function(a){return"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)}));if(/^[\],:{}\s]*$/.test(text.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return j=eval("("+text+")"),typeof reviver=="function"?walk({"":j},""):j;throw new SyntaxError("JSON.parse")})}()
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file