coffeecake 0.0.1

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 (1336) hide show
  1. data/.gitignore +17 -0
  2. data/Gemfile +4 -0
  3. data/README.markdown +28 -0
  4. data/Rakefile +2 -0
  5. data/bin/ck +16 -0
  6. data/coffeecake.gemspec +21 -0
  7. data/lib/coffeecake.rb +4 -0
  8. data/lib/coffeecake/generators.rb +12 -0
  9. data/lib/coffeecake/generators/new_generator.rb +55 -0
  10. data/lib/coffeecake/templates/.gitkeep +0 -0
  11. data/lib/coffeecake/templates/README.markdown +56 -0
  12. data/lib/coffeecake/templates/SpecHelper.tt +0 -0
  13. data/lib/coffeecake/templates/docs_readme +5 -0
  14. data/lib/coffeecake/templates/jasmine.tt +18 -0
  15. data/lib/coffeecake/templates/lib.tt +3 -0
  16. data/lib/coffeecake/templates/spec.tt +3 -0
  17. data/lib/coffeecake/version.rb +3 -0
  18. data/lib/thor_register_patch.rb +16 -0
  19. data/node_modules/.bin/cake +7 -0
  20. data/node_modules/.bin/coffee +7 -0
  21. data/node_modules/.bin/docco +8 -0
  22. data/node_modules/.bin/jasmine +26 -0
  23. data/node_modules/.bin/jasmine-node +7 -0
  24. data/node_modules/.bin/uglifycss +127 -0
  25. data/node_modules/.bin/uglifyjs +317 -0
  26. data/node_modules/coffee-script/.npmignore +11 -0
  27. data/node_modules/coffee-script/LICENSE +22 -0
  28. data/node_modules/coffee-script/README +51 -0
  29. data/node_modules/coffee-script/Rakefile +78 -0
  30. data/node_modules/coffee-script/bin/cake +7 -0
  31. data/node_modules/coffee-script/bin/coffee +7 -0
  32. data/node_modules/coffee-script/extras/jsl.conf +44 -0
  33. data/node_modules/coffee-script/lib/coffee-script/browser.js +74 -0
  34. data/node_modules/coffee-script/lib/coffee-script/cake.js +89 -0
  35. data/node_modules/coffee-script/lib/coffee-script/coffee-script.js +148 -0
  36. data/node_modules/coffee-script/lib/coffee-script/command.js +310 -0
  37. data/node_modules/coffee-script/lib/coffee-script/grammar.js +588 -0
  38. data/node_modules/coffee-script/lib/coffee-script/helpers.js +72 -0
  39. data/node_modules/coffee-script/lib/coffee-script/index.js +10 -0
  40. data/node_modules/coffee-script/lib/coffee-script/lexer.js +687 -0
  41. data/node_modules/coffee-script/lib/coffee-script/nodes.js +2481 -0
  42. data/node_modules/coffee-script/lib/coffee-script/optparse.js +122 -0
  43. data/node_modules/coffee-script/lib/coffee-script/parser.js +670 -0
  44. data/node_modules/coffee-script/lib/coffee-script/repl.js +149 -0
  45. data/node_modules/coffee-script/lib/coffee-script/rewriter.js +288 -0
  46. data/node_modules/coffee-script/lib/coffee-script/scope.js +124 -0
  47. data/node_modules/coffee-script/npm-install-45965.sh +282 -0
  48. data/node_modules/coffee-script/package.json +31 -0
  49. data/node_modules/docco/.gitignore +3 -0
  50. data/node_modules/docco/Cakefile +27 -0
  51. data/node_modules/docco/README +13 -0
  52. data/node_modules/docco/bin/docco +8 -0
  53. data/node_modules/docco/index.html +143 -0
  54. data/node_modules/docco/lib/docco.js +155 -0
  55. data/node_modules/docco/package.json +21 -0
  56. data/node_modules/docco/resources/docco.css +186 -0
  57. data/node_modules/docco/resources/docco.jst +58 -0
  58. data/node_modules/docco/src/docco.coffee +204 -0
  59. data/node_modules/docco/vendor/showdown.js +1298 -0
  60. data/node_modules/jasmine-jquery/.gitignore +3 -0
  61. data/node_modules/jasmine-jquery/MIT.LICENSE +20 -0
  62. data/node_modules/jasmine-jquery/README.markdown +174 -0
  63. data/node_modules/jasmine-jquery/SpecRunner.html +24 -0
  64. data/node_modules/jasmine-jquery/index.js +15 -0
  65. data/node_modules/jasmine-jquery/lib/jasmine-jquery.js +288 -0
  66. data/node_modules/jasmine-jquery/package.json +19 -0
  67. data/node_modules/jasmine-jquery/spec/fixtures/real_non_mocked_fixture.html +1 -0
  68. data/node_modules/jasmine-jquery/spec/suites/jasmine-jquery-spec.js +691 -0
  69. data/node_modules/jasmine-node/.gitignore +10 -0
  70. data/node_modules/jasmine-node/LICENSE +22 -0
  71. data/node_modules/jasmine-node/README.md +35 -0
  72. data/node_modules/jasmine-node/bin/jasmine-node +7 -0
  73. data/node_modules/jasmine-node/lib/jasmine-node/cli.js +110 -0
  74. data/node_modules/jasmine-node/lib/jasmine-node/index.js +171 -0
  75. data/node_modules/jasmine-node/lib/jasmine-node/jasmine-2.0.0.rc1.js +2479 -0
  76. data/node_modules/jasmine-node/lib/jasmine-node/reporter.js +177 -0
  77. data/node_modules/jasmine-node/package.json +22 -0
  78. data/node_modules/jasmine-node/spec/CoffeeSpec.coffee +4 -0
  79. data/node_modules/jasmine-node/spec/SampleSpecs.js +15 -0
  80. data/node_modules/jasmine-node/spec/TestSpec.js +5 -0
  81. data/node_modules/jasmine-node/spec/helper_spec.js +7 -0
  82. data/node_modules/jasmine-node/spec/include/include_spec.js +7 -0
  83. data/node_modules/jasmine-node/spec/include/lib/test.js +3 -0
  84. data/node_modules/jasmine-node/spec/nested.js/NestedSpec.js +5 -0
  85. data/node_modules/jasmine-node/spec/nested/NestedSpec.js +5 -0
  86. data/node_modules/jasmine-node/spec/nested/uber-nested/UberNestedSpec.js +11 -0
  87. data/node_modules/jasmine-node/spec/sample_helper.js +19 -0
  88. data/node_modules/jasmine-node/specs.sh +2 -0
  89. data/node_modules/jasmine-reporters/.gitignore +1 -0
  90. data/node_modules/jasmine-reporters/.gitmodules +3 -0
  91. data/node_modules/jasmine-reporters/LICENSE +21 -0
  92. data/node_modules/jasmine-reporters/README.markdown +52 -0
  93. data/node_modules/jasmine-reporters/ext/env.rhino.1.2.js +13989 -0
  94. data/node_modules/jasmine-reporters/ext/jasmine-html.js +182 -0
  95. data/node_modules/jasmine-reporters/ext/jasmine.css +166 -0
  96. data/node_modules/jasmine-reporters/ext/jasmine.js +2421 -0
  97. data/node_modules/jasmine-reporters/ext/jline.jar +0 -0
  98. data/node_modules/jasmine-reporters/ext/js.jar +0 -0
  99. data/node_modules/jasmine-reporters/ext/phantomjs/.gitignore +10 -0
  100. data/node_modules/jasmine-reporters/ext/phantomjs/ChangeLog +57 -0
  101. data/node_modules/jasmine-reporters/ext/phantomjs/LICENSE.BSD +22 -0
  102. data/node_modules/jasmine-reporters/ext/phantomjs/README.md +28 -0
  103. data/node_modules/jasmine-reporters/ext/phantomjs/examples/arguments.coffee +6 -0
  104. data/node_modules/jasmine-reporters/ext/phantomjs/examples/arguments.js +8 -0
  105. data/node_modules/jasmine-reporters/ext/phantomjs/examples/colorwheel.coffee +45 -0
  106. data/node_modules/jasmine-reporters/ext/phantomjs/examples/colorwheel.js +52 -0
  107. data/node_modules/jasmine-reporters/ext/phantomjs/examples/countdown.coffee +8 -0
  108. data/node_modules/jasmine-reporters/ext/phantomjs/examples/countdown.js +8 -0
  109. data/node_modules/jasmine-reporters/ext/phantomjs/examples/cycle_multiple_urls.js +64 -0
  110. data/node_modules/jasmine-reporters/ext/phantomjs/examples/direction.coffee +28 -0
  111. data/node_modules/jasmine-reporters/ext/phantomjs/examples/direction.js +34 -0
  112. data/node_modules/jasmine-reporters/ext/phantomjs/examples/extract-text.coffee +81 -0
  113. data/node_modules/jasmine-reporters/ext/phantomjs/examples/extract-text.js +121 -0
  114. data/node_modules/jasmine-reporters/ext/phantomjs/examples/fibo.coffee +8 -0
  115. data/node_modules/jasmine-reporters/ext/phantomjs/examples/fibo.js +9 -0
  116. data/node_modules/jasmine-reporters/ext/phantomjs/examples/follow.coffee +36 -0
  117. data/node_modules/jasmine-reporters/ext/phantomjs/examples/follow.js +37 -0
  118. data/node_modules/jasmine-reporters/ext/phantomjs/examples/hello.coffee +2 -0
  119. data/node_modules/jasmine-reporters/ext/phantomjs/examples/hello.js +2 -0
  120. data/node_modules/jasmine-reporters/ext/phantomjs/examples/ipgeocode.coffee +13 -0
  121. data/node_modules/jasmine-reporters/ext/phantomjs/examples/ipgeocode.js +14 -0
  122. data/node_modules/jasmine-reporters/ext/phantomjs/examples/loadspeed.coffee +17 -0
  123. data/node_modules/jasmine-reporters/ext/phantomjs/examples/loadspeed.js +20 -0
  124. data/node_modules/jasmine-reporters/ext/phantomjs/examples/movies.coffee +13 -0
  125. data/node_modules/jasmine-reporters/ext/phantomjs/examples/movies.js +14 -0
  126. data/node_modules/jasmine-reporters/ext/phantomjs/examples/pizza.coffee +10 -0
  127. data/node_modules/jasmine-reporters/ext/phantomjs/examples/pizza.js +12 -0
  128. data/node_modules/jasmine-reporters/ext/phantomjs/examples/rasterize.coffee +21 -0
  129. data/node_modules/jasmine-reporters/ext/phantomjs/examples/rasterize.js +22 -0
  130. data/node_modules/jasmine-reporters/ext/phantomjs/examples/run-jasmine.js +26 -0
  131. data/node_modules/jasmine-reporters/ext/phantomjs/examples/run-qunit.js +24 -0
  132. data/node_modules/jasmine-reporters/ext/phantomjs/examples/seasonfood.coffee +17 -0
  133. data/node_modules/jasmine-reporters/ext/phantomjs/examples/seasonfood.js +19 -0
  134. data/node_modules/jasmine-reporters/ext/phantomjs/examples/technews.coffee +13 -0
  135. data/node_modules/jasmine-reporters/ext/phantomjs/examples/technews.js +14 -0
  136. data/node_modules/jasmine-reporters/ext/phantomjs/examples/tweets.coffee +8 -0
  137. data/node_modules/jasmine-reporters/ext/phantomjs/examples/tweets.js +12 -0
  138. data/node_modules/jasmine-reporters/ext/phantomjs/examples/useragent.coffee +7 -0
  139. data/node_modules/jasmine-reporters/ext/phantomjs/examples/useragent.js +8 -0
  140. data/node_modules/jasmine-reporters/ext/phantomjs/examples/version.coffee +5 -0
  141. data/node_modules/jasmine-reporters/ext/phantomjs/examples/version.js +5 -0
  142. data/node_modules/jasmine-reporters/ext/phantomjs/examples/waitfor.coffee +40 -0
  143. data/node_modules/jasmine-reporters/ext/phantomjs/examples/waitfor.js +43 -0
  144. data/node_modules/jasmine-reporters/ext/phantomjs/examples/weather.coffee +35 -0
  145. data/node_modules/jasmine-reporters/ext/phantomjs/examples/weather.js +42 -0
  146. data/node_modules/jasmine-reporters/ext/phantomjs/phantomjs.pro +3 -0
  147. data/node_modules/jasmine-reporters/ext/phantomjs/python/INSTALL +20 -0
  148. data/node_modules/jasmine-reporters/ext/phantomjs/python/LICENSE +674 -0
  149. data/node_modules/jasmine-reporters/ext/phantomjs/python/README +56 -0
  150. data/node_modules/jasmine-reporters/ext/phantomjs/python/csconverter.py +41 -0
  151. data/node_modules/jasmine-reporters/ext/phantomjs/python/networkaccessmanager.py +84 -0
  152. data/node_modules/jasmine-reporters/ext/phantomjs/python/phantom.py +384 -0
  153. data/node_modules/jasmine-reporters/ext/phantomjs/python/plugincontroller.py +98 -0
  154. data/node_modules/jasmine-reporters/ext/phantomjs/python/plugins/__init__.py +1 -0
  155. data/node_modules/jasmine-reporters/ext/phantomjs/python/pyphantomjs.py +154 -0
  156. data/node_modules/jasmine-reporters/ext/phantomjs/python/resources.py +4160 -0
  157. data/node_modules/jasmine-reporters/ext/phantomjs/python/resources.qrc +6 -0
  158. data/node_modules/jasmine-reporters/ext/phantomjs/python/resources/coffee-script.js +8 -0
  159. data/node_modules/jasmine-reporters/ext/phantomjs/python/resources/pyphantomjs-icon.ico +0 -0
  160. data/node_modules/jasmine-reporters/ext/phantomjs/python/resources/pyphantomjs-icon.png +0 -0
  161. data/node_modules/jasmine-reporters/ext/phantomjs/python/tools/build_resources.sh +14 -0
  162. data/node_modules/jasmine-reporters/ext/phantomjs/python/tools/setup.py +52 -0
  163. data/node_modules/jasmine-reporters/ext/phantomjs/python/utils.py +126 -0
  164. data/node_modules/jasmine-reporters/ext/phantomjs/python/webpage.py +67 -0
  165. data/node_modules/jasmine-reporters/ext/phantomjs/src/coffee-script.js +8 -0
  166. data/node_modules/jasmine-reporters/ext/phantomjs/src/consts.h +39 -0
  167. data/node_modules/jasmine-reporters/ext/phantomjs/src/csconverter.cpp +61 -0
  168. data/node_modules/jasmine-reporters/ext/phantomjs/src/csconverter.h +47 -0
  169. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/config.h +1 -0
  170. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/egif_lib.c +1111 -0
  171. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/gif.pri +20 -0
  172. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/gif_err.c +120 -0
  173. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/gif_hash.c +160 -0
  174. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/gif_hash.h +59 -0
  175. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/gif_lib.h +336 -0
  176. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/gif_lib_private.h +59 -0
  177. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/gifalloc.c +443 -0
  178. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/gifwriter.cpp +126 -0
  179. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/gifwriter.h +38 -0
  180. data/node_modules/jasmine-reporters/ext/phantomjs/src/gif/quantize.c +330 -0
  181. data/node_modules/jasmine-reporters/ext/phantomjs/src/main.cpp +64 -0
  182. data/node_modules/jasmine-reporters/ext/phantomjs/src/networkaccessmanager.cpp +119 -0
  183. data/node_modules/jasmine-reporters/ext/phantomjs/src/networkaccessmanager.h +53 -0
  184. data/node_modules/jasmine-reporters/ext/phantomjs/src/phantom.cpp +494 -0
  185. data/node_modules/jasmine-reporters/ext/phantomjs/src/phantom.h +117 -0
  186. data/node_modules/jasmine-reporters/ext/phantomjs/src/phantomjs-icon.png +0 -0
  187. data/node_modules/jasmine-reporters/ext/phantomjs/src/phantomjs.pro +32 -0
  188. data/node_modules/jasmine-reporters/ext/phantomjs/src/phantomjs.qrc +7 -0
  189. data/node_modules/jasmine-reporters/ext/phantomjs/src/phantomjs_os2.ico +0 -0
  190. data/node_modules/jasmine-reporters/ext/phantomjs/src/phantomjs_os2.rc +1 -0
  191. data/node_modules/jasmine-reporters/ext/phantomjs/src/phantomjs_win.ico +0 -0
  192. data/node_modules/jasmine-reporters/ext/phantomjs/src/phantomjs_win.rc +1 -0
  193. data/node_modules/jasmine-reporters/ext/phantomjs/src/usage.txt +11 -0
  194. data/node_modules/jasmine-reporters/ext/phantomjs/src/utils.cpp +74 -0
  195. data/node_modules/jasmine-reporters/ext/phantomjs/src/utils.h +50 -0
  196. data/node_modules/jasmine-reporters/ext/phantomjs/src/webpage.cpp +87 -0
  197. data/node_modules/jasmine-reporters/ext/phantomjs/src/webpage.h +61 -0
  198. data/node_modules/jasmine-reporters/package.json +15 -0
  199. data/node_modules/jasmine-reporters/src/jasmine.console_reporter.js +132 -0
  200. data/node_modules/jasmine-reporters/src/jasmine.junit_reporter.js +199 -0
  201. data/node_modules/jasmine-reporters/src/load_reporters.js +2 -0
  202. data/node_modules/jasmine-reporters/test/JUnitXmlReporterSpec.js +214 -0
  203. data/node_modules/jasmine-reporters/test/console_reporter.html +36 -0
  204. data/node_modules/jasmine-reporters/test/envjs.bootstrap.js +14 -0
  205. data/node_modules/jasmine-reporters/test/envjs.runner.sh +7 -0
  206. data/node_modules/jasmine-reporters/test/junit_xml_reporter.html +23 -0
  207. data/node_modules/jasmine-reporters/test/phantomjs-testrunner.js +39 -0
  208. data/node_modules/jasmine-reporters/test/phantomjs.runner.sh +30 -0
  209. data/node_modules/jasmine-reporters/test/pyphantomjs-plugins/saveToFile/__init__.py +1 -0
  210. data/node_modules/jasmine-reporters/test/pyphantomjs-plugins/saveToFile/saveToFile.py +46 -0
  211. data/node_modules/jasmine-runner/README.md +42 -0
  212. data/node_modules/jasmine-runner/TODO.md +16 -0
  213. data/node_modules/jasmine-runner/bin/jasmine +26 -0
  214. data/node_modules/jasmine-runner/lib/ServerRoutes.js +70 -0
  215. data/node_modules/jasmine-runner/lib/TestRunner.js +29 -0
  216. data/node_modules/jasmine-runner/lib/browser.js +14 -0
  217. data/node_modules/jasmine-runner/lib/config.js +21 -0
  218. data/node_modules/jasmine-runner/lib/jasmine-runner.js +83 -0
  219. data/node_modules/jasmine-runner/lib/monitor.js +34 -0
  220. data/node_modules/jasmine-runner/lib/notify.js +48 -0
  221. data/node_modules/jasmine-runner/lib/public/control-frame.js +57 -0
  222. data/node_modules/jasmine-runner/lib/public/jasmine-html.js +188 -0
  223. data/node_modules/jasmine-runner/lib/public/jasmine.css +166 -0
  224. data/node_modules/jasmine-runner/lib/public/jasmine.js +2421 -0
  225. data/node_modules/jasmine-runner/lib/public/jquery-1.4.3.js +166 -0
  226. data/node_modules/jasmine-runner/lib/public/json2.js +482 -0
  227. data/node_modules/jasmine-runner/lib/public/run.js +6 -0
  228. data/node_modules/jasmine-runner/lib/reporters.js +31 -0
  229. data/node_modules/jasmine-runner/lib/server-worker.js +18 -0
  230. data/node_modules/jasmine-runner/lib/server.js +27 -0
  231. data/node_modules/jasmine-runner/lib/template/jasmine.json +18 -0
  232. data/node_modules/jasmine-runner/lib/template/public/javascript/Player.js +22 -0
  233. data/node_modules/jasmine-runner/lib/template/public/javascript/Song.js +7 -0
  234. data/node_modules/jasmine-runner/lib/template/spec/PlayerSpec.coffee +45 -0
  235. data/node_modules/jasmine-runner/lib/template/spec/PlayerSpec.js +58 -0
  236. data/node_modules/jasmine-runner/lib/template/spec/SpecHelper.js +9 -0
  237. data/node_modules/jasmine-runner/lib/testserver.js +26 -0
  238. data/node_modules/jasmine-runner/lib/views/control-frame.jade +7 -0
  239. data/node_modules/jasmine-runner/lib/views/index.jade +18 -0
  240. data/node_modules/jasmine-runner/node_modules/.bin/cake +7 -0
  241. data/node_modules/jasmine-runner/node_modules/.bin/coffee +7 -0
  242. data/node_modules/jasmine-runner/node_modules/.bin/express +451 -0
  243. data/node_modules/jasmine-runner/node_modules/.bin/jade +92 -0
  244. data/node_modules/jasmine-runner/node_modules/.bin/vows +421 -0
  245. data/node_modules/jasmine-runner/node_modules/coffee-script/.npmignore +11 -0
  246. data/node_modules/jasmine-runner/node_modules/coffee-script/LICENSE +22 -0
  247. data/node_modules/jasmine-runner/node_modules/coffee-script/README +47 -0
  248. data/node_modules/jasmine-runner/node_modules/coffee-script/Rakefile +78 -0
  249. data/node_modules/jasmine-runner/node_modules/coffee-script/bin/cake +7 -0
  250. data/node_modules/jasmine-runner/node_modules/coffee-script/bin/coffee +7 -0
  251. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/browser.js +52 -0
  252. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/cake.js +76 -0
  253. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/coffee-script.js +82 -0
  254. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/command.js +269 -0
  255. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/grammar.js +586 -0
  256. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/helpers.js +66 -0
  257. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/index.js +8 -0
  258. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/lexer.js +638 -0
  259. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/nodes.js +2181 -0
  260. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/optparse.js +111 -0
  261. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/parser.js +656 -0
  262. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/repl.js +47 -0
  263. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/rewriter.js +353 -0
  264. data/node_modules/jasmine-runner/node_modules/coffee-script/lib/scope.js +120 -0
  265. data/node_modules/jasmine-runner/node_modules/coffee-script/package.json +22 -0
  266. data/node_modules/jasmine-runner/node_modules/colors/MIT-LICENSE.txt +20 -0
  267. data/node_modules/jasmine-runner/node_modules/colors/ReadMe.md +30 -0
  268. data/node_modules/jasmine-runner/node_modules/colors/colors.js +75 -0
  269. data/node_modules/jasmine-runner/node_modules/colors/example.js +6 -0
  270. data/node_modules/jasmine-runner/node_modules/colors/package.json +14 -0
  271. data/node_modules/jasmine-runner/node_modules/express/.npmignore +7 -0
  272. data/node_modules/jasmine-runner/node_modules/express/History.md +630 -0
  273. data/node_modules/jasmine-runner/node_modules/express/LICENSE +22 -0
  274. data/node_modules/jasmine-runner/node_modules/express/Makefile +39 -0
  275. data/node_modules/jasmine-runner/node_modules/express/Readme.md +102 -0
  276. data/node_modules/jasmine-runner/node_modules/express/bin/express +451 -0
  277. data/node_modules/jasmine-runner/node_modules/express/index.js +2 -0
  278. data/node_modules/jasmine-runner/node_modules/express/lib/express.js +78 -0
  279. data/node_modules/jasmine-runner/node_modules/express/lib/http.js +503 -0
  280. data/node_modules/jasmine-runner/node_modules/express/lib/https.js +52 -0
  281. data/node_modules/jasmine-runner/node_modules/express/lib/request.js +289 -0
  282. data/node_modules/jasmine-runner/node_modules/express/lib/response.js +423 -0
  283. data/node_modules/jasmine-runner/node_modules/express/lib/router/index.js +329 -0
  284. data/node_modules/jasmine-runner/node_modules/express/lib/router/methods.js +70 -0
  285. data/node_modules/jasmine-runner/node_modules/express/lib/router/route.js +71 -0
  286. data/node_modules/jasmine-runner/node_modules/express/lib/utils.js +122 -0
  287. data/node_modules/jasmine-runner/node_modules/express/lib/view.js +413 -0
  288. data/node_modules/jasmine-runner/node_modules/express/lib/view/partial.js +40 -0
  289. data/node_modules/jasmine-runner/node_modules/express/lib/view/view.js +206 -0
  290. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/.npmignore +11 -0
  291. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/LICENSE +24 -0
  292. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/index.js +2 -0
  293. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/cache.js +81 -0
  294. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/connect.js +106 -0
  295. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/http.js +215 -0
  296. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/https.js +47 -0
  297. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/index.js +46 -0
  298. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/basicAuth.js +93 -0
  299. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/bodyParser.js +92 -0
  300. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/compiler.js +163 -0
  301. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/cookieParser.js +46 -0
  302. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/csrf.js +105 -0
  303. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/directory.js +222 -0
  304. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/errorHandler.js +100 -0
  305. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/favicon.js +76 -0
  306. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/limit.js +82 -0
  307. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/logger.js +299 -0
  308. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/methodOverride.js +38 -0
  309. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/profiler.js +100 -0
  310. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/query.js +40 -0
  311. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/responseTime.js +34 -0
  312. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/router.js +379 -0
  313. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/session.js +346 -0
  314. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/session/cookie.js +126 -0
  315. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/session/memory.js +131 -0
  316. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/session/session.js +137 -0
  317. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/session/store.js +87 -0
  318. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/static.js +225 -0
  319. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/staticCache.js +175 -0
  320. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/middleware/vhost.js +44 -0
  321. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/patch.js +79 -0
  322. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/directory.html +75 -0
  323. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/error.html +13 -0
  324. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/favicon.ico +0 -0
  325. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page.png +0 -0
  326. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_add.png +0 -0
  327. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_attach.png +0 -0
  328. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_code.png +0 -0
  329. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_copy.png +0 -0
  330. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_delete.png +0 -0
  331. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_edit.png +0 -0
  332. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_error.png +0 -0
  333. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_excel.png +0 -0
  334. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_find.png +0 -0
  335. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_gear.png +0 -0
  336. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_go.png +0 -0
  337. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_green.png +0 -0
  338. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_key.png +0 -0
  339. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_lightning.png +0 -0
  340. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_link.png +0 -0
  341. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_paintbrush.png +0 -0
  342. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_paste.png +0 -0
  343. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_red.png +0 -0
  344. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_refresh.png +0 -0
  345. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_save.png +0 -0
  346. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white.png +0 -0
  347. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_acrobat.png +0 -0
  348. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_actionscript.png +0 -0
  349. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_add.png +0 -0
  350. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_c.png +0 -0
  351. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_camera.png +0 -0
  352. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_cd.png +0 -0
  353. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_code.png +0 -0
  354. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_code_red.png +0 -0
  355. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_coldfusion.png +0 -0
  356. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_compressed.png +0 -0
  357. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_copy.png +0 -0
  358. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_cplusplus.png +0 -0
  359. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_csharp.png +0 -0
  360. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_cup.png +0 -0
  361. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_database.png +0 -0
  362. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_delete.png +0 -0
  363. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_dvd.png +0 -0
  364. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_edit.png +0 -0
  365. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_error.png +0 -0
  366. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_excel.png +0 -0
  367. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_find.png +0 -0
  368. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_flash.png +0 -0
  369. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_freehand.png +0 -0
  370. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_gear.png +0 -0
  371. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_get.png +0 -0
  372. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_go.png +0 -0
  373. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_h.png +0 -0
  374. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_horizontal.png +0 -0
  375. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_key.png +0 -0
  376. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_lightning.png +0 -0
  377. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_link.png +0 -0
  378. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_magnify.png +0 -0
  379. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_medal.png +0 -0
  380. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_office.png +0 -0
  381. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_paint.png +0 -0
  382. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_paintbrush.png +0 -0
  383. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_paste.png +0 -0
  384. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_php.png +0 -0
  385. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_picture.png +0 -0
  386. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_powerpoint.png +0 -0
  387. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_put.png +0 -0
  388. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_ruby.png +0 -0
  389. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_stack.png +0 -0
  390. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_star.png +0 -0
  391. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_swoosh.png +0 -0
  392. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_text.png +0 -0
  393. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_text_width.png +0 -0
  394. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_tux.png +0 -0
  395. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_vector.png +0 -0
  396. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_visualstudio.png +0 -0
  397. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_width.png +0 -0
  398. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_word.png +0 -0
  399. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_world.png +0 -0
  400. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_wrench.png +0 -0
  401. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_white_zip.png +0 -0
  402. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_word.png +0 -0
  403. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/icons/page_world.png +0 -0
  404. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/public/style.css +141 -0
  405. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/lib/utils.js +451 -0
  406. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/package.json +24 -0
  407. data/node_modules/jasmine-runner/node_modules/express/node_modules/connect/test.js +11 -0
  408. data/node_modules/jasmine-runner/node_modules/express/node_modules/mime/LICENSE +19 -0
  409. data/node_modules/jasmine-runner/node_modules/express/node_modules/mime/README.md +50 -0
  410. data/node_modules/jasmine-runner/node_modules/express/node_modules/mime/mime.js +92 -0
  411. data/node_modules/jasmine-runner/node_modules/express/node_modules/mime/package.json +22 -0
  412. data/node_modules/jasmine-runner/node_modules/express/node_modules/mime/test.js +79 -0
  413. data/node_modules/jasmine-runner/node_modules/express/node_modules/mime/types/mime.types +1479 -0
  414. data/node_modules/jasmine-runner/node_modules/express/node_modules/mime/types/node.types +43 -0
  415. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/.gitignore +1 -0
  416. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/.gitmodules +6 -0
  417. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/History.md +57 -0
  418. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/Makefile +7 -0
  419. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/Readme.md +49 -0
  420. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/benchmark.js +17 -0
  421. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/examples.js +48 -0
  422. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/index.js +2 -0
  423. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/lib/querystring.js +236 -0
  424. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/package.json +16 -0
  425. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/test/parse.test.js +156 -0
  426. data/node_modules/jasmine-runner/node_modules/express/node_modules/qs/test/stringify.test.js +95 -0
  427. data/node_modules/jasmine-runner/node_modules/express/package.json +22 -0
  428. data/node_modules/jasmine-runner/node_modules/growl/History.md +10 -0
  429. data/node_modules/jasmine-runner/node_modules/growl/Readme.md +74 -0
  430. data/node_modules/jasmine-runner/node_modules/growl/lib/growl.js +80 -0
  431. data/node_modules/jasmine-runner/node_modules/growl/package.json +6 -0
  432. data/node_modules/jasmine-runner/node_modules/growl/seed.yml +4 -0
  433. data/node_modules/jasmine-runner/node_modules/growl/test.js +17 -0
  434. data/node_modules/jasmine-runner/node_modules/jade/.gitignore +3 -0
  435. data/node_modules/jasmine-runner/node_modules/jade/.gitmodules +21 -0
  436. data/node_modules/jasmine-runner/node_modules/jade/.npmignore +4 -0
  437. data/node_modules/jasmine-runner/node_modules/jade/CNAME +1 -0
  438. data/node_modules/jasmine-runner/node_modules/jade/History.md +163 -0
  439. data/node_modules/jasmine-runner/node_modules/jade/LICENSE +22 -0
  440. data/node_modules/jasmine-runner/node_modules/jade/Makefile +25 -0
  441. data/node_modules/jasmine-runner/node_modules/jade/Readme.md +408 -0
  442. data/node_modules/jasmine-runner/node_modules/jade/api.html +850 -0
  443. data/node_modules/jasmine-runner/node_modules/jade/bin/jade +92 -0
  444. data/node_modules/jasmine-runner/node_modules/jade/index.js +2 -0
  445. data/node_modules/jasmine-runner/node_modules/jade/lib/compiler.js +273 -0
  446. data/node_modules/jasmine-runner/node_modules/jade/lib/doctypes.js +18 -0
  447. data/node_modules/jasmine-runner/node_modules/jade/lib/filters.js +70 -0
  448. data/node_modules/jasmine-runner/node_modules/jade/lib/index.js +314 -0
  449. data/node_modules/jasmine-runner/node_modules/jade/lib/jade.js +314 -0
  450. data/node_modules/jasmine-runner/node_modules/jade/lib/lexer.js +359 -0
  451. data/node_modules/jasmine-runner/node_modules/jade/lib/nodes/block.js +29 -0
  452. data/node_modules/jasmine-runner/node_modules/jade/lib/nodes/code.js +35 -0
  453. data/node_modules/jasmine-runner/node_modules/jade/lib/nodes/comment.js +32 -0
  454. data/node_modules/jasmine-runner/node_modules/jade/lib/nodes/doctype.js +29 -0
  455. data/node_modules/jasmine-runner/node_modules/jade/lib/nodes/each.js +35 -0
  456. data/node_modules/jasmine-runner/node_modules/jade/lib/nodes/filter.js +33 -0
  457. data/node_modules/jasmine-runner/node_modules/jade/lib/nodes/index.js +16 -0
  458. data/node_modules/jasmine-runner/node_modules/jade/lib/nodes/node.js +20 -0
  459. data/node_modules/jasmine-runner/node_modules/jade/lib/nodes/tag.js +80 -0
  460. data/node_modules/jasmine-runner/node_modules/jade/lib/nodes/text.js +29 -0
  461. data/node_modules/jasmine-runner/node_modules/jade/lib/parser.js +358 -0
  462. data/node_modules/jasmine-runner/node_modules/jade/lib/self-closing.js +17 -0
  463. data/node_modules/jasmine-runner/node_modules/jade/lib/utils.js +49 -0
  464. data/node_modules/jasmine-runner/node_modules/jade/package.json +9 -0
  465. data/node_modules/jasmine-runner/node_modules/libnotify/.gitignore +2 -0
  466. data/node_modules/jasmine-runner/node_modules/libnotify/README.md +59 -0
  467. data/node_modules/jasmine-runner/node_modules/libnotify/lib/libnotify.js +72 -0
  468. data/node_modules/jasmine-runner/node_modules/libnotify/package.json +11 -0
  469. data/node_modules/jasmine-runner/node_modules/libnotify/seed.yml +5 -0
  470. data/node_modules/jasmine-runner/node_modules/libnotify/test.js +5 -0
  471. data/node_modules/jasmine-runner/node_modules/socket.io/.gitignore +8 -0
  472. data/node_modules/jasmine-runner/node_modules/socket.io/Makefile +10 -0
  473. data/node_modules/jasmine-runner/node_modules/socket.io/README.md +218 -0
  474. data/node_modules/jasmine-runner/node_modules/socket.io/example/chat.html +61 -0
  475. data/node_modules/jasmine-runner/node_modules/socket.io/example/json.js +18 -0
  476. data/node_modules/jasmine-runner/node_modules/socket.io/example/server.js +58 -0
  477. data/node_modules/jasmine-runner/node_modules/socket.io/index.js +1 -0
  478. data/node_modules/jasmine-runner/node_modules/socket.io/lib/socket.io/client.js +191 -0
  479. data/node_modules/jasmine-runner/node_modules/socket.io/lib/socket.io/index.js +4 -0
  480. data/node_modules/jasmine-runner/node_modules/socket.io/lib/socket.io/listener.js +166 -0
  481. data/node_modules/jasmine-runner/node_modules/socket.io/lib/socket.io/transports/flashsocket.js +44 -0
  482. data/node_modules/jasmine-runner/node_modules/socket.io/lib/socket.io/transports/htmlfile.js +45 -0
  483. data/node_modules/jasmine-runner/node_modules/socket.io/lib/socket.io/transports/jsonp-polling.js +32 -0
  484. data/node_modules/jasmine-runner/node_modules/socket.io/lib/socket.io/transports/websocket.js +137 -0
  485. data/node_modules/jasmine-runner/node_modules/socket.io/lib/socket.io/transports/xhr-multipart.js +63 -0
  486. data/node_modules/jasmine-runner/node_modules/socket.io/lib/socket.io/transports/xhr-polling.js +75 -0
  487. data/node_modules/jasmine-runner/node_modules/socket.io/lib/socket.io/utils.js +52 -0
  488. data/node_modules/jasmine-runner/node_modules/socket.io/package.json +17 -0
  489. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/.gitignore +3 -0
  490. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/.gitmodules +3 -0
  491. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/History.md +97 -0
  492. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/Makefile +53 -0
  493. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/Readme.md +39 -0
  494. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/bin/expresso +837 -0
  495. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/COPYING +339 -0
  496. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/Makefile.am +81 -0
  497. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/Makefile.in +884 -0
  498. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/Readme.md +8 -0
  499. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/aclocal.m4 +872 -0
  500. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/config.guess +1526 -0
  501. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/config.h.in +92 -0
  502. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/config.rpath +666 -0
  503. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/config.sub +1658 -0
  504. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/configure +7971 -0
  505. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/configure.ac +88 -0
  506. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/depcomp +589 -0
  507. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/encoding.c +315 -0
  508. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/encoding.h +33 -0
  509. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/generate-resources.c +58 -0
  510. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/global.h +29 -0
  511. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/highlight.c +478 -0
  512. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/highlight.h +37 -0
  513. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/http-connection.c +192 -0
  514. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/http-exchange.c +494 -0
  515. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/http-host.c +95 -0
  516. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/http-message.c +900 -0
  517. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/http-server.c +236 -0
  518. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/http-server.h +208 -0
  519. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/http-url.c +156 -0
  520. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/install-sh +519 -0
  521. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/instrument-js.cpp +1873 -0
  522. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/instrument-js.h +81 -0
  523. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/instrument.c +226 -0
  524. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/instrument.h +31 -0
  525. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/GNUmakefile +15 -0
  526. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/Makefile.ref +483 -0
  527. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/README.html +54 -0
  528. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/SpiderMonkey.rsp +11 -0
  529. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/aclocal.m4 +9 -0
  530. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/bench.sh +5 -0
  531. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/builtins.tbl +98 -0
  532. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config.mk +206 -0
  533. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/Makefile.in +106 -0
  534. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/Moz/Milestone.pm +232 -0
  535. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/autoconf.mk.in +349 -0
  536. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/check-sync-dirs.py +108 -0
  537. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/check-sync-exceptions +6 -0
  538. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/config.mk +884 -0
  539. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/fastcwd.pl +66 -0
  540. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/gcc_hidden.h +2 -0
  541. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/insure.mk +53 -0
  542. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/make-system-wrappers.pl +59 -0
  543. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/milestone.pl +112 -0
  544. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/milestone.txt +13 -0
  545. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/mkdepend/Makefile.in +84 -0
  546. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/mkdepend/cppsetup.c +233 -0
  547. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/mkdepend/def.h +184 -0
  548. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/mkdepend/ifparser.c +549 -0
  549. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/mkdepend/ifparser.h +83 -0
  550. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/mkdepend/imakemdep.h +733 -0
  551. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/mkdepend/include.c +337 -0
  552. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/mkdepend/main.c +860 -0
  553. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/mkdepend/mkdepend.man +382 -0
  554. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/mkdepend/parse.c +686 -0
  555. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/mkdepend/pr.c +124 -0
  556. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/nfspwd.pl +50 -0
  557. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/nsinstall.c +481 -0
  558. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/nsinstall.py +139 -0
  559. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/pathsub.c +247 -0
  560. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/pathsub.h +74 -0
  561. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/preprocessor.pl +671 -0
  562. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/revdepth-nt.pl +48 -0
  563. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/revdepth.pl +51 -0
  564. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/rules.mk +2269 -0
  565. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/system-headers +1038 -0
  566. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/version.mk +85 -0
  567. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/config/version_win.pl +423 -0
  568. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/dtoa.c +3321 -0
  569. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/editline/Makefile.ref +143 -0
  570. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/editline/README +83 -0
  571. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/editline/editline.3 +175 -0
  572. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/editline/editline.c +1368 -0
  573. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/editline/editline.h +135 -0
  574. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/editline/sysunix.c +182 -0
  575. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/editline/unix.h +82 -0
  576. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/javascript-trace.d +73 -0
  577. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jitstats.tbl +52 -0
  578. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/js-config.h.in +55 -0
  579. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/js-config.in +111 -0
  580. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/js.cpp +4050 -0
  581. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/js.mdp +0 -0
  582. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/js.msg +309 -0
  583. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/js3240.rc +79 -0
  584. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsOS240.def +654 -0
  585. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsapi.cpp +6060 -0
  586. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsapi.h +2699 -0
  587. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsarena.cpp +450 -0
  588. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsarena.h +318 -0
  589. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsarray.cpp +3426 -0
  590. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsarray.h +191 -0
  591. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsatom.cpp +1064 -0
  592. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsatom.h +458 -0
  593. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsbit.h +253 -0
  594. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsbool.cpp +182 -0
  595. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsbool.h +75 -0
  596. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsbuiltins.cpp +497 -0
  597. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsbuiltins.h +374 -0
  598. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsclist.h +139 -0
  599. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jscntxt.cpp +1394 -0
  600. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jscntxt.h +1247 -0
  601. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jscompat.h +57 -0
  602. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsconfig.mk +181 -0
  603. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jscpucfg.cpp +388 -0
  604. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jscpucfg.h +212 -0
  605. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsdate.cpp +2475 -0
  606. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsdate.h +124 -0
  607. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsdbgapi.cpp +1954 -0
  608. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsdbgapi.h +500 -0
  609. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsdhash.cpp +876 -0
  610. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsdhash.h +588 -0
  611. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsdtoa.cpp +572 -0
  612. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsdtoa.h +131 -0
  613. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsdtracef.c +318 -0
  614. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsdtracef.h +81 -0
  615. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsemit.cpp +6857 -0
  616. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsemit.h +777 -0
  617. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsexn.cpp +1376 -0
  618. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsexn.h +96 -0
  619. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsfile.cpp +2736 -0
  620. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsfile.h +56 -0
  621. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsfile.msg +90 -0
  622. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsfun.cpp +2706 -0
  623. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsfun.h +296 -0
  624. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsgc.cpp +3763 -0
  625. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsgc.h +427 -0
  626. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jshash.cpp +476 -0
  627. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jshash.h +151 -0
  628. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsify.pl +483 -0
  629. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsinterp.cpp +7225 -0
  630. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsinterp.h +591 -0
  631. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsinvoke.cpp +42 -0
  632. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsiter.cpp +1050 -0
  633. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsiter.h +140 -0
  634. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jskeyword.tbl +124 -0
  635. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jskwgen.cpp +460 -0
  636. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jslibmath.h +69 -0
  637. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jslock.cpp +1417 -0
  638. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jslock.h +311 -0
  639. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jslocko.asm +60 -0
  640. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jslog2.cpp +94 -0
  641. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jslong.cpp +264 -0
  642. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jslong.h +412 -0
  643. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsmath.cpp +721 -0
  644. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsmath.h +63 -0
  645. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsnum.cpp +1338 -0
  646. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsnum.h +287 -0
  647. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsobj.cpp +5563 -0
  648. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsobj.h +735 -0
  649. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/json.cpp +954 -0
  650. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/json.h +107 -0
  651. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsopcode.cpp +5304 -0
  652. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsopcode.h +404 -0
  653. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsopcode.tbl +557 -0
  654. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsoplengen.cpp +121 -0
  655. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsotypes.h +202 -0
  656. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsparse.cpp +6822 -0
  657. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsparse.h +508 -0
  658. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsprf.cpp +1262 -0
  659. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsprf.h +150 -0
  660. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsproto.tbl +129 -0
  661. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsprvtd.h +263 -0
  662. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jspubtd.h +727 -0
  663. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsregexp.cpp +4772 -0
  664. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsregexp.h +192 -0
  665. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsreops.tbl +145 -0
  666. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsscan.cpp +2017 -0
  667. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsscan.h +389 -0
  668. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsscope.cpp +1955 -0
  669. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsscope.h +419 -0
  670. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsscript.cpp +1891 -0
  671. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsscript.h +330 -0
  672. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsshell.msg +51 -0
  673. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsstaticcheck.h +57 -0
  674. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsstddef.h +87 -0
  675. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsstr.cpp +5347 -0
  676. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsstr.h +662 -0
  677. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jstracer.cpp +8276 -0
  678. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jstracer.h +552 -0
  679. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jstypes.h +490 -0
  680. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsutil.cpp +345 -0
  681. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsutil.h +168 -0
  682. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsversion.h +243 -0
  683. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsxdrapi.cpp +800 -0
  684. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsxdrapi.h +220 -0
  685. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsxml.cpp +8343 -0
  686. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/jsxml.h +298 -0
  687. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/lock_SunOS.s +119 -0
  688. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/plify_jsdhash.sed +35 -0
  689. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/prmjtime.cpp +846 -0
  690. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/prmjtime.h +103 -0
  691. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/AIX4.1.mk +65 -0
  692. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/AIX4.2.mk +64 -0
  693. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/AIX4.3.mk +65 -0
  694. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/Cygwin.mk +14 -0
  695. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/Darwin.mk +85 -0
  696. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/Darwin1.3.mk +81 -0
  697. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/Darwin1.4.mk +41 -0
  698. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/Darwin5.2.mk +81 -0
  699. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/Darwin5.3.mk +81 -0
  700. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/Darwin64.mk +72 -0
  701. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/HP-UXB.10.10.mk +77 -0
  702. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/HP-UXB.10.20.mk +77 -0
  703. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/HP-UXB.11.00.mk +80 -0
  704. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/IRIX.mk +87 -0
  705. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/IRIX5.3.mk +44 -0
  706. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/IRIX6.1.mk +44 -0
  707. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/IRIX6.2.mk +44 -0
  708. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/IRIX6.3.mk +44 -0
  709. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/IRIX6.5.mk +44 -0
  710. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/Linux_All.mk +105 -0
  711. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/MSYS.mk +7 -0
  712. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/Mac_OS10.0.mk +82 -0
  713. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/OSF1V4.0.mk +72 -0
  714. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/OSF1V5.0.mk +69 -0
  715. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/SunOS4.1.4.mk +101 -0
  716. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/SunOS5.10.mk +50 -0
  717. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/SunOS5.3.mk +91 -0
  718. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/SunOS5.4.mk +92 -0
  719. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/SunOS5.5.1.mk +44 -0
  720. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/SunOS5.5.mk +87 -0
  721. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/SunOS5.6.mk +89 -0
  722. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/SunOS5.7.mk +44 -0
  723. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/SunOS5.8.mk +44 -0
  724. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/SunOS5.9.mk +44 -0
  725. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/WINNT4.0.mk +118 -0
  726. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/WINNT5.0.mk +118 -0
  727. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/WINNT5.1.mk +118 -0
  728. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/WINNT5.2.mk +118 -0
  729. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/WINNT6.0.mk +118 -0
  730. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/ref-config/dgux.mk +64 -0
  731. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/resource.h +15 -0
  732. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/rules.mk +206 -0
  733. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/time.sh +13 -0
  734. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/js/win32.order +384 -0
  735. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage-help.txt +12 -0
  736. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage-highlight.css +38 -0
  737. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage-ie.css +89 -0
  738. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage-overlay.js +211 -0
  739. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage-server-help.txt +17 -0
  740. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage-server.1 +79 -0
  741. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage-server.c +1307 -0
  742. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage-throbber.gif +0 -0
  743. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage.1 +52 -0
  744. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage.c +142 -0
  745. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage.css +328 -0
  746. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage.html +125 -0
  747. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage.js +1024 -0
  748. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage.jsm +22 -0
  749. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage.manifest +2 -0
  750. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/jscoverage.xul +36 -0
  751. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/m4/iconv.m4 +180 -0
  752. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/m4/lib-ld.m4 +110 -0
  753. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/m4/lib-link.m4 +709 -0
  754. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/m4/lib-prefix.m4 +185 -0
  755. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/make-bin-dist.sh.in +24 -0
  756. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/make-dist.sh.in +43 -0
  757. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/missing +367 -0
  758. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/report.js +76 -0
  759. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/resource-manager.c +59 -0
  760. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/resource-manager.h +46 -0
  761. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/stream.c +129 -0
  762. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/stream.h +57 -0
  763. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/Makefile.am +130 -0
  764. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/Makefile.in +846 -0
  765. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/asprintf.c +42 -0
  766. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/asprintf.sh +19 -0
  767. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/charset.sh +110 -0
  768. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/chunked.sh +74 -0
  769. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/common.sh +7 -0
  770. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/destination-is-existing-directory.expected.err +2 -0
  771. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/destination-is-file.expected.err +2 -0
  772. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/encoding-requires-argument.expected.err +2 -0
  773. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/encodings.c +223 -0
  774. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/encodings.sh +19 -0
  775. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/exclude-requires-argument.expected.err +2 -0
  776. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/fatal.sh +110 -0
  777. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/gethostbyname.c +53 -0
  778. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/gethostbyname.sh +25 -0
  779. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/help.sh +35 -0
  780. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/http-client-bad-body.c +98 -0
  781. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/http-client-bad-url.c +77 -0
  782. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/http-client-close-after-request.c +57 -0
  783. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/http-server-bad-body.c +97 -0
  784. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/http-server-bad-headers.c +97 -0
  785. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/http-server-charset.c +144 -0
  786. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/http-server-chunked.c +196 -0
  787. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/http-server-close-immediately.c +60 -0
  788. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/invalid-option.expected.err +2 -0
  789. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/invalid-option.sh +29 -0
  790. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-ignore.expected/ignore.js +106 -0
  791. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-ignore.sh +28 -0
  792. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-ignore/ignore.js +44 -0
  793. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-invalid.expected.err +2 -0
  794. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-invalid/javascript-invalid.js +1 -0
  795. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-setter.expected.err +1 -0
  796. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-setter/javascript-setter.js +3 -0
  797. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-utf-8.expected/javascript-utf-8.js +15 -0
  798. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-utf-8.sh +43 -0
  799. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-utf-8/javascript-utf-8.js +2 -0
  800. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-xml.expected.err +1 -0
  801. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript-xml/javascript-xml.js +8 -0
  802. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-array-comprehension.js +32 -0
  803. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-assign.js +51 -0
  804. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-colon.js +24 -0
  805. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-comma.js +12 -0
  806. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-cr.js +12 -0
  807. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-crlf.js +12 -0
  808. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-debugger.js +21 -0
  809. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-dec.js +15 -0
  810. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-delete.js +12 -0
  811. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-destructuring.js +96 -0
  812. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-do.js +28 -0
  813. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-dot.js +30 -0
  814. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-empty.js +9 -0
  815. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-for.js +51 -0
  816. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-foreach.js +16 -0
  817. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-function.js +79 -0
  818. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-generator-expression.js +45 -0
  819. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-generator.js +32 -0
  820. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-getter-setter.js +31 -0
  821. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-hook.js +15 -0
  822. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-if.js +71 -0
  823. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-in.js +19 -0
  824. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-inc.js +15 -0
  825. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-iso-8859-1.js +15 -0
  826. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-lambda.js +14 -0
  827. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-let.js +148 -0
  828. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-lf.js +12 -0
  829. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-new.js +22 -0
  830. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-number.js +57 -0
  831. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-object.js +15 -0
  832. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-op.js +108 -0
  833. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-primary.js +21 -0
  834. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-rb.js +24 -0
  835. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-rc.js +15 -0
  836. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-rp.js +12 -0
  837. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-special-characters.js +30 -0
  838. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-string.js +36 -0
  839. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-switch.js +55 -0
  840. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-throw.js +21 -0
  841. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-try.js +66 -0
  842. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-unaryop.js +27 -0
  843. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-var.js +15 -0
  844. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-while.js +79 -0
  845. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.expected/javascript-with.js +30 -0
  846. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript.sh +53 -0
  847. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-array-comprehension.js +14 -0
  848. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-assign.js +14 -0
  849. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-colon.js +7 -0
  850. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-comma.js +1 -0
  851. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-cr.js +1 -0
  852. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-crlf.js +4 -0
  853. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-debugger.js +6 -0
  854. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-dec.js +2 -0
  855. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-delete.js +1 -0
  856. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-destructuring.js +42 -0
  857. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-do.js +10 -0
  858. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-dot.js +8 -0
  859. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-empty.js +0 -0
  860. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-for.js +22 -0
  861. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-foreach.js +8 -0
  862. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-function.js +38 -0
  863. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-generator-expression.js +18 -0
  864. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-generator.js +11 -0
  865. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-getter-setter.js +19 -0
  866. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-hook.js +2 -0
  867. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-if.js +30 -0
  868. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-in.js +4 -0
  869. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-inc.js +2 -0
  870. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-iso-8859-1.js +2 -0
  871. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-lambda.js +3 -0
  872. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-let.js +79 -0
  873. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-lf.js +4 -0
  874. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-new.js +4 -0
  875. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-number.js +19 -0
  876. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-object.js +2 -0
  877. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-op.js +55 -0
  878. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-primary.js +4 -0
  879. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-rb.js +5 -0
  880. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-rc.js +7 -0
  881. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-rp.js +1 -0
  882. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-special-characters.js +11 -0
  883. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-string.js +11 -0
  884. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-switch.js +21 -0
  885. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-throw.js +6 -0
  886. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-try.js +32 -0
  887. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-unaryop.js +6 -0
  888. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-var.js +2 -0
  889. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-while.js +35 -0
  890. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/javascript/javascript-with.js +9 -0
  891. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/json-cmp.js +65 -0
  892. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/json.c +48 -0
  893. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/json.sh +19 -0
  894. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/mkdirs.c +42 -0
  895. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/mkdirs.sh +19 -0
  896. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/netcat.pl +35 -0
  897. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/no-arguments.expected.err +2 -0
  898. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/no-arguments.sh +29 -0
  899. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/no-instrument-requires-argument.expected.err +2 -0
  900. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/proxy-bad-request-body.sh +58 -0
  901. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/proxy-bad-response-body-javascript.sh +53 -0
  902. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/proxy-bad-response-body.expected.err +1 -0
  903. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/proxy-bad-response-body.sh +54 -0
  904. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/proxy-bad-response-headers.sh +53 -0
  905. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/proxy-no-server.sh +49 -0
  906. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/proxy-url.sh +67 -0
  907. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/proxy.sh +143 -0
  908. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive-crlf.sh +59 -0
  909. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive-dir-list.c +93 -0
  910. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive-dir-list.sh +19 -0
  911. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive-exclude.sh +41 -0
  912. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive-fatal.sh +40 -0
  913. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive-no-instrument.sh +41 -0
  914. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/1/1.css +3 -0
  915. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/1/1.html +12 -0
  916. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/1/1.js +12 -0
  917. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/1/2/2.css +3 -0
  918. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/1/2/2.html +11 -0
  919. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/1/2/2.js +12 -0
  920. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/image.png +0 -0
  921. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/index.html +12 -0
  922. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/script.js +19 -0
  923. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/style.css +3 -0
  924. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/unix.txt +3 -0
  925. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/windows.txt +3 -0
  926. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.expected/x +1 -0
  927. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive.sh +55 -0
  928. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/1/1.css +3 -0
  929. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/1/1.html +12 -0
  930. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/1/1.js +1 -0
  931. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/1/2/2.css +3 -0
  932. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/1/2/2.html +11 -0
  933. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/1/2/2.js +1 -0
  934. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/image.png +0 -0
  935. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/index.html +12 -0
  936. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/script.js +6 -0
  937. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/style.css +3 -0
  938. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/unix.txt +3 -0
  939. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/windows.txt +3 -0
  940. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/recursive/x +1 -0
  941. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/same-directory.expected.err +1 -0
  942. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/same-directory.sh +30 -0
  943. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-bad-requests.sh +104 -0
  944. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-close-after-request.sh +47 -0
  945. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-content-types.sh +68 -0
  946. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-directory-listing.expected +4 -0
  947. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-directory-listing.sh +57 -0
  948. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-directory-redirect.sh +50 -0
  949. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-encoded-url.sh +57 -0
  950. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-error.sh +61 -0
  951. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-help.sh +26 -0
  952. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-ip-address.sh +68 -0
  953. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-shutdown-bad-method.sh +49 -0
  954. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-shutdown.expected.err +1 -0
  955. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-shutdown.sh +42 -0
  956. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-special-file.sh +62 -0
  957. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-unreadable-directory.sh +61 -0
  958. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-unreadable-file.sh +62 -0
  959. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-verbose.expected.err +4 -0
  960. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-verbose.sh +54 -0
  961. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server-version.sh +25 -0
  962. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server.pl +61 -0
  963. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/server.sh +216 -0
  964. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/source-does-not-exist.expected.err +2 -0
  965. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/source-is-file.expected.err +2 -0
  966. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-bad-json.sh +50 -0
  967. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-bad-request-body.sh +48 -0
  968. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-bad-response-headers.sh +56 -0
  969. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-bad-source-urls.expected.err +3 -0
  970. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-bad-source-urls.expected.json +14 -0
  971. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-escaped-characters.expected.json +6 -0
  972. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-escaped-characters.js +11 -0
  973. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-escaped-characters.json +3 -0
  974. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-escaped-characters.sh +52 -0
  975. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-server-bad-body.sh +59 -0
  976. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-server-closes-immediately.sh +58 -0
  977. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-source-not-found.expected.err +1 -0
  978. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-source-not-found.expected.json +6 -0
  979. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-source-not-found.json +3 -0
  980. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-source-not-found.sh +50 -0
  981. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-source-urls.expected.err +3 -0
  982. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-source-urls.expected.json +14 -0
  983. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-unreachable-source-urls.expected.err +3 -0
  984. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-unreachable-source-urls.expected.json +14 -0
  985. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-unreadable-json.sh +66 -0
  986. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store-unwritable-json.sh +58 -0
  987. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store.expected.json +14 -0
  988. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store.json +5 -0
  989. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/store.sh +137 -0
  990. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/streams.c +107 -0
  991. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/streams.sh +19 -0
  992. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/too-many-arguments.expected.err +2 -0
  993. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/valgrind.sh +7 -0
  994. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/tests/version.sh +29 -0
  995. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/util.c +570 -0
  996. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/deps/jscoverage/util.h +133 -0
  997. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/docs/api.html +1048 -0
  998. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/docs/index.html +373 -0
  999. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/docs/index.md +290 -0
  1000. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/docs/layout/foot.html +3 -0
  1001. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/docs/layout/head.html +42 -0
  1002. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/lib/bar.js +4 -0
  1003. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/lib/foo.js +16 -0
  1004. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/package.json +12 -0
  1005. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/test/assert.test.js +84 -0
  1006. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/test/async.test.js +6 -0
  1007. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/test/bar.test.js +12 -0
  1008. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/test/foo.test.js +13 -0
  1009. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/test/http.test.js +82 -0
  1010. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/test/serial/async.test.js +38 -0
  1011. data/node_modules/jasmine-runner/node_modules/socket.io/support/expresso/test/serial/http.test.js +47 -0
  1012. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/LICENSE +27 -0
  1013. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/Makefile +8 -0
  1014. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/README.md +41 -0
  1015. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/examples/client-unix.js +12 -0
  1016. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/examples/client.js +10 -0
  1017. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/examples/server-unix.js +13 -0
  1018. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/lib/websocket.js +562 -0
  1019. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/package.json +22 -0
  1020. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/test/test-basic.js +63 -0
  1021. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/test/test-readonly-attrs.js +44 -0
  1022. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/test/test-ready-state.js +23 -0
  1023. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/test/test-unix-send-fd.js +63 -0
  1024. data/node_modules/jasmine-runner/node_modules/socket.io/support/node-websocket-client/test/test-unix-sockets.js +46 -0
  1025. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/.gitignore +1 -0
  1026. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/.gitmodules +3 -0
  1027. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/Makefile +2 -0
  1028. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/README.md +213 -0
  1029. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/io.js +24 -0
  1030. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/socket.js +157 -0
  1031. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/transport.js +141 -0
  1032. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/transports/flashsocket.js +53 -0
  1033. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/transports/htmlfile.js +73 -0
  1034. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/transports/jsonp-polling.js +116 -0
  1035. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/transports/websocket.js +60 -0
  1036. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/transports/xhr-multipart.js +36 -0
  1037. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/transports/xhr-polling.js +68 -0
  1038. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/transports/xhr.js +131 -0
  1039. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/util.js +60 -0
  1040. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/.gitignore +1 -0
  1041. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/FABridge.js +604 -0
  1042. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/README.txt +109 -0
  1043. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/WebSocketMain.swf +0 -0
  1044. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/WebSocketMainInsecure.zip +0 -0
  1045. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/WebSocket.as +461 -0
  1046. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/WebSocketMain.as +94 -0
  1047. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/WebSocketMainInsecure.as +19 -0
  1048. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/WebSocketStateEvent.as +32 -0
  1049. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/bridge/FABridge.as +943 -0
  1050. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/build.sh +10 -0
  1051. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/adobe/net/proxies/RFC2817Socket.as +204 -0
  1052. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/gsolo/encryption/MD5.as +375 -0
  1053. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/Crypto.as +287 -0
  1054. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/cert/MozillaRootCertificates.as +3235 -0
  1055. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/cert/X509Certificate.as +218 -0
  1056. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/cert/X509CertificateCollection.as +57 -0
  1057. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/hash/HMAC.as +82 -0
  1058. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/hash/IHMAC.as +27 -0
  1059. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/hash/IHash.as +21 -0
  1060. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/hash/MAC.as +137 -0
  1061. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/hash/MD2.as +124 -0
  1062. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/hash/MD5.as +204 -0
  1063. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/hash/SHA1.as +106 -0
  1064. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/hash/SHA224.as +28 -0
  1065. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/hash/SHA256.as +115 -0
  1066. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/hash/SHABase.as +71 -0
  1067. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/prng/ARC4.as +90 -0
  1068. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/prng/IPRNG.as +20 -0
  1069. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/prng/Random.as +119 -0
  1070. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/prng/TLSPRF.as +142 -0
  1071. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/rsa/RSAKey.as +339 -0
  1072. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/AESKey.as +2797 -0
  1073. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/BlowFishKey.as +375 -0
  1074. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/CBCMode.as +55 -0
  1075. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/CFB8Mode.as +61 -0
  1076. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/CFBMode.as +64 -0
  1077. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/CTRMode.as +58 -0
  1078. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/DESKey.as +365 -0
  1079. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/ECBMode.as +86 -0
  1080. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/ICipher.as +21 -0
  1081. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/IMode.as +15 -0
  1082. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/IPad.as +32 -0
  1083. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/IStreamCipher.as +21 -0
  1084. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/ISymmetricKey.as +35 -0
  1085. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/IVMode.as +110 -0
  1086. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/NullPad.as +34 -0
  1087. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/OFBMode.as +52 -0
  1088. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/PKCS5.as +44 -0
  1089. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/SSLPad.as +44 -0
  1090. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/SimpleIVMode.as +60 -0
  1091. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/TLSPad.as +42 -0
  1092. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/TripleDESKey.as +88 -0
  1093. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/XTeaKey.as +94 -0
  1094. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/aeskey.pl +29 -0
  1095. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/symmetric/dump.txt +2304 -0
  1096. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/AESKeyTest.as +1220 -0
  1097. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/ARC4Test.as +58 -0
  1098. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/BigIntegerTest.as +39 -0
  1099. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/BlowFishKeyTest.as +148 -0
  1100. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/CBCModeTest.as +160 -0
  1101. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/CFB8ModeTest.as +71 -0
  1102. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/CFBModeTest.as +98 -0
  1103. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/CTRModeTest.as +109 -0
  1104. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/DESKeyTest.as +112 -0
  1105. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/ECBModeTest.as +151 -0
  1106. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/HMACTest.as +184 -0
  1107. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/ITestHarness.as +20 -0
  1108. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/MD2Test.as +56 -0
  1109. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/MD5Test.as +58 -0
  1110. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/OFBModeTest.as +101 -0
  1111. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/RSAKeyTest.as +92 -0
  1112. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/SHA1Test.as +198 -0
  1113. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/SHA224Test.as +58 -0
  1114. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/SHA256Test.as +60 -0
  1115. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/TLSPRFTest.as +51 -0
  1116. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/TestCase.as +42 -0
  1117. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/TripleDESKeyTest.as +59 -0
  1118. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tests/XTeaKeyTest.as +66 -0
  1119. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/BulkCiphers.as +102 -0
  1120. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/CipherSuites.as +117 -0
  1121. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/IConnectionState.as +14 -0
  1122. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/ISecurityParameters.as +29 -0
  1123. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/KeyExchanges.as +24 -0
  1124. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/MACs.as +38 -0
  1125. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/SSLConnectionState.as +171 -0
  1126. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/SSLEvent.as +26 -0
  1127. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/SSLSecurityParameters.as +340 -0
  1128. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/TLSConfig.as +70 -0
  1129. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/TLSConnectionState.as +151 -0
  1130. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/TLSEngine.as +895 -0
  1131. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/TLSError.as +39 -0
  1132. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/TLSEvent.as +27 -0
  1133. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/TLSSecurityParameters.as +197 -0
  1134. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/TLSSocket.as +370 -0
  1135. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/TLSSocketEvent.as +26 -0
  1136. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/crypto/tls/TLSTest.as +180 -0
  1137. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/math/BarrettReduction.as +90 -0
  1138. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/math/BigInteger.as +1543 -0
  1139. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/math/ClassicReduction.as +35 -0
  1140. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/math/IReduction.as +11 -0
  1141. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/math/MontgomeryReduction.as +85 -0
  1142. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/math/NullReduction.as +34 -0
  1143. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/math/bi_internal.as +11 -0
  1144. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/ArrayUtil.as +25 -0
  1145. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/Base64.as +189 -0
  1146. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/Hex.as +66 -0
  1147. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/Memory.as +28 -0
  1148. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/ByteString.as +43 -0
  1149. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/DER.as +210 -0
  1150. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/IAsn1Type.as +21 -0
  1151. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/Integer.as +44 -0
  1152. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/OID.as +35 -0
  1153. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/ObjectIdentifier.as +112 -0
  1154. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/PEM.as +118 -0
  1155. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/PrintableString.as +49 -0
  1156. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/Sequence.as +90 -0
  1157. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/Set.as +27 -0
  1158. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/Type.as +94 -0
  1159. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/der/UTCTime.as +60 -0
  1160. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/sample.html +76 -0
  1161. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/swfobject.js +4 -0
  1162. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/lib/vendor/web-socket-js/web_socket.js +388 -0
  1163. data/node_modules/jasmine-runner/node_modules/socket.io/support/socket.io-client/socket.io.js +1918 -0
  1164. data/node_modules/jasmine-runner/node_modules/socket.io/tests/index.js +17 -0
  1165. data/node_modules/jasmine-runner/node_modules/socket.io/tests/listener.js +152 -0
  1166. data/node_modules/jasmine-runner/node_modules/socket.io/tests/transports.flashsocket.js +48 -0
  1167. data/node_modules/jasmine-runner/node_modules/socket.io/tests/transports.htmlfile.js +214 -0
  1168. data/node_modules/jasmine-runner/node_modules/socket.io/tests/transports.jsonp-polling.js +148 -0
  1169. data/node_modules/jasmine-runner/node_modules/socket.io/tests/transports.websocket.js +245 -0
  1170. data/node_modules/jasmine-runner/node_modules/socket.io/tests/transports.xhr-multipart.js +215 -0
  1171. data/node_modules/jasmine-runner/node_modules/socket.io/tests/transports.xhr-polling.js +138 -0
  1172. data/node_modules/jasmine-runner/node_modules/socket.io/tests/utils.js +25 -0
  1173. data/node_modules/jasmine-runner/node_modules/vows/LICENSE +20 -0
  1174. data/node_modules/jasmine-runner/node_modules/vows/Makefile +7 -0
  1175. data/node_modules/jasmine-runner/node_modules/vows/README.md +39 -0
  1176. data/node_modules/jasmine-runner/node_modules/vows/bin/vows +421 -0
  1177. data/node_modules/jasmine-runner/node_modules/vows/lib/assert/error.js +27 -0
  1178. data/node_modules/jasmine-runner/node_modules/vows/lib/assert/macros.js +180 -0
  1179. data/node_modules/jasmine-runner/node_modules/vows/lib/vows.js +195 -0
  1180. data/node_modules/jasmine-runner/node_modules/vows/lib/vows/console.js +93 -0
  1181. data/node_modules/jasmine-runner/node_modules/vows/lib/vows/context.js +55 -0
  1182. data/node_modules/jasmine-runner/node_modules/vows/lib/vows/extras.js +28 -0
  1183. data/node_modules/jasmine-runner/node_modules/vows/lib/vows/reporters/dot-matrix.js +69 -0
  1184. data/node_modules/jasmine-runner/node_modules/vows/lib/vows/reporters/json.js +10 -0
  1185. data/node_modules/jasmine-runner/node_modules/vows/lib/vows/reporters/silent.js +8 -0
  1186. data/node_modules/jasmine-runner/node_modules/vows/lib/vows/reporters/spec.js +74 -0
  1187. data/node_modules/jasmine-runner/node_modules/vows/lib/vows/reporters/watch.js +38 -0
  1188. data/node_modules/jasmine-runner/node_modules/vows/lib/vows/reporters/xunit.js +90 -0
  1189. data/node_modules/jasmine-runner/node_modules/vows/lib/vows/suite.js +321 -0
  1190. data/node_modules/jasmine-runner/node_modules/vows/package.json +14 -0
  1191. data/node_modules/jasmine-runner/node_modules/vows/test/assert-test.js +101 -0
  1192. data/node_modules/jasmine-runner/node_modules/vows/test/vows-test.js +373 -0
  1193. data/node_modules/jasmine-runner/node_modules/webworker/.gitignore +2 -0
  1194. data/node_modules/jasmine-runner/node_modules/webworker/LICENSE +27 -0
  1195. data/node_modules/jasmine-runner/node_modules/webworker/Makefile +15 -0
  1196. data/node_modules/jasmine-runner/node_modules/webworker/README.md +74 -0
  1197. data/node_modules/jasmine-runner/node_modules/webworker/docs/design.md +103 -0
  1198. data/node_modules/jasmine-runner/node_modules/webworker/examples/prefork/README.md +1 -0
  1199. data/node_modules/jasmine-runner/node_modules/webworker/examples/prefork/master.js +12 -0
  1200. data/node_modules/jasmine-runner/node_modules/webworker/examples/prefork/worker.js +20 -0
  1201. data/node_modules/jasmine-runner/node_modules/webworker/lib/webworker-child.js +173 -0
  1202. data/node_modules/jasmine-runner/node_modules/webworker/lib/webworker-util.js +185 -0
  1203. data/node_modules/jasmine-runner/node_modules/webworker/lib/webworker.js +304 -0
  1204. data/node_modules/jasmine-runner/node_modules/webworker/lib/ws.js +118 -0
  1205. data/node_modules/jasmine-runner/node_modules/webworker/lib/ws/connection.js +408 -0
  1206. data/node_modules/jasmine-runner/node_modules/webworker/lib/ws/manager.js +98 -0
  1207. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/LICENSE +27 -0
  1208. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/Makefile +8 -0
  1209. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/README.md +41 -0
  1210. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/examples/client-unix.js +12 -0
  1211. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/examples/client.js +10 -0
  1212. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/examples/server-unix.js +13 -0
  1213. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/lib/websocket.js +516 -0
  1214. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/package.json +22 -0
  1215. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/test/test-basic.js +63 -0
  1216. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/test/test-readonly-attrs.js +44 -0
  1217. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/test/test-ready-state.js +23 -0
  1218. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/test/test-unix-send-fd.js +63 -0
  1219. data/node_modules/jasmine-runner/node_modules/webworker/node_modules/websocket-client/test/test-unix-sockets.js +46 -0
  1220. data/node_modules/jasmine-runner/node_modules/webworker/package.json +25 -0
  1221. data/node_modules/jasmine-runner/node_modules/webworker/test/test-error.js +24 -0
  1222. data/node_modules/jasmine-runner/node_modules/webworker/test/test-fd.js +32 -0
  1223. data/node_modules/jasmine-runner/node_modules/webworker/test/test-simple.js +36 -0
  1224. data/node_modules/jasmine-runner/node_modules/webworker/test/workers/error.js +6 -0
  1225. data/node_modules/jasmine-runner/node_modules/webworker/test/workers/fd.js +17 -0
  1226. data/node_modules/jasmine-runner/node_modules/webworker/test/workers/simple.js +15 -0
  1227. data/node_modules/jasmine-runner/package.json +22 -0
  1228. data/node_modules/jasmine-runner/spec/ConsoleLoggerSpec.js +1 -0
  1229. data/node_modules/jasmine-runner/spec/ServerSpec.js +42 -0
  1230. data/node_modules/jasmine-runner/spec/TestRunner.js +72 -0
  1231. data/node_modules/jasmine-runner/spec/file.worker +8 -0
  1232. data/node_modules/jasmine-runner/spec/temp/spec/foo.spec.js +0 -0
  1233. data/node_modules/jasmine-runner/spec/temp/src/foo.hs +1 -0
  1234. data/node_modules/uglify-js/.gitignore +4 -0
  1235. data/node_modules/uglify-js/README.html +1026 -0
  1236. data/node_modules/uglify-js/README.org +571 -0
  1237. data/node_modules/uglify-js/bin/uglifyjs +317 -0
  1238. data/node_modules/uglify-js/docstyle.css +75 -0
  1239. data/node_modules/uglify-js/lib/object-ast.js +75 -0
  1240. data/node_modules/uglify-js/lib/parse-js.js +1339 -0
  1241. data/node_modules/uglify-js/lib/process.js +2001 -0
  1242. data/node_modules/uglify-js/lib/squeeze-more.js +51 -0
  1243. data/node_modules/uglify-js/package.json +24 -0
  1244. data/node_modules/uglify-js/package.json~ +24 -0
  1245. data/node_modules/uglify-js/test/beautify.js +28 -0
  1246. data/node_modules/uglify-js/test/testparser.js +403 -0
  1247. data/node_modules/uglify-js/test/unit/compress/expected/array1.js +1 -0
  1248. data/node_modules/uglify-js/test/unit/compress/expected/array2.js +1 -0
  1249. data/node_modules/uglify-js/test/unit/compress/expected/array3.js +1 -0
  1250. data/node_modules/uglify-js/test/unit/compress/expected/array4.js +1 -0
  1251. data/node_modules/uglify-js/test/unit/compress/expected/assignment.js +1 -0
  1252. data/node_modules/uglify-js/test/unit/compress/expected/concatstring.js +1 -0
  1253. data/node_modules/uglify-js/test/unit/compress/expected/const.js +1 -0
  1254. data/node_modules/uglify-js/test/unit/compress/expected/empty-blocks.js +1 -0
  1255. data/node_modules/uglify-js/test/unit/compress/expected/forstatement.js +1 -0
  1256. data/node_modules/uglify-js/test/unit/compress/expected/if.js +1 -0
  1257. data/node_modules/uglify-js/test/unit/compress/expected/ifreturn.js +1 -0
  1258. data/node_modules/uglify-js/test/unit/compress/expected/ifreturn2.js +1 -0
  1259. data/node_modules/uglify-js/test/unit/compress/expected/issue10.js +1 -0
  1260. data/node_modules/uglify-js/test/unit/compress/expected/issue11.js +1 -0
  1261. data/node_modules/uglify-js/test/unit/compress/expected/issue13.js +1 -0
  1262. data/node_modules/uglify-js/test/unit/compress/expected/issue14.js +1 -0
  1263. data/node_modules/uglify-js/test/unit/compress/expected/issue16.js +1 -0
  1264. data/node_modules/uglify-js/test/unit/compress/expected/issue17.js +1 -0
  1265. data/node_modules/uglify-js/test/unit/compress/expected/issue20.js +1 -0
  1266. data/node_modules/uglify-js/test/unit/compress/expected/issue21.js +1 -0
  1267. data/node_modules/uglify-js/test/unit/compress/expected/issue25.js +1 -0
  1268. data/node_modules/uglify-js/test/unit/compress/expected/issue27.js +1 -0
  1269. data/node_modules/uglify-js/test/unit/compress/expected/issue28.js +1 -0
  1270. data/node_modules/uglify-js/test/unit/compress/expected/issue29.js +1 -0
  1271. data/node_modules/uglify-js/test/unit/compress/expected/issue30.js +1 -0
  1272. data/node_modules/uglify-js/test/unit/compress/expected/issue34.js +1 -0
  1273. data/node_modules/uglify-js/test/unit/compress/expected/issue4.js +1 -0
  1274. data/node_modules/uglify-js/test/unit/compress/expected/issue48.js +1 -0
  1275. data/node_modules/uglify-js/test/unit/compress/expected/issue50.js +1 -0
  1276. data/node_modules/uglify-js/test/unit/compress/expected/issue53.js +1 -0
  1277. data/node_modules/uglify-js/test/unit/compress/expected/issue54.1.js +1 -0
  1278. data/node_modules/uglify-js/test/unit/compress/expected/issue68.js +1 -0
  1279. data/node_modules/uglify-js/test/unit/compress/expected/issue69.js +1 -0
  1280. data/node_modules/uglify-js/test/unit/compress/expected/issue9.js +1 -0
  1281. data/node_modules/uglify-js/test/unit/compress/expected/mangle.js +1 -0
  1282. data/node_modules/uglify-js/test/unit/compress/expected/null_string.js +1 -0
  1283. data/node_modules/uglify-js/test/unit/compress/expected/strict-equals.js +1 -0
  1284. data/node_modules/uglify-js/test/unit/compress/expected/var.js +1 -0
  1285. data/node_modules/uglify-js/test/unit/compress/expected/whitespace.js +1 -0
  1286. data/node_modules/uglify-js/test/unit/compress/expected/with.js +1 -0
  1287. data/node_modules/uglify-js/test/unit/compress/test/array1.js +3 -0
  1288. data/node_modules/uglify-js/test/unit/compress/test/array2.js +4 -0
  1289. data/node_modules/uglify-js/test/unit/compress/test/array3.js +4 -0
  1290. data/node_modules/uglify-js/test/unit/compress/test/array4.js +6 -0
  1291. data/node_modules/uglify-js/test/unit/compress/test/assignment.js +20 -0
  1292. data/node_modules/uglify-js/test/unit/compress/test/concatstring.js +3 -0
  1293. data/node_modules/uglify-js/test/unit/compress/test/const.js +5 -0
  1294. data/node_modules/uglify-js/test/unit/compress/test/empty-blocks.js +4 -0
  1295. data/node_modules/uglify-js/test/unit/compress/test/forstatement.js +10 -0
  1296. data/node_modules/uglify-js/test/unit/compress/test/if.js +6 -0
  1297. data/node_modules/uglify-js/test/unit/compress/test/ifreturn.js +9 -0
  1298. data/node_modules/uglify-js/test/unit/compress/test/ifreturn2.js +16 -0
  1299. data/node_modules/uglify-js/test/unit/compress/test/issue10.js +1 -0
  1300. data/node_modules/uglify-js/test/unit/compress/test/issue11.js +3 -0
  1301. data/node_modules/uglify-js/test/unit/compress/test/issue13.js +1 -0
  1302. data/node_modules/uglify-js/test/unit/compress/test/issue14.js +1 -0
  1303. data/node_modules/uglify-js/test/unit/compress/test/issue16.js +1 -0
  1304. data/node_modules/uglify-js/test/unit/compress/test/issue17.js +4 -0
  1305. data/node_modules/uglify-js/test/unit/compress/test/issue20.js +1 -0
  1306. data/node_modules/uglify-js/test/unit/compress/test/issue21.js +6 -0
  1307. data/node_modules/uglify-js/test/unit/compress/test/issue25.js +7 -0
  1308. data/node_modules/uglify-js/test/unit/compress/test/issue27.js +1 -0
  1309. data/node_modules/uglify-js/test/unit/compress/test/issue28.js +3 -0
  1310. data/node_modules/uglify-js/test/unit/compress/test/issue29.js +1 -0
  1311. data/node_modules/uglify-js/test/unit/compress/test/issue30.js +3 -0
  1312. data/node_modules/uglify-js/test/unit/compress/test/issue34.js +3 -0
  1313. data/node_modules/uglify-js/test/unit/compress/test/issue4.js +3 -0
  1314. data/node_modules/uglify-js/test/unit/compress/test/issue48.js +1 -0
  1315. data/node_modules/uglify-js/test/unit/compress/test/issue50.js +9 -0
  1316. data/node_modules/uglify-js/test/unit/compress/test/issue53.js +1 -0
  1317. data/node_modules/uglify-js/test/unit/compress/test/issue54.1.js +3 -0
  1318. data/node_modules/uglify-js/test/unit/compress/test/issue68.js +5 -0
  1319. data/node_modules/uglify-js/test/unit/compress/test/issue69.js +1 -0
  1320. data/node_modules/uglify-js/test/unit/compress/test/issue9.js +4 -0
  1321. data/node_modules/uglify-js/test/unit/compress/test/mangle.js +5 -0
  1322. data/node_modules/uglify-js/test/unit/compress/test/null_string.js +1 -0
  1323. data/node_modules/uglify-js/test/unit/compress/test/strict-equals.js +3 -0
  1324. data/node_modules/uglify-js/test/unit/compress/test/var.js +3 -0
  1325. data/node_modules/uglify-js/test/unit/compress/test/whitespace.js +21 -0
  1326. data/node_modules/uglify-js/test/unit/compress/test/with.js +2 -0
  1327. data/node_modules/uglify-js/test/unit/scripts.js +55 -0
  1328. data/node_modules/uglify-js/uglify-js.js +17 -0
  1329. data/node_modules/uglifycss/README.md +21 -0
  1330. data/node_modules/uglifycss/index.js +26 -0
  1331. data/node_modules/uglifycss/package.json +15 -0
  1332. data/node_modules/uglifycss/test.js +43 -0
  1333. data/node_modules/uglifycss/tests.yui.js +42 -0
  1334. data/node_modules/uglifycss/uglifycss +127 -0
  1335. data/node_modules/uglifycss/uglifycss-lib.js +461 -0
  1336. metadata +1383 -0
@@ -0,0 +1,2699 @@
1
+ /* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*-
2
+ * vim: set ts=8 sw=4 et tw=78:
3
+ *
4
+ * ***** BEGIN LICENSE BLOCK *****
5
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
6
+ *
7
+ * The contents of this file are subject to the Mozilla Public License Version
8
+ * 1.1 (the "License"); you may not use this file except in compliance with
9
+ * the License. You may obtain a copy of the License at
10
+ * http://www.mozilla.org/MPL/
11
+ *
12
+ * Software distributed under the License is distributed on an "AS IS" basis,
13
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
14
+ * for the specific language governing rights and limitations under the
15
+ * License.
16
+ *
17
+ * The Original Code is Mozilla Communicator client code, released
18
+ * March 31, 1998.
19
+ *
20
+ * The Initial Developer of the Original Code is
21
+ * Netscape Communications Corporation.
22
+ * Portions created by the Initial Developer are Copyright (C) 1998
23
+ * the Initial Developer. All Rights Reserved.
24
+ *
25
+ * Contributor(s):
26
+ *
27
+ * Alternatively, the contents of this file may be used under the terms of
28
+ * either of the GNU General Public License Version 2 or later (the "GPL"),
29
+ * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
30
+ * in which case the provisions of the GPL or the LGPL are applicable instead
31
+ * of those above. If you wish to allow use of your version of this file only
32
+ * under the terms of either the GPL or the LGPL, and not to allow others to
33
+ * use your version of this file under the terms of the MPL, indicate your
34
+ * decision by deleting the provisions above and replace them with the notice
35
+ * and other provisions required by the GPL or the LGPL. If you do not delete
36
+ * the provisions above, a recipient may use your version of this file under
37
+ * the terms of any one of the MPL, the GPL or the LGPL.
38
+ *
39
+ * ***** END LICENSE BLOCK ***** */
40
+
41
+ #ifndef jsapi_h___
42
+ #define jsapi_h___
43
+ /*
44
+ * JavaScript API.
45
+ */
46
+ #include <stddef.h>
47
+ #include <stdio.h>
48
+ #include "js-config.h"
49
+ #include "jspubtd.h"
50
+ #include "jsutil.h"
51
+
52
+ JS_BEGIN_EXTERN_C
53
+
54
+ /*
55
+ * Type tags stored in the low bits of a jsval.
56
+ */
57
+ #define JSVAL_OBJECT 0x0 /* untagged reference to object */
58
+ #define JSVAL_INT 0x1 /* tagged 31-bit integer value */
59
+ #define JSVAL_DOUBLE 0x2 /* tagged reference to double */
60
+ #define JSVAL_STRING 0x4 /* tagged reference to string */
61
+ #define JSVAL_BOOLEAN 0x6 /* tagged boolean value */
62
+
63
+ /* Type tag bitfield length and derived macros. */
64
+ #define JSVAL_TAGBITS 3
65
+ #define JSVAL_TAGMASK JS_BITMASK(JSVAL_TAGBITS)
66
+ #define JSVAL_TAG(v) ((v) & JSVAL_TAGMASK)
67
+ #define JSVAL_SETTAG(v,t) ((v) | (t))
68
+ #define JSVAL_CLRTAG(v) ((v) & ~(jsval)JSVAL_TAGMASK)
69
+ #define JSVAL_ALIGN JS_BIT(JSVAL_TAGBITS)
70
+
71
+ /* Predicates for type testing. */
72
+ #define JSVAL_IS_OBJECT(v) (JSVAL_TAG(v) == JSVAL_OBJECT)
73
+ #define JSVAL_IS_NUMBER(v) (JSVAL_IS_INT(v) || JSVAL_IS_DOUBLE(v))
74
+ #define JSVAL_IS_INT(v) ((v) & JSVAL_INT)
75
+ #define JSVAL_IS_DOUBLE(v) (JSVAL_TAG(v) == JSVAL_DOUBLE)
76
+ #define JSVAL_IS_STRING(v) (JSVAL_TAG(v) == JSVAL_STRING)
77
+ #define JSVAL_IS_BOOLEAN(v) (((v) & ~((jsval)1 << JSVAL_TAGBITS)) == \
78
+ JSVAL_BOOLEAN)
79
+ #define JSVAL_IS_NULL(v) ((v) == JSVAL_NULL)
80
+ #define JSVAL_IS_VOID(v) ((v) == JSVAL_VOID)
81
+ #define JSVAL_IS_PRIMITIVE(v) (!JSVAL_IS_OBJECT(v) || JSVAL_IS_NULL(v))
82
+
83
+ /* Objects, strings, and doubles are GC'ed. */
84
+ #define JSVAL_IS_GCTHING(v) (!((v) & JSVAL_INT) && \
85
+ JSVAL_TAG(v) != JSVAL_BOOLEAN)
86
+ #define JSVAL_TO_GCTHING(v) ((void *)JSVAL_CLRTAG(v))
87
+ #define JSVAL_TO_OBJECT(v) ((JSObject *)JSVAL_TO_GCTHING(v))
88
+ #define JSVAL_TO_DOUBLE(v) ((jsdouble *)JSVAL_TO_GCTHING(v))
89
+ #define JSVAL_TO_STRING(v) ((JSString *)JSVAL_TO_GCTHING(v))
90
+ #define OBJECT_TO_JSVAL(obj) ((jsval)(obj))
91
+ #define DOUBLE_TO_JSVAL(dp) JSVAL_SETTAG((jsval)(dp), JSVAL_DOUBLE)
92
+ #define STRING_TO_JSVAL(str) JSVAL_SETTAG((jsval)(str), JSVAL_STRING)
93
+
94
+ /* Lock and unlock the GC thing held by a jsval. */
95
+ #define JSVAL_LOCK(cx,v) (JSVAL_IS_GCTHING(v) \
96
+ ? JS_LockGCThing(cx, JSVAL_TO_GCTHING(v)) \
97
+ : JS_TRUE)
98
+ #define JSVAL_UNLOCK(cx,v) (JSVAL_IS_GCTHING(v) \
99
+ ? JS_UnlockGCThing(cx, JSVAL_TO_GCTHING(v)) \
100
+ : JS_TRUE)
101
+
102
+ /* Domain limits for the jsval int type. */
103
+ #define JSVAL_INT_BITS 31
104
+ #define JSVAL_INT_POW2(n) ((jsval)1 << (n))
105
+ #define JSVAL_INT_MIN (-JSVAL_INT_POW2(30))
106
+ #define JSVAL_INT_MAX (JSVAL_INT_POW2(30) - 1)
107
+ #define INT_FITS_IN_JSVAL(i) ((jsuint)(i) - (jsuint)JSVAL_INT_MIN <= \
108
+ (jsuint)(JSVAL_INT_MAX - JSVAL_INT_MIN))
109
+ #define JSVAL_TO_INT(v) ((jsint)(v) >> 1)
110
+ #define INT_TO_JSVAL(i) (((jsval)(i) << 1) | JSVAL_INT)
111
+
112
+ /* Convert between boolean and jsval. */
113
+ #define JSVAL_TO_BOOLEAN(v) ((JSBool)((v) >> JSVAL_TAGBITS))
114
+ #define BOOLEAN_TO_JSVAL(b) JSVAL_SETTAG((jsval)(b) << JSVAL_TAGBITS, \
115
+ JSVAL_BOOLEAN)
116
+
117
+ /* A private data pointer (2-byte-aligned) can be stored as an int jsval. */
118
+ #define JSVAL_TO_PRIVATE(v) ((void *)((v) & ~JSVAL_INT))
119
+ #define PRIVATE_TO_JSVAL(p) ((jsval)(p) | JSVAL_INT)
120
+
121
+ /* Property attributes, set in JSPropertySpec and passed to API functions. */
122
+ #define JSPROP_ENUMERATE 0x01 /* property is visible to for/in loop */
123
+ #define JSPROP_READONLY 0x02 /* not settable: assignment is no-op */
124
+ #define JSPROP_PERMANENT 0x04 /* property cannot be deleted */
125
+ #define JSPROP_GETTER 0x10 /* property holds getter function */
126
+ #define JSPROP_SETTER 0x20 /* property holds setter function */
127
+ #define JSPROP_SHARED 0x40 /* don't allocate a value slot for this
128
+ property; don't copy the property on
129
+ set of the same-named property in an
130
+ object that delegates to a prototype
131
+ containing this property */
132
+ #define JSPROP_INDEX 0x80 /* name is actually (jsint) index */
133
+
134
+ /* Function flags, set in JSFunctionSpec and passed to JS_NewFunction etc. */
135
+ #define JSFUN_LAMBDA 0x08 /* expressed, not declared, function */
136
+ #define JSFUN_GETTER JSPROP_GETTER
137
+ #define JSFUN_SETTER JSPROP_SETTER
138
+ #define JSFUN_BOUND_METHOD 0x40 /* bind this to fun->object's parent */
139
+ #define JSFUN_HEAVYWEIGHT 0x80 /* activation requires a Call object */
140
+
141
+ #define JSFUN_DISJOINT_FLAGS(f) ((f) & 0x0f)
142
+ #define JSFUN_GSFLAGS(f) ((f) & (JSFUN_GETTER | JSFUN_SETTER))
143
+
144
+ #define JSFUN_GETTER_TEST(f) ((f) & JSFUN_GETTER)
145
+ #define JSFUN_SETTER_TEST(f) ((f) & JSFUN_SETTER)
146
+ #define JSFUN_BOUND_METHOD_TEST(f) ((f) & JSFUN_BOUND_METHOD)
147
+ #define JSFUN_HEAVYWEIGHT_TEST(f) ((f) & JSFUN_HEAVYWEIGHT)
148
+
149
+ #define JSFUN_GSFLAG2ATTR(f) JSFUN_GSFLAGS(f)
150
+
151
+ #define JSFUN_THISP_FLAGS(f) (f)
152
+ #define JSFUN_THISP_TEST(f,t) ((f) & t)
153
+
154
+ #define JSFUN_THISP_STRING 0x0100 /* |this| may be a primitive string */
155
+ #define JSFUN_THISP_NUMBER 0x0200 /* |this| may be a primitive number */
156
+ #define JSFUN_THISP_BOOLEAN 0x0400 /* |this| may be a primitive boolean */
157
+ #define JSFUN_THISP_PRIMITIVE 0x0700 /* |this| may be any primitive value */
158
+
159
+ #define JSFUN_FAST_NATIVE 0x0800 /* JSFastNative needs no JSStackFrame */
160
+
161
+ #define JSFUN_FLAGS_MASK 0x0ff8 /* overlay JSFUN_* attributes --
162
+ note that bit #15 is used internally
163
+ to flag interpreted functions */
164
+
165
+ #define JSFUN_STUB_GSOPS 0x1000 /* use JS_PropertyStub getter/setter
166
+ instead of defaulting to class gsops
167
+ for property holding function */
168
+
169
+ /*
170
+ * Re-use JSFUN_LAMBDA, which applies only to scripted functions, for use in
171
+ * JSFunctionSpec arrays that specify generic native prototype methods, i.e.,
172
+ * methods of a class prototype that are exposed as static methods taking an
173
+ * extra leading argument: the generic |this| parameter.
174
+ *
175
+ * If you set this flag in a JSFunctionSpec struct's flags initializer, then
176
+ * that struct must live at least as long as the native static method object
177
+ * created due to this flag by JS_DefineFunctions or JS_InitClass. Typically
178
+ * JSFunctionSpec structs are allocated in static arrays.
179
+ */
180
+ #define JSFUN_GENERIC_NATIVE JSFUN_LAMBDA
181
+
182
+ /*
183
+ * Well-known JS values. The extern'd variables are initialized when the
184
+ * first JSContext is created by JS_NewContext (see below).
185
+ */
186
+ #define JSVAL_VOID BOOLEAN_TO_JSVAL(2)
187
+ #define JSVAL_NULL OBJECT_TO_JSVAL(0)
188
+ #define JSVAL_ZERO INT_TO_JSVAL(0)
189
+ #define JSVAL_ONE INT_TO_JSVAL(1)
190
+ #define JSVAL_FALSE BOOLEAN_TO_JSVAL(JS_FALSE)
191
+ #define JSVAL_TRUE BOOLEAN_TO_JSVAL(JS_TRUE)
192
+
193
+ /*
194
+ * Microseconds since the epoch, midnight, January 1, 1970 UTC. See the
195
+ * comment in jstypes.h regarding safe int64 usage.
196
+ */
197
+ extern JS_PUBLIC_API(int64)
198
+ JS_Now(void);
199
+
200
+ /* Don't want to export data, so provide accessors for non-inline jsvals. */
201
+ extern JS_PUBLIC_API(jsval)
202
+ JS_GetNaNValue(JSContext *cx);
203
+
204
+ extern JS_PUBLIC_API(jsval)
205
+ JS_GetNegativeInfinityValue(JSContext *cx);
206
+
207
+ extern JS_PUBLIC_API(jsval)
208
+ JS_GetPositiveInfinityValue(JSContext *cx);
209
+
210
+ extern JS_PUBLIC_API(jsval)
211
+ JS_GetEmptyStringValue(JSContext *cx);
212
+
213
+ /*
214
+ * Format is a string of the following characters (spaces are insignificant),
215
+ * specifying the tabulated type conversions:
216
+ *
217
+ * b JSBool Boolean
218
+ * c uint16/jschar ECMA uint16, Unicode char
219
+ * i int32 ECMA int32
220
+ * u uint32 ECMA uint32
221
+ * j int32 Rounded int32 (coordinate)
222
+ * d jsdouble IEEE double
223
+ * I jsdouble Integral IEEE double
224
+ * s char * C string
225
+ * S JSString * Unicode string, accessed by a JSString pointer
226
+ * W jschar * Unicode character vector, 0-terminated (W for wide)
227
+ * o JSObject * Object reference
228
+ * f JSFunction * Function private
229
+ * v jsval Argument value (no conversion)
230
+ * * N/A Skip this argument (no vararg)
231
+ * / N/A End of required arguments
232
+ *
233
+ * The variable argument list after format must consist of &b, &c, &s, e.g.,
234
+ * where those variables have the types given above. For the pointer types
235
+ * char *, JSString *, and JSObject *, the pointed-at memory returned belongs
236
+ * to the JS runtime, not to the calling native code. The runtime promises
237
+ * to keep this memory valid so long as argv refers to allocated stack space
238
+ * (so long as the native function is active).
239
+ *
240
+ * Fewer arguments than format specifies may be passed only if there is a /
241
+ * in format after the last required argument specifier and argc is at least
242
+ * the number of required arguments. More arguments than format specifies
243
+ * may be passed without error; it is up to the caller to deal with trailing
244
+ * unconverted arguments.
245
+ */
246
+ extern JS_PUBLIC_API(JSBool)
247
+ JS_ConvertArguments(JSContext *cx, uintN argc, jsval *argv, const char *format,
248
+ ...);
249
+
250
+ #ifdef va_start
251
+ extern JS_PUBLIC_API(JSBool)
252
+ JS_ConvertArgumentsVA(JSContext *cx, uintN argc, jsval *argv,
253
+ const char *format, va_list ap);
254
+ #endif
255
+
256
+ /*
257
+ * Inverse of JS_ConvertArguments: scan format and convert trailing arguments
258
+ * into jsvals, GC-rooted if necessary by the JS stack. Return null on error,
259
+ * and a pointer to the new argument vector on success. Also return a stack
260
+ * mark on success via *markp, in which case the caller must eventually clean
261
+ * up by calling JS_PopArguments.
262
+ *
263
+ * Note that the number of actual arguments supplied is specified exclusively
264
+ * by format, so there is no argc parameter.
265
+ */
266
+ extern JS_PUBLIC_API(jsval *)
267
+ JS_PushArguments(JSContext *cx, void **markp, const char *format, ...);
268
+
269
+ #ifdef va_start
270
+ extern JS_PUBLIC_API(jsval *)
271
+ JS_PushArgumentsVA(JSContext *cx, void **markp, const char *format, va_list ap);
272
+ #endif
273
+
274
+ extern JS_PUBLIC_API(void)
275
+ JS_PopArguments(JSContext *cx, void *mark);
276
+
277
+ #ifdef JS_ARGUMENT_FORMATTER_DEFINED
278
+
279
+ /*
280
+ * Add and remove a format string handler for JS_{Convert,Push}Arguments{,VA}.
281
+ * The handler function has this signature (see jspubtd.h):
282
+ *
283
+ * JSBool MyArgumentFormatter(JSContext *cx, const char *format,
284
+ * JSBool fromJS, jsval **vpp, va_list *app);
285
+ *
286
+ * It should return true on success, and return false after reporting an error
287
+ * or detecting an already-reported error.
288
+ *
289
+ * For a given format string, for example "AA", the formatter is called from
290
+ * JS_ConvertArgumentsVA like so:
291
+ *
292
+ * formatter(cx, "AA...", JS_TRUE, &sp, &ap);
293
+ *
294
+ * sp points into the arguments array on the JS stack, while ap points into
295
+ * the stdarg.h va_list on the C stack. The JS_TRUE passed for fromJS tells
296
+ * the formatter to convert zero or more jsvals at sp to zero or more C values
297
+ * accessed via pointers-to-values at ap, updating both sp (via *vpp) and ap
298
+ * (via *app) to point past the converted arguments and their result pointers
299
+ * on the C stack.
300
+ *
301
+ * When called from JS_PushArgumentsVA, the formatter is invoked thus:
302
+ *
303
+ * formatter(cx, "AA...", JS_FALSE, &sp, &ap);
304
+ *
305
+ * where JS_FALSE for fromJS means to wrap the C values at ap according to the
306
+ * format specifier and store them at sp, updating ap and sp appropriately.
307
+ *
308
+ * The "..." after "AA" is the rest of the format string that was passed into
309
+ * JS_{Convert,Push}Arguments{,VA}. The actual format trailing substring used
310
+ * in each Convert or PushArguments call is passed to the formatter, so that
311
+ * one such function may implement several formats, in order to share code.
312
+ *
313
+ * Remove just forgets about any handler associated with format. Add does not
314
+ * copy format, it points at the string storage allocated by the caller, which
315
+ * is typically a string constant. If format is in dynamic storage, it is up
316
+ * to the caller to keep the string alive until Remove is called.
317
+ */
318
+ extern JS_PUBLIC_API(JSBool)
319
+ JS_AddArgumentFormatter(JSContext *cx, const char *format,
320
+ JSArgumentFormatter formatter);
321
+
322
+ extern JS_PUBLIC_API(void)
323
+ JS_RemoveArgumentFormatter(JSContext *cx, const char *format);
324
+
325
+ #endif /* JS_ARGUMENT_FORMATTER_DEFINED */
326
+
327
+ extern JS_PUBLIC_API(JSBool)
328
+ JS_ConvertValue(JSContext *cx, jsval v, JSType type, jsval *vp);
329
+
330
+ extern JS_PUBLIC_API(JSBool)
331
+ JS_ValueToObject(JSContext *cx, jsval v, JSObject **objp);
332
+
333
+ extern JS_PUBLIC_API(JSFunction *)
334
+ JS_ValueToFunction(JSContext *cx, jsval v);
335
+
336
+ extern JS_PUBLIC_API(JSFunction *)
337
+ JS_ValueToConstructor(JSContext *cx, jsval v);
338
+
339
+ extern JS_PUBLIC_API(JSString *)
340
+ JS_ValueToString(JSContext *cx, jsval v);
341
+
342
+ extern JS_PUBLIC_API(JSString *)
343
+ JS_ValueToSource(JSContext *cx, jsval v);
344
+
345
+ extern JS_PUBLIC_API(JSBool)
346
+ JS_ValueToNumber(JSContext *cx, jsval v, jsdouble *dp);
347
+
348
+ /*
349
+ * Convert a value to a number, then to an int32, according to the ECMA rules
350
+ * for ToInt32.
351
+ */
352
+ extern JS_PUBLIC_API(JSBool)
353
+ JS_ValueToECMAInt32(JSContext *cx, jsval v, int32 *ip);
354
+
355
+ /*
356
+ * Convert a value to a number, then to a uint32, according to the ECMA rules
357
+ * for ToUint32.
358
+ */
359
+ extern JS_PUBLIC_API(JSBool)
360
+ JS_ValueToECMAUint32(JSContext *cx, jsval v, uint32 *ip);
361
+
362
+ /*
363
+ * Convert a value to a number, then to an int32 if it fits by rounding to
364
+ * nearest; but failing with an error report if the double is out of range
365
+ * or unordered.
366
+ */
367
+ extern JS_PUBLIC_API(JSBool)
368
+ JS_ValueToInt32(JSContext *cx, jsval v, int32 *ip);
369
+
370
+ /*
371
+ * ECMA ToUint16, for mapping a jsval to a Unicode point.
372
+ */
373
+ extern JS_PUBLIC_API(JSBool)
374
+ JS_ValueToUint16(JSContext *cx, jsval v, uint16 *ip);
375
+
376
+ extern JS_PUBLIC_API(JSBool)
377
+ JS_ValueToBoolean(JSContext *cx, jsval v, JSBool *bp);
378
+
379
+ extern JS_PUBLIC_API(JSType)
380
+ JS_TypeOfValue(JSContext *cx, jsval v);
381
+
382
+ extern JS_PUBLIC_API(const char *)
383
+ JS_GetTypeName(JSContext *cx, JSType type);
384
+
385
+ /************************************************************************/
386
+
387
+ /*
388
+ * Initialization, locking, contexts, and memory allocation.
389
+ *
390
+ * It is important that the first runtime and first context be created in a
391
+ * single-threaded fashion, otherwise the behavior of the library is undefined.
392
+ * See: http://developer.mozilla.org/en/docs/Category:JSAPI_Reference
393
+ */
394
+ #define JS_NewRuntime JS_Init
395
+ #define JS_DestroyRuntime JS_Finish
396
+ #define JS_LockRuntime JS_Lock
397
+ #define JS_UnlockRuntime JS_Unlock
398
+
399
+ extern JS_PUBLIC_API(JSRuntime *)
400
+ JS_NewRuntime(uint32 maxbytes);
401
+
402
+ extern JS_PUBLIC_API(void)
403
+ JS_DestroyRuntime(JSRuntime *rt);
404
+
405
+ extern JS_PUBLIC_API(void)
406
+ JS_ShutDown(void);
407
+
408
+ JS_PUBLIC_API(void *)
409
+ JS_GetRuntimePrivate(JSRuntime *rt);
410
+
411
+ JS_PUBLIC_API(void)
412
+ JS_SetRuntimePrivate(JSRuntime *rt, void *data);
413
+
414
+ extern JS_PUBLIC_API(void)
415
+ JS_BeginRequest(JSContext *cx);
416
+
417
+ extern JS_PUBLIC_API(void)
418
+ JS_EndRequest(JSContext *cx);
419
+
420
+ /* Yield to pending GC operations, regardless of request depth */
421
+ extern JS_PUBLIC_API(void)
422
+ JS_YieldRequest(JSContext *cx);
423
+
424
+ extern JS_PUBLIC_API(jsrefcount)
425
+ JS_SuspendRequest(JSContext *cx);
426
+
427
+ extern JS_PUBLIC_API(void)
428
+ JS_ResumeRequest(JSContext *cx, jsrefcount saveDepth);
429
+
430
+ #ifdef __cplusplus
431
+ JS_END_EXTERN_C
432
+
433
+ class JSAutoRequest {
434
+ public:
435
+ JSAutoRequest(JSContext *cx) : mContext(cx), mSaveDepth(0) {
436
+ JS_BeginRequest(mContext);
437
+ }
438
+ ~JSAutoRequest() {
439
+ JS_EndRequest(mContext);
440
+ }
441
+
442
+ void suspend() {
443
+ mSaveDepth = JS_SuspendRequest(mContext);
444
+ }
445
+ void resume() {
446
+ JS_ResumeRequest(mContext, mSaveDepth);
447
+ }
448
+
449
+ protected:
450
+ JSContext *mContext;
451
+ jsrefcount mSaveDepth;
452
+
453
+ #if 0
454
+ private:
455
+ static void *operator new(size_t) CPP_THROW_NEW { return 0; };
456
+ static void operator delete(void *, size_t) { };
457
+ #endif
458
+ };
459
+
460
+ class JSAutoSuspendRequest {
461
+ public:
462
+ JSAutoSuspendRequest(JSContext *cx) : mContext(cx), mSaveDepth(0) {
463
+ if (mContext) {
464
+ mSaveDepth = JS_SuspendRequest(mContext);
465
+ }
466
+ }
467
+ ~JSAutoSuspendRequest() {
468
+ resume();
469
+ }
470
+
471
+ void resume() {
472
+ if (mContext) {
473
+ JS_ResumeRequest(mContext, mSaveDepth);
474
+ mContext = 0;
475
+ }
476
+ }
477
+
478
+ protected:
479
+ JSContext *mContext;
480
+ jsrefcount mSaveDepth;
481
+
482
+ #if 0
483
+ private:
484
+ static void *operator new(size_t) CPP_THROW_NEW { return 0; };
485
+ static void operator delete(void *, size_t) { };
486
+ #endif
487
+ };
488
+
489
+ JS_BEGIN_EXTERN_C
490
+ #endif
491
+
492
+ extern JS_PUBLIC_API(void)
493
+ JS_Lock(JSRuntime *rt);
494
+
495
+ extern JS_PUBLIC_API(void)
496
+ JS_Unlock(JSRuntime *rt);
497
+
498
+ extern JS_PUBLIC_API(JSContextCallback)
499
+ JS_SetContextCallback(JSRuntime *rt, JSContextCallback cxCallback);
500
+
501
+ extern JS_PUBLIC_API(JSContext *)
502
+ JS_NewContext(JSRuntime *rt, size_t stackChunkSize);
503
+
504
+ extern JS_PUBLIC_API(void)
505
+ JS_DestroyContext(JSContext *cx);
506
+
507
+ extern JS_PUBLIC_API(void)
508
+ JS_DestroyContextNoGC(JSContext *cx);
509
+
510
+ extern JS_PUBLIC_API(void)
511
+ JS_DestroyContextMaybeGC(JSContext *cx);
512
+
513
+ extern JS_PUBLIC_API(void *)
514
+ JS_GetContextPrivate(JSContext *cx);
515
+
516
+ extern JS_PUBLIC_API(void)
517
+ JS_SetContextPrivate(JSContext *cx, void *data);
518
+
519
+ extern JS_PUBLIC_API(JSRuntime *)
520
+ JS_GetRuntime(JSContext *cx);
521
+
522
+ extern JS_PUBLIC_API(JSContext *)
523
+ JS_ContextIterator(JSRuntime *rt, JSContext **iterp);
524
+
525
+ extern JS_PUBLIC_API(JSVersion)
526
+ JS_GetVersion(JSContext *cx);
527
+
528
+ extern JS_PUBLIC_API(JSVersion)
529
+ JS_SetVersion(JSContext *cx, JSVersion version);
530
+
531
+ extern JS_PUBLIC_API(const char *)
532
+ JS_VersionToString(JSVersion version);
533
+
534
+ extern JS_PUBLIC_API(JSVersion)
535
+ JS_StringToVersion(const char *string);
536
+
537
+ /*
538
+ * JS options are orthogonal to version, and may be freely composed with one
539
+ * another as well as with version.
540
+ *
541
+ * JSOPTION_VAROBJFIX is recommended -- see the comments associated with the
542
+ * prototypes for JS_ExecuteScript, JS_EvaluateScript, etc.
543
+ */
544
+ #define JSOPTION_STRICT JS_BIT(0) /* warn on dubious practice */
545
+ #define JSOPTION_WERROR JS_BIT(1) /* convert warning to error */
546
+ #define JSOPTION_VAROBJFIX JS_BIT(2) /* make JS_EvaluateScript use
547
+ the last object on its 'obj'
548
+ param's scope chain as the
549
+ ECMA 'variables object' */
550
+ #define JSOPTION_PRIVATE_IS_NSISUPPORTS \
551
+ JS_BIT(3) /* context private data points
552
+ to an nsISupports subclass */
553
+ #define JSOPTION_COMPILE_N_GO JS_BIT(4) /* caller of JS_Compile*Script
554
+ promises to execute compiled
555
+ script once only; enables
556
+ compile-time scope chain
557
+ resolution of consts. */
558
+ #define JSOPTION_ATLINE JS_BIT(5) /* //@line number ["filename"]
559
+ option supported for the
560
+ XUL preprocessor and kindred
561
+ beasts. */
562
+ #define JSOPTION_XML JS_BIT(6) /* EMCAScript for XML support:
563
+ parse <!-- --> as a token,
564
+ not backward compatible with
565
+ the comment-hiding hack used
566
+ in HTML script tags. */
567
+ #define JSOPTION_NATIVE_BRANCH_CALLBACK \
568
+ JS_BIT(7) /* the branch callback set by
569
+ JS_SetBranchCallback may be
570
+ called with a null script
571
+ parameter, by native code
572
+ that loops intensively.
573
+ Deprecated, use
574
+ JS_SetOperationCallback
575
+ instead */
576
+ #define JSOPTION_DONT_REPORT_UNCAUGHT \
577
+ JS_BIT(8) /* When returning from the
578
+ outermost API call, prevent
579
+ uncaught exceptions from
580
+ being converted to error
581
+ reports */
582
+
583
+ #define JSOPTION_RELIMIT JS_BIT(9) /* Throw exception on any
584
+ regular expression which
585
+ backtracks more than n^3
586
+ times, where n is length
587
+ of the input string */
588
+ #define JSOPTION_ANONFUNFIX JS_BIT(10) /* Disallow function () {} in
589
+ statement context per
590
+ ECMA-262 Edition 3. */
591
+
592
+ #define JSOPTION_JIT JS_BIT(11) /* Enable JIT compilation. */
593
+
594
+ #define JSOPTION_NO_SCRIPT_RVAL JS_BIT(12) /* A promise to the compiler
595
+ that a null rval out-param
596
+ will be passed to each call
597
+ to JS_ExecuteScript. */
598
+
599
+ extern JS_PUBLIC_API(uint32)
600
+ JS_GetOptions(JSContext *cx);
601
+
602
+ extern JS_PUBLIC_API(uint32)
603
+ JS_SetOptions(JSContext *cx, uint32 options);
604
+
605
+ extern JS_PUBLIC_API(uint32)
606
+ JS_ToggleOptions(JSContext *cx, uint32 options);
607
+
608
+ extern JS_PUBLIC_API(const char *)
609
+ JS_GetImplementationVersion(void);
610
+
611
+ extern JS_PUBLIC_API(JSObject *)
612
+ JS_GetGlobalObject(JSContext *cx);
613
+
614
+ extern JS_PUBLIC_API(void)
615
+ JS_SetGlobalObject(JSContext *cx, JSObject *obj);
616
+
617
+ /*
618
+ * Initialize standard JS class constructors, prototypes, and any top-level
619
+ * functions and constants associated with the standard classes (e.g. isNaN
620
+ * for Number).
621
+ *
622
+ * NB: This sets cx's global object to obj if it was null.
623
+ */
624
+ extern JS_PUBLIC_API(JSBool)
625
+ JS_InitStandardClasses(JSContext *cx, JSObject *obj);
626
+
627
+ /*
628
+ * Resolve id, which must contain either a string or an int, to a standard
629
+ * class name in obj if possible, defining the class's constructor and/or
630
+ * prototype and storing true in *resolved. If id does not name a standard
631
+ * class or a top-level property induced by initializing a standard class,
632
+ * store false in *resolved and just return true. Return false on error,
633
+ * as usual for JSBool result-typed API entry points.
634
+ *
635
+ * This API can be called directly from a global object class's resolve op,
636
+ * to define standard classes lazily. The class's enumerate op should call
637
+ * JS_EnumerateStandardClasses(cx, obj), to define eagerly during for..in
638
+ * loops any classes not yet resolved lazily.
639
+ */
640
+ extern JS_PUBLIC_API(JSBool)
641
+ JS_ResolveStandardClass(JSContext *cx, JSObject *obj, jsval id,
642
+ JSBool *resolved);
643
+
644
+ extern JS_PUBLIC_API(JSBool)
645
+ JS_EnumerateStandardClasses(JSContext *cx, JSObject *obj);
646
+
647
+ /*
648
+ * Enumerate any already-resolved standard class ids into ida, or into a new
649
+ * JSIdArray if ida is null. Return the augmented array on success, null on
650
+ * failure with ida (if it was non-null on entry) destroyed.
651
+ */
652
+ extern JS_PUBLIC_API(JSIdArray *)
653
+ JS_EnumerateResolvedStandardClasses(JSContext *cx, JSObject *obj,
654
+ JSIdArray *ida);
655
+
656
+ extern JS_PUBLIC_API(JSBool)
657
+ JS_GetClassObject(JSContext *cx, JSObject *obj, JSProtoKey key,
658
+ JSObject **objp);
659
+
660
+ extern JS_PUBLIC_API(JSObject *)
661
+ JS_GetScopeChain(JSContext *cx);
662
+
663
+ extern JS_PUBLIC_API(JSObject *)
664
+ JS_GetGlobalForObject(JSContext *cx, JSObject *obj);
665
+
666
+ /*
667
+ * Macros to hide interpreter stack layout details from a JSFastNative using
668
+ * its jsval *vp parameter. The stack layout underlying invocation can't change
669
+ * without breaking source and binary compatibility (argv[-2] is well-known to
670
+ * be the callee jsval, and argv[-1] is as well known to be |this|).
671
+ *
672
+ * Note well: However, argv[-1] may be JSVAL_NULL where with slow natives it
673
+ * is the global object, so embeddings implementing fast natives *must* call
674
+ * JS_THIS or JS_THIS_OBJECT and test for failure indicated by a null return,
675
+ * which should propagate as a false return from native functions and hooks.
676
+ *
677
+ * To reduce boilerplace checks, JS_InstanceOf and JS_GetInstancePrivate now
678
+ * handle a null obj parameter by returning false (throwing a TypeError if
679
+ * given non-null argv), so most native functions that type-check their |this|
680
+ * parameter need not add null checking.
681
+ *
682
+ * NB: there is an anti-dependency between JS_CALLEE and JS_SET_RVAL: native
683
+ * methods that may inspect their callee must defer setting their return value
684
+ * until after any such possible inspection. Otherwise the return value will be
685
+ * inspected instead of the callee function object.
686
+ *
687
+ * WARNING: These are not (yet) mandatory macros, but new code outside of the
688
+ * engine should use them. In the Mozilla 2.0 milestone their definitions may
689
+ * change incompatibly.
690
+ */
691
+ #define JS_CALLEE(cx,vp) ((vp)[0])
692
+ #define JS_ARGV_CALLEE(argv) ((argv)[-2])
693
+ #define JS_THIS(cx,vp) JS_ComputeThis(cx, vp)
694
+ #define JS_THIS_OBJECT(cx,vp) ((JSObject *) JS_THIS(cx,vp))
695
+ #define JS_ARGV(cx,vp) ((vp) + 2)
696
+ #define JS_RVAL(cx,vp) (*(vp))
697
+ #define JS_SET_RVAL(cx,vp,v) (*(vp) = (v))
698
+
699
+ extern JS_PUBLIC_API(jsval)
700
+ JS_ComputeThis(JSContext *cx, jsval *vp);
701
+
702
+ extern JS_PUBLIC_API(void *)
703
+ JS_malloc(JSContext *cx, size_t nbytes);
704
+
705
+ extern JS_PUBLIC_API(void *)
706
+ JS_realloc(JSContext *cx, void *p, size_t nbytes);
707
+
708
+ extern JS_PUBLIC_API(void)
709
+ JS_free(JSContext *cx, void *p);
710
+
711
+ extern JS_PUBLIC_API(char *)
712
+ JS_strdup(JSContext *cx, const char *s);
713
+
714
+ extern JS_PUBLIC_API(jsdouble *)
715
+ JS_NewDouble(JSContext *cx, jsdouble d);
716
+
717
+ extern JS_PUBLIC_API(JSBool)
718
+ JS_NewDoubleValue(JSContext *cx, jsdouble d, jsval *rval);
719
+
720
+ extern JS_PUBLIC_API(JSBool)
721
+ JS_NewNumberValue(JSContext *cx, jsdouble d, jsval *rval);
722
+
723
+ /*
724
+ * A JS GC root is a pointer to a JSObject *, JSString *, or jsdouble * that
725
+ * itself points into the GC heap (more recently, we support this extension:
726
+ * a root may be a pointer to a jsval v for which JSVAL_IS_GCTHING(v) is true).
727
+ *
728
+ * Therefore, you never pass JSObject *obj to JS_AddRoot(cx, obj). You always
729
+ * call JS_AddRoot(cx, &obj), passing obj by reference. And later, before obj
730
+ * or the structure it is embedded within goes out of scope or is freed, you
731
+ * must call JS_RemoveRoot(cx, &obj).
732
+ *
733
+ * Also, use JS_AddNamedRoot(cx, &structPtr->memberObj, "structPtr->memberObj")
734
+ * in preference to JS_AddRoot(cx, &structPtr->memberObj), in order to identify
735
+ * roots by their source callsites. This way, you can find the callsite while
736
+ * debugging if you should fail to do JS_RemoveRoot(cx, &structPtr->memberObj)
737
+ * before freeing structPtr's memory.
738
+ */
739
+ extern JS_PUBLIC_API(JSBool)
740
+ JS_AddRoot(JSContext *cx, void *rp);
741
+
742
+ #ifdef NAME_ALL_GC_ROOTS
743
+ #define JS_DEFINE_TO_TOKEN(def) #def
744
+ #define JS_DEFINE_TO_STRING(def) JS_DEFINE_TO_TOKEN(def)
745
+ #define JS_AddRoot(cx,rp) JS_AddNamedRoot((cx), (rp), (__FILE__ ":" JS_TOKEN_TO_STRING(__LINE__))
746
+ #endif
747
+
748
+ extern JS_PUBLIC_API(JSBool)
749
+ JS_AddNamedRoot(JSContext *cx, void *rp, const char *name);
750
+
751
+ extern JS_PUBLIC_API(JSBool)
752
+ JS_AddNamedRootRT(JSRuntime *rt, void *rp, const char *name);
753
+
754
+ extern JS_PUBLIC_API(JSBool)
755
+ JS_RemoveRoot(JSContext *cx, void *rp);
756
+
757
+ extern JS_PUBLIC_API(JSBool)
758
+ JS_RemoveRootRT(JSRuntime *rt, void *rp);
759
+
760
+ /*
761
+ * The last GC thing of each type (object, string, double, external string
762
+ * types) created on a given context is kept alive until another thing of the
763
+ * same type is created, using a newborn root in the context. These newborn
764
+ * roots help native code protect newly-created GC-things from GC invocations
765
+ * activated before those things can be rooted using local or global roots.
766
+ *
767
+ * However, the newborn roots can also entrain great gobs of garbage, so the
768
+ * JS_GC entry point clears them for the context on which GC is being forced.
769
+ * Embeddings may need to do likewise for all contexts.
770
+ *
771
+ * See the scoped local root API immediately below for a better way to manage
772
+ * newborns in cases where native hooks (functions, getters, setters, etc.)
773
+ * create many GC-things, potentially without connecting them to predefined
774
+ * local roots such as *rval or argv[i] in an active native function. Using
775
+ * JS_EnterLocalRootScope disables updating of the context's per-gc-thing-type
776
+ * newborn roots, until control flow unwinds and leaves the outermost nesting
777
+ * local root scope.
778
+ */
779
+ extern JS_PUBLIC_API(void)
780
+ JS_ClearNewbornRoots(JSContext *cx);
781
+
782
+ /*
783
+ * Scoped local root management allows native functions, getter/setters, etc.
784
+ * to avoid worrying about the newborn root pigeon-holes, overloading local
785
+ * roots allocated in argv and *rval, or ending up having to call JS_Add*Root
786
+ * and JS_RemoveRoot to manage global roots temporarily.
787
+ *
788
+ * Instead, calling JS_EnterLocalRootScope and JS_LeaveLocalRootScope around
789
+ * the body of the native hook causes the engine to allocate a local root for
790
+ * each newborn created in between the two API calls, using a local root stack
791
+ * associated with cx. For example:
792
+ *
793
+ * JSBool
794
+ * my_GetProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
795
+ * {
796
+ * JSBool ok;
797
+ *
798
+ * if (!JS_EnterLocalRootScope(cx))
799
+ * return JS_FALSE;
800
+ * ok = my_GetPropertyBody(cx, obj, id, vp);
801
+ * JS_LeaveLocalRootScope(cx);
802
+ * return ok;
803
+ * }
804
+ *
805
+ * NB: JS_LeaveLocalRootScope must be called once for every prior successful
806
+ * call to JS_EnterLocalRootScope. If JS_EnterLocalRootScope fails, you must
807
+ * not make the matching JS_LeaveLocalRootScope call.
808
+ *
809
+ * JS_LeaveLocalRootScopeWithResult(cx, rval) is an alternative way to leave
810
+ * a local root scope that protects a result or return value, by effectively
811
+ * pushing it in the caller's local root scope.
812
+ *
813
+ * In case a native hook allocates many objects or other GC-things, but the
814
+ * native protects some of those GC-things by storing them as property values
815
+ * in an object that is itself protected, the hook can call JS_ForgetLocalRoot
816
+ * to free the local root automatically pushed for the now-protected GC-thing.
817
+ *
818
+ * JS_ForgetLocalRoot works on any GC-thing allocated in the current local
819
+ * root scope, but it's more time-efficient when called on references to more
820
+ * recently created GC-things. Calling it successively on other than the most
821
+ * recently allocated GC-thing will tend to average the time inefficiency, and
822
+ * may risk O(n^2) growth rate, but in any event, you shouldn't allocate too
823
+ * many local roots if you can root as you go (build a tree of objects from
824
+ * the top down, forgetting each latest-allocated GC-thing immediately upon
825
+ * linking it to its parent).
826
+ */
827
+ extern JS_PUBLIC_API(JSBool)
828
+ JS_EnterLocalRootScope(JSContext *cx);
829
+
830
+ extern JS_PUBLIC_API(void)
831
+ JS_LeaveLocalRootScope(JSContext *cx);
832
+
833
+ extern JS_PUBLIC_API(void)
834
+ JS_LeaveLocalRootScopeWithResult(JSContext *cx, jsval rval);
835
+
836
+ extern JS_PUBLIC_API(void)
837
+ JS_ForgetLocalRoot(JSContext *cx, void *thing);
838
+
839
+ #ifdef __cplusplus
840
+ JS_END_EXTERN_C
841
+
842
+ class JSAutoLocalRootScope {
843
+ public:
844
+ JSAutoLocalRootScope(JSContext *cx) : mContext(cx) {
845
+ JS_EnterLocalRootScope(mContext);
846
+ }
847
+ ~JSAutoLocalRootScope() {
848
+ JS_LeaveLocalRootScope(mContext);
849
+ }
850
+
851
+ void forget(void *thing) {
852
+ JS_ForgetLocalRoot(mContext, thing);
853
+ }
854
+
855
+ protected:
856
+ JSContext *mContext;
857
+
858
+ #if 0
859
+ private:
860
+ static void *operator new(size_t) CPP_THROW_NEW { return 0; };
861
+ static void operator delete(void *, size_t) { };
862
+ #endif
863
+ };
864
+
865
+ JS_BEGIN_EXTERN_C
866
+ #endif
867
+
868
+ #ifdef DEBUG
869
+ extern JS_PUBLIC_API(void)
870
+ JS_DumpNamedRoots(JSRuntime *rt,
871
+ void (*dump)(const char *name, void *rp, void *data),
872
+ void *data);
873
+ #endif
874
+
875
+ /*
876
+ * Call JS_MapGCRoots to map the GC's roots table using map(rp, name, data).
877
+ * The root is pointed at by rp; if the root is unnamed, name is null; data is
878
+ * supplied from the third parameter to JS_MapGCRoots.
879
+ *
880
+ * The map function should return JS_MAP_GCROOT_REMOVE to cause the currently
881
+ * enumerated root to be removed. To stop enumeration, set JS_MAP_GCROOT_STOP
882
+ * in the return value. To keep on mapping, return JS_MAP_GCROOT_NEXT. These
883
+ * constants are flags; you can OR them together.
884
+ *
885
+ * This function acquires and releases rt's GC lock around the mapping of the
886
+ * roots table, so the map function should run to completion in as few cycles
887
+ * as possible. Of course, map cannot call JS_GC, JS_MaybeGC, JS_BeginRequest,
888
+ * or any JS API entry point that acquires locks, without double-tripping or
889
+ * deadlocking on the GC lock.
890
+ *
891
+ * JS_MapGCRoots returns the count of roots that were successfully mapped.
892
+ */
893
+ #define JS_MAP_GCROOT_NEXT 0 /* continue mapping entries */
894
+ #define JS_MAP_GCROOT_STOP 1 /* stop mapping entries */
895
+ #define JS_MAP_GCROOT_REMOVE 2 /* remove and free the current entry */
896
+
897
+ typedef intN
898
+ (* JSGCRootMapFun)(void *rp, const char *name, void *data);
899
+
900
+ extern JS_PUBLIC_API(uint32)
901
+ JS_MapGCRoots(JSRuntime *rt, JSGCRootMapFun map, void *data);
902
+
903
+ extern JS_PUBLIC_API(JSBool)
904
+ JS_LockGCThing(JSContext *cx, void *thing);
905
+
906
+ extern JS_PUBLIC_API(JSBool)
907
+ JS_LockGCThingRT(JSRuntime *rt, void *thing);
908
+
909
+ extern JS_PUBLIC_API(JSBool)
910
+ JS_UnlockGCThing(JSContext *cx, void *thing);
911
+
912
+ extern JS_PUBLIC_API(JSBool)
913
+ JS_UnlockGCThingRT(JSRuntime *rt, void *thing);
914
+
915
+ /*
916
+ * Register externally maintained GC roots.
917
+ *
918
+ * traceOp: the trace operation. For each root the implementation should call
919
+ * JS_CallTracer whenever the root contains a traceable thing.
920
+ * data: the data argument to pass to each invocation of traceOp.
921
+ */
922
+ extern JS_PUBLIC_API(void)
923
+ JS_SetExtraGCRoots(JSRuntime *rt, JSTraceDataOp traceOp, void *data);
924
+
925
+ /*
926
+ * For implementors of JSMarkOp. All new code should implement JSTraceOp
927
+ * instead.
928
+ */
929
+ extern JS_PUBLIC_API(void)
930
+ JS_MarkGCThing(JSContext *cx, void *thing, const char *name, void *arg);
931
+
932
+ /*
933
+ * JS_CallTracer API and related macros for implementors of JSTraceOp, to
934
+ * enumerate all references to traceable things reachable via a property or
935
+ * other strong ref identified for debugging purposes by name or index or
936
+ * a naming callback.
937
+ *
938
+ * By definition references to traceable things include non-null pointers
939
+ * to JSObject, JSString and jsdouble and corresponding jsvals.
940
+ *
941
+ * See the JSTraceOp typedef in jspubtd.h.
942
+ */
943
+
944
+ /* Trace kinds to pass to JS_Tracing. */
945
+ #define JSTRACE_OBJECT 0
946
+ #define JSTRACE_DOUBLE 1
947
+ #define JSTRACE_STRING 2
948
+
949
+ /*
950
+ * Use the following macros to check if a particular jsval is a traceable
951
+ * thing and to extract the thing and its kind to pass to JS_CallTracer.
952
+ */
953
+ #define JSVAL_IS_TRACEABLE(v) (JSVAL_IS_GCTHING(v) && !JSVAL_IS_NULL(v))
954
+ #define JSVAL_TO_TRACEABLE(v) (JSVAL_TO_GCTHING(v))
955
+ #define JSVAL_TRACE_KIND(v) (JSVAL_TAG(v) >> 1)
956
+
957
+ JS_STATIC_ASSERT(JSVAL_TRACE_KIND(JSVAL_OBJECT) == JSTRACE_OBJECT);
958
+ JS_STATIC_ASSERT(JSVAL_TRACE_KIND(JSVAL_DOUBLE) == JSTRACE_DOUBLE);
959
+ JS_STATIC_ASSERT(JSVAL_TRACE_KIND(JSVAL_STRING) == JSTRACE_STRING);
960
+
961
+ struct JSTracer {
962
+ JSContext *context;
963
+ JSTraceCallback callback;
964
+ #ifdef DEBUG
965
+ JSTraceNamePrinter debugPrinter;
966
+ const void *debugPrintArg;
967
+ size_t debugPrintIndex;
968
+ #endif
969
+ };
970
+
971
+ /*
972
+ * The method to call on each reference to a traceable thing stored in a
973
+ * particular JSObject or other runtime structure. With DEBUG defined the
974
+ * caller before calling JS_CallTracer must initialize JSTracer fields
975
+ * describing the reference using the macros below.
976
+ */
977
+ extern JS_PUBLIC_API(void)
978
+ JS_CallTracer(JSTracer *trc, void *thing, uint32 kind);
979
+
980
+ /*
981
+ * Set debugging information about a reference to a traceable thing to prepare
982
+ * for the following call to JS_CallTracer.
983
+ *
984
+ * When printer is null, arg must be const char * or char * C string naming
985
+ * the reference and index must be either (size_t)-1 indicating that the name
986
+ * alone describes the reference or it must be an index into some array vector
987
+ * that stores the reference.
988
+ *
989
+ * When printer callback is not null, the arg and index arguments are
990
+ * available to the callback as debugPrinterArg and debugPrintIndex fields
991
+ * of JSTracer.
992
+ *
993
+ * The storage for name or callback's arguments needs to live only until
994
+ * the following call to JS_CallTracer returns.
995
+ */
996
+ #ifdef DEBUG
997
+ # define JS_SET_TRACING_DETAILS(trc, printer, arg, index) \
998
+ JS_BEGIN_MACRO \
999
+ (trc)->debugPrinter = (printer); \
1000
+ (trc)->debugPrintArg = (arg); \
1001
+ (trc)->debugPrintIndex = (index); \
1002
+ JS_END_MACRO
1003
+ #else
1004
+ # define JS_SET_TRACING_DETAILS(trc, printer, arg, index) \
1005
+ JS_BEGIN_MACRO \
1006
+ JS_END_MACRO
1007
+ #endif
1008
+
1009
+ /*
1010
+ * Convenience macro to describe the argument of JS_CallTracer using C string
1011
+ * and index.
1012
+ */
1013
+ # define JS_SET_TRACING_INDEX(trc, name, index) \
1014
+ JS_SET_TRACING_DETAILS(trc, NULL, name, index)
1015
+
1016
+ /*
1017
+ * Convenience macro to describe the argument of JS_CallTracer using C string.
1018
+ */
1019
+ # define JS_SET_TRACING_NAME(trc, name) \
1020
+ JS_SET_TRACING_DETAILS(trc, NULL, name, (size_t)-1)
1021
+
1022
+ /*
1023
+ * Convenience macro to invoke JS_CallTracer using C string as the name for
1024
+ * the reference to a traceable thing.
1025
+ */
1026
+ # define JS_CALL_TRACER(trc, thing, kind, name) \
1027
+ JS_BEGIN_MACRO \
1028
+ JS_SET_TRACING_NAME(trc, name); \
1029
+ JS_CallTracer((trc), (thing), (kind)); \
1030
+ JS_END_MACRO
1031
+
1032
+ /*
1033
+ * Convenience macros to invoke JS_CallTracer when jsval represents a
1034
+ * reference to a traceable thing.
1035
+ */
1036
+ #define JS_CALL_VALUE_TRACER(trc, val, name) \
1037
+ JS_BEGIN_MACRO \
1038
+ if (JSVAL_IS_TRACEABLE(val)) { \
1039
+ JS_CALL_TRACER((trc), JSVAL_TO_GCTHING(val), \
1040
+ JSVAL_TRACE_KIND(val), name); \
1041
+ } \
1042
+ JS_END_MACRO
1043
+
1044
+ #define JS_CALL_OBJECT_TRACER(trc, object, name) \
1045
+ JS_BEGIN_MACRO \
1046
+ JSObject *obj_ = (object); \
1047
+ JS_ASSERT(obj_); \
1048
+ JS_CALL_TRACER((trc), obj_, JSTRACE_OBJECT, name); \
1049
+ JS_END_MACRO
1050
+
1051
+ #define JS_CALL_STRING_TRACER(trc, string, name) \
1052
+ JS_BEGIN_MACRO \
1053
+ JSString *str_ = (string); \
1054
+ JS_ASSERT(str_); \
1055
+ JS_CALL_TRACER((trc), str_, JSTRACE_STRING, name); \
1056
+ JS_END_MACRO
1057
+
1058
+ #define JS_CALL_DOUBLE_TRACER(trc, number, name) \
1059
+ JS_BEGIN_MACRO \
1060
+ jsdouble *num_ = (number); \
1061
+ JS_ASSERT(num_); \
1062
+ JS_CALL_TRACER((trc), num_, JSTRACE_DOUBLE, name); \
1063
+ JS_END_MACRO
1064
+
1065
+ /*
1066
+ * API for JSTraceCallback implementations.
1067
+ */
1068
+ # define JS_TRACER_INIT(trc, cx_, callback_) \
1069
+ JS_BEGIN_MACRO \
1070
+ (trc)->context = (cx_); \
1071
+ (trc)->callback = (callback_); \
1072
+ JS_SET_TRACING_DETAILS(trc, NULL, NULL, (size_t)-1); \
1073
+ JS_END_MACRO
1074
+
1075
+ extern JS_PUBLIC_API(void)
1076
+ JS_TraceChildren(JSTracer *trc, void *thing, uint32 kind);
1077
+
1078
+ extern JS_PUBLIC_API(void)
1079
+ JS_TraceRuntime(JSTracer *trc);
1080
+
1081
+ #ifdef DEBUG
1082
+
1083
+ extern JS_PUBLIC_API(void)
1084
+ JS_PrintTraceThingInfo(char *buf, size_t bufsize, JSTracer *trc,
1085
+ void *thing, uint32 kind, JSBool includeDetails);
1086
+
1087
+ /*
1088
+ * DEBUG-only method to dump the object graph of heap-allocated things.
1089
+ *
1090
+ * fp: file for the dump output.
1091
+ * start: when non-null, dump only things reachable from start
1092
+ * thing. Otherwise dump all things reachable from the
1093
+ * runtime roots.
1094
+ * startKind: trace kind of start if start is not null. Must be 0 when
1095
+ * start is null.
1096
+ * thingToFind: dump only paths in the object graph leading to thingToFind
1097
+ * when non-null.
1098
+ * maxDepth: the upper bound on the number of edges to descend from the
1099
+ * graph roots.
1100
+ * thingToIgnore: thing to ignore during the graph traversal when non-null.
1101
+ */
1102
+ extern JS_PUBLIC_API(JSBool)
1103
+ JS_DumpHeap(JSContext *cx, FILE *fp, void* startThing, uint32 startKind,
1104
+ void *thingToFind, size_t maxDepth, void *thingToIgnore);
1105
+
1106
+ #endif
1107
+
1108
+ /*
1109
+ * Garbage collector API.
1110
+ */
1111
+ extern JS_PUBLIC_API(void)
1112
+ JS_GC(JSContext *cx);
1113
+
1114
+ extern JS_PUBLIC_API(void)
1115
+ JS_MaybeGC(JSContext *cx);
1116
+
1117
+ extern JS_PUBLIC_API(JSGCCallback)
1118
+ JS_SetGCCallback(JSContext *cx, JSGCCallback cb);
1119
+
1120
+ extern JS_PUBLIC_API(JSGCCallback)
1121
+ JS_SetGCCallbackRT(JSRuntime *rt, JSGCCallback cb);
1122
+
1123
+ extern JS_PUBLIC_API(JSBool)
1124
+ JS_IsGCMarkingTracer(JSTracer *trc);
1125
+
1126
+ extern JS_PUBLIC_API(JSBool)
1127
+ JS_IsAboutToBeFinalized(JSContext *cx, void *thing);
1128
+
1129
+ typedef enum JSGCParamKey {
1130
+ /* Maximum nominal heap before last ditch GC. */
1131
+ JSGC_MAX_BYTES = 0,
1132
+
1133
+ /* Number of JS_malloc bytes before last ditch GC. */
1134
+ JSGC_MAX_MALLOC_BYTES = 1,
1135
+
1136
+ /* Hoard stackPools for this long, in ms, default is 30 seconds. */
1137
+ JSGC_STACKPOOL_LIFESPAN = 2
1138
+ } JSGCParamKey;
1139
+
1140
+ extern JS_PUBLIC_API(void)
1141
+ JS_SetGCParameter(JSRuntime *rt, JSGCParamKey key, uint32 value);
1142
+
1143
+ /*
1144
+ * Add a finalizer for external strings created by JS_NewExternalString (see
1145
+ * below) using a type-code returned from this function, and that understands
1146
+ * how to free or release the memory pointed at by JS_GetStringChars(str).
1147
+ *
1148
+ * Return a nonnegative type index if there is room for finalizer in the
1149
+ * global GC finalizers table, else return -1. If the engine is compiled
1150
+ * JS_THREADSAFE and used in a multi-threaded environment, this function must
1151
+ * be invoked on the primordial thread only, at startup -- or else the entire
1152
+ * program must single-thread itself while loading a module that calls this
1153
+ * function.
1154
+ */
1155
+ extern JS_PUBLIC_API(intN)
1156
+ JS_AddExternalStringFinalizer(JSStringFinalizeOp finalizer);
1157
+
1158
+ /*
1159
+ * Remove finalizer from the global GC finalizers table, returning its type
1160
+ * code if found, -1 if not found.
1161
+ *
1162
+ * As with JS_AddExternalStringFinalizer, there is a threading restriction
1163
+ * if you compile the engine JS_THREADSAFE: this function may be called for a
1164
+ * given finalizer pointer on only one thread; different threads may call to
1165
+ * remove distinct finalizers safely.
1166
+ *
1167
+ * You must ensure that all strings with finalizer's type have been collected
1168
+ * before calling this function. Otherwise, string data will be leaked by the
1169
+ * GC, for want of a finalizer to call.
1170
+ */
1171
+ extern JS_PUBLIC_API(intN)
1172
+ JS_RemoveExternalStringFinalizer(JSStringFinalizeOp finalizer);
1173
+
1174
+ /*
1175
+ * Create a new JSString whose chars member refers to external memory, i.e.,
1176
+ * memory requiring special, type-specific finalization. The type code must
1177
+ * be a nonnegative return value from JS_AddExternalStringFinalizer.
1178
+ */
1179
+ extern JS_PUBLIC_API(JSString *)
1180
+ JS_NewExternalString(JSContext *cx, jschar *chars, size_t length, intN type);
1181
+
1182
+ /*
1183
+ * Returns the external-string finalizer index for this string, or -1 if it is
1184
+ * an "internal" (native to JS engine) string.
1185
+ */
1186
+ extern JS_PUBLIC_API(intN)
1187
+ JS_GetExternalStringGCType(JSRuntime *rt, JSString *str);
1188
+
1189
+ /*
1190
+ * Sets maximum (if stack grows upward) or minimum (downward) legal stack byte
1191
+ * address in limitAddr for the thread or process stack used by cx. To disable
1192
+ * stack size checking, pass 0 for limitAddr.
1193
+ */
1194
+ extern JS_PUBLIC_API(void)
1195
+ JS_SetThreadStackLimit(JSContext *cx, jsuword limitAddr);
1196
+
1197
+ /*
1198
+ * Set the quota on the number of bytes that stack-like data structures can
1199
+ * use when the runtime compiles and executes scripts. These structures
1200
+ * consume heap space, so JS_SetThreadStackLimit does not bound their size.
1201
+ * The default quota is 32MB which is quite generous.
1202
+ *
1203
+ * The function must be called before any script compilation or execution API
1204
+ * calls, i.e. either immediately after JS_NewContext or from JSCONTEXT_NEW
1205
+ * context callback.
1206
+ */
1207
+ extern JS_PUBLIC_API(void)
1208
+ JS_SetScriptStackQuota(JSContext *cx, size_t quota);
1209
+
1210
+ #define JS_DEFAULT_SCRIPT_STACK_QUOTA ((size_t) 0x2000000)
1211
+
1212
+ /************************************************************************/
1213
+
1214
+ /*
1215
+ * Classes, objects, and properties.
1216
+ */
1217
+
1218
+ /* For detailed comments on the function pointer types, see jspubtd.h. */
1219
+ struct JSClass {
1220
+ const char *name;
1221
+ uint32 flags;
1222
+
1223
+ /* Mandatory non-null function pointer members. */
1224
+ JSPropertyOp addProperty;
1225
+ JSPropertyOp delProperty;
1226
+ JSPropertyOp getProperty;
1227
+ JSPropertyOp setProperty;
1228
+ JSEnumerateOp enumerate;
1229
+ JSResolveOp resolve;
1230
+ JSConvertOp convert;
1231
+ JSFinalizeOp finalize;
1232
+
1233
+ /* Optionally non-null members start here. */
1234
+ JSGetObjectOps getObjectOps;
1235
+ JSCheckAccessOp checkAccess;
1236
+ JSNative call;
1237
+ JSNative construct;
1238
+ JSXDRObjectOp xdrObject;
1239
+ JSHasInstanceOp hasInstance;
1240
+ JSMarkOp mark;
1241
+ JSReserveSlotsOp reserveSlots;
1242
+ };
1243
+
1244
+ struct JSExtendedClass {
1245
+ JSClass base;
1246
+ JSEqualityOp equality;
1247
+ JSObjectOp outerObject;
1248
+ JSObjectOp innerObject;
1249
+ JSIteratorOp iteratorObject;
1250
+ JSObjectOp wrappedObject; /* NB: infallible, null
1251
+ returns are treated as
1252
+ the original object */
1253
+ void (*reserved0)(void);
1254
+ void (*reserved1)(void);
1255
+ void (*reserved2)(void);
1256
+ };
1257
+
1258
+ #define JSCLASS_HAS_PRIVATE (1<<0) /* objects have private slot */
1259
+ #define JSCLASS_NEW_ENUMERATE (1<<1) /* has JSNewEnumerateOp hook */
1260
+ #define JSCLASS_NEW_RESOLVE (1<<2) /* has JSNewResolveOp hook */
1261
+ #define JSCLASS_PRIVATE_IS_NSISUPPORTS (1<<3) /* private is (nsISupports *) */
1262
+ #define JSCLASS_SHARE_ALL_PROPERTIES (1<<4) /* all properties are SHARED */
1263
+ #define JSCLASS_NEW_RESOLVE_GETS_START (1<<5) /* JSNewResolveOp gets starting
1264
+ object in prototype chain
1265
+ passed in via *objp in/out
1266
+ parameter */
1267
+ #define JSCLASS_CONSTRUCT_PROTOTYPE (1<<6) /* call constructor on class
1268
+ prototype */
1269
+ #define JSCLASS_DOCUMENT_OBSERVER (1<<7) /* DOM document observer */
1270
+
1271
+ /*
1272
+ * To reserve slots fetched and stored via JS_Get/SetReservedSlot, bitwise-or
1273
+ * JSCLASS_HAS_RESERVED_SLOTS(n) into the initializer for JSClass.flags, where
1274
+ * n is a constant in [1, 255]. Reserved slots are indexed from 0 to n-1.
1275
+ */
1276
+ #define JSCLASS_RESERVED_SLOTS_SHIFT 8 /* room for 8 flags below */
1277
+ #define JSCLASS_RESERVED_SLOTS_WIDTH 8 /* and 16 above this field */
1278
+ #define JSCLASS_RESERVED_SLOTS_MASK JS_BITMASK(JSCLASS_RESERVED_SLOTS_WIDTH)
1279
+ #define JSCLASS_HAS_RESERVED_SLOTS(n) (((n) & JSCLASS_RESERVED_SLOTS_MASK) \
1280
+ << JSCLASS_RESERVED_SLOTS_SHIFT)
1281
+ #define JSCLASS_RESERVED_SLOTS(clasp) (((clasp)->flags \
1282
+ >> JSCLASS_RESERVED_SLOTS_SHIFT) \
1283
+ & JSCLASS_RESERVED_SLOTS_MASK)
1284
+
1285
+ #define JSCLASS_HIGH_FLAGS_SHIFT (JSCLASS_RESERVED_SLOTS_SHIFT + \
1286
+ JSCLASS_RESERVED_SLOTS_WIDTH)
1287
+
1288
+ /* True if JSClass is really a JSExtendedClass. */
1289
+ #define JSCLASS_IS_EXTENDED (1<<(JSCLASS_HIGH_FLAGS_SHIFT+0))
1290
+ #define JSCLASS_IS_ANONYMOUS (1<<(JSCLASS_HIGH_FLAGS_SHIFT+1))
1291
+ #define JSCLASS_IS_GLOBAL (1<<(JSCLASS_HIGH_FLAGS_SHIFT+2))
1292
+
1293
+ /* Indicates that JSClass.mark is a tracer with JSTraceOp type. */
1294
+ #define JSCLASS_MARK_IS_TRACE (1<<(JSCLASS_HIGH_FLAGS_SHIFT+3))
1295
+
1296
+ /*
1297
+ * ECMA-262 requires that most constructors used internally create objects
1298
+ * with "the original Foo.prototype value" as their [[Prototype]] (__proto__)
1299
+ * member initial value. The "original ... value" verbiage is there because
1300
+ * in ECMA-262, global properties naming class objects are read/write and
1301
+ * deleteable, for the most part.
1302
+ *
1303
+ * Implementing this efficiently requires that global objects have classes
1304
+ * with the following flags. Failure to use JSCLASS_GLOBAL_FLAGS won't break
1305
+ * anything except the ECMA-262 "original prototype value" behavior, which was
1306
+ * broken for years in SpiderMonkey. In other words, without these flags you
1307
+ * get backward compatibility.
1308
+ */
1309
+ #define JSCLASS_GLOBAL_FLAGS \
1310
+ (JSCLASS_IS_GLOBAL | JSCLASS_HAS_RESERVED_SLOTS(JSProto_LIMIT))
1311
+
1312
+ /* Fast access to the original value of each standard class's prototype. */
1313
+ #define JSCLASS_CACHED_PROTO_SHIFT (JSCLASS_HIGH_FLAGS_SHIFT + 8)
1314
+ #define JSCLASS_CACHED_PROTO_WIDTH 8
1315
+ #define JSCLASS_CACHED_PROTO_MASK JS_BITMASK(JSCLASS_CACHED_PROTO_WIDTH)
1316
+ #define JSCLASS_HAS_CACHED_PROTO(key) ((key) << JSCLASS_CACHED_PROTO_SHIFT)
1317
+ #define JSCLASS_CACHED_PROTO_KEY(clasp) ((JSProtoKey) \
1318
+ (((clasp)->flags \
1319
+ >> JSCLASS_CACHED_PROTO_SHIFT) \
1320
+ & JSCLASS_CACHED_PROTO_MASK))
1321
+
1322
+ /* Initializer for unused members of statically initialized JSClass structs. */
1323
+ #define JSCLASS_NO_OPTIONAL_MEMBERS 0,0,0,0,0,0,0,0
1324
+ #define JSCLASS_NO_RESERVED_MEMBERS 0,0,0
1325
+
1326
+ /* For detailed comments on these function pointer types, see jspubtd.h. */
1327
+ struct JSObjectOps {
1328
+ /* Mandatory non-null function pointer members. */
1329
+ JSNewObjectMapOp newObjectMap;
1330
+ JSObjectMapOp destroyObjectMap;
1331
+ JSLookupPropOp lookupProperty;
1332
+ JSDefinePropOp defineProperty;
1333
+ JSPropertyIdOp getProperty;
1334
+ JSPropertyIdOp setProperty;
1335
+ JSAttributesOp getAttributes;
1336
+ JSAttributesOp setAttributes;
1337
+ JSPropertyIdOp deleteProperty;
1338
+ JSConvertOp defaultValue;
1339
+ JSNewEnumerateOp enumerate;
1340
+ JSCheckAccessIdOp checkAccess;
1341
+
1342
+ /* Optionally non-null members start here. */
1343
+ JSObjectOp thisObject;
1344
+ JSPropertyRefOp dropProperty;
1345
+ JSNative call;
1346
+ JSNative construct;
1347
+ JSXDRObjectOp xdrObject;
1348
+ JSHasInstanceOp hasInstance;
1349
+ JSSetObjectSlotOp setProto;
1350
+ JSSetObjectSlotOp setParent;
1351
+ JSTraceOp trace;
1352
+ JSFinalizeOp clear;
1353
+ JSGetRequiredSlotOp getRequiredSlot;
1354
+ JSSetRequiredSlotOp setRequiredSlot;
1355
+ };
1356
+
1357
+ struct JSXMLObjectOps {
1358
+ JSObjectOps base;
1359
+ JSGetMethodOp getMethod;
1360
+ JSSetMethodOp setMethod;
1361
+ JSEnumerateValuesOp enumerateValues;
1362
+ JSEqualityOp equality;
1363
+ JSConcatenateOp concatenate;
1364
+ };
1365
+
1366
+ /*
1367
+ * Classes that expose JSObjectOps via a non-null getObjectOps class hook may
1368
+ * derive a property structure from this struct, return a pointer to it from
1369
+ * lookupProperty and defineProperty, and use the pointer to avoid rehashing
1370
+ * in getAttributes and setAttributes.
1371
+ *
1372
+ * The jsid type contains either an int jsval (see JSVAL_IS_INT above), or an
1373
+ * internal pointer that is opaque to users of this API, but which users may
1374
+ * convert from and to a jsval using JS_ValueToId and JS_IdToValue.
1375
+ */
1376
+ struct JSProperty {
1377
+ jsid id;
1378
+ };
1379
+
1380
+ struct JSIdArray {
1381
+ jsint length;
1382
+ jsid vector[1]; /* actually, length jsid words */
1383
+ };
1384
+
1385
+ extern JS_PUBLIC_API(void)
1386
+ JS_DestroyIdArray(JSContext *cx, JSIdArray *ida);
1387
+
1388
+ extern JS_PUBLIC_API(JSBool)
1389
+ JS_ValueToId(JSContext *cx, jsval v, jsid *idp);
1390
+
1391
+ extern JS_PUBLIC_API(JSBool)
1392
+ JS_IdToValue(JSContext *cx, jsid id, jsval *vp);
1393
+
1394
+ /*
1395
+ * The magic XML namespace id is int-tagged, but not a valid integer jsval.
1396
+ * Global object classes in embeddings that enable JS_HAS_XML_SUPPORT (E4X)
1397
+ * should handle this id specially before converting id via JSVAL_TO_INT.
1398
+ */
1399
+ #define JS_DEFAULT_XML_NAMESPACE_ID ((jsid) JSVAL_VOID)
1400
+
1401
+ /*
1402
+ * JSNewResolveOp flag bits.
1403
+ */
1404
+ #define JSRESOLVE_QUALIFIED 0x01 /* resolve a qualified property id */
1405
+ #define JSRESOLVE_ASSIGNING 0x02 /* resolve on the left of assignment */
1406
+ #define JSRESOLVE_DETECTING 0x04 /* 'if (o.p)...' or '(o.p) ?...:...' */
1407
+ #define JSRESOLVE_DECLARING 0x08 /* var, const, or function prolog op */
1408
+ #define JSRESOLVE_CLASSNAME 0x10 /* class name used when constructing */
1409
+
1410
+ extern JS_PUBLIC_API(JSBool)
1411
+ JS_PropertyStub(JSContext *cx, JSObject *obj, jsval id, jsval *vp);
1412
+
1413
+ extern JS_PUBLIC_API(JSBool)
1414
+ JS_EnumerateStub(JSContext *cx, JSObject *obj);
1415
+
1416
+ extern JS_PUBLIC_API(JSBool)
1417
+ JS_ResolveStub(JSContext *cx, JSObject *obj, jsval id);
1418
+
1419
+ extern JS_PUBLIC_API(JSBool)
1420
+ JS_ConvertStub(JSContext *cx, JSObject *obj, JSType type, jsval *vp);
1421
+
1422
+ extern JS_PUBLIC_API(void)
1423
+ JS_FinalizeStub(JSContext *cx, JSObject *obj);
1424
+
1425
+ struct JSConstDoubleSpec {
1426
+ jsdouble dval;
1427
+ const char *name;
1428
+ uint8 flags;
1429
+ uint8 spare[3];
1430
+ };
1431
+
1432
+ /*
1433
+ * To define an array element rather than a named property member, cast the
1434
+ * element's index to (const char *) and initialize name with it, and set the
1435
+ * JSPROP_INDEX bit in flags.
1436
+ */
1437
+ struct JSPropertySpec {
1438
+ const char *name;
1439
+ int8 tinyid;
1440
+ uint8 flags;
1441
+ JSPropertyOp getter;
1442
+ JSPropertyOp setter;
1443
+ };
1444
+
1445
+ struct JSFunctionSpec {
1446
+ const char *name;
1447
+ JSNative call;
1448
+ uint16 nargs;
1449
+ uint16 flags;
1450
+
1451
+ /*
1452
+ * extra & 0xFFFF: Number of extra argument slots for local GC roots.
1453
+ * If fast native, must be zero.
1454
+ * extra >> 16: Reserved for future use (must be 0).
1455
+ */
1456
+ uint32 extra;
1457
+ };
1458
+
1459
+ /*
1460
+ * Terminating sentinel initializer to put at the end of a JSFunctionSpec array
1461
+ * that's passed to JS_DefineFunctions or JS_InitClass.
1462
+ */
1463
+ #define JS_FS_END JS_FS(NULL,NULL,0,0,0)
1464
+
1465
+ /*
1466
+ * Initializer macro for a JSFunctionSpec array element. This is the original
1467
+ * kind of native function specifier initializer. Use JS_FN ("fast native", see
1468
+ * JSFastNative in jspubtd.h) for all functions that do not need a stack frame
1469
+ * when activated.
1470
+ */
1471
+ #define JS_FS(name,call,nargs,flags,extra) \
1472
+ {name, call, nargs, flags, extra}
1473
+
1474
+ /*
1475
+ * "Fast native" initializer macro for a JSFunctionSpec array element. Use this
1476
+ * in preference to JS_FS if the native in question does not need its own stack
1477
+ * frame when activated.
1478
+ */
1479
+ #define JS_FN(name,fastcall,nargs,flags) \
1480
+ {name, (JSNative)(fastcall), nargs, \
1481
+ (flags) | JSFUN_FAST_NATIVE | JSFUN_STUB_GSOPS, 0}
1482
+
1483
+ extern JS_PUBLIC_API(JSObject *)
1484
+ JS_InitClass(JSContext *cx, JSObject *obj, JSObject *parent_proto,
1485
+ JSClass *clasp, JSNative constructor, uintN nargs,
1486
+ JSPropertySpec *ps, JSFunctionSpec *fs,
1487
+ JSPropertySpec *static_ps, JSFunctionSpec *static_fs);
1488
+
1489
+ #ifdef JS_THREADSAFE
1490
+ extern JS_PUBLIC_API(JSClass *)
1491
+ JS_GetClass(JSContext *cx, JSObject *obj);
1492
+
1493
+ #define JS_GET_CLASS(cx,obj) JS_GetClass(cx, obj)
1494
+ #else
1495
+ extern JS_PUBLIC_API(JSClass *)
1496
+ JS_GetClass(JSObject *obj);
1497
+
1498
+ #define JS_GET_CLASS(cx,obj) JS_GetClass(obj)
1499
+ #endif
1500
+
1501
+ extern JS_PUBLIC_API(JSBool)
1502
+ JS_InstanceOf(JSContext *cx, JSObject *obj, JSClass *clasp, jsval *argv);
1503
+
1504
+ extern JS_PUBLIC_API(JSBool)
1505
+ JS_HasInstance(JSContext *cx, JSObject *obj, jsval v, JSBool *bp);
1506
+
1507
+ extern JS_PUBLIC_API(void *)
1508
+ JS_GetPrivate(JSContext *cx, JSObject *obj);
1509
+
1510
+ extern JS_PUBLIC_API(JSBool)
1511
+ JS_SetPrivate(JSContext *cx, JSObject *obj, void *data);
1512
+
1513
+ extern JS_PUBLIC_API(void *)
1514
+ JS_GetInstancePrivate(JSContext *cx, JSObject *obj, JSClass *clasp,
1515
+ jsval *argv);
1516
+
1517
+ extern JS_PUBLIC_API(JSObject *)
1518
+ JS_GetPrototype(JSContext *cx, JSObject *obj);
1519
+
1520
+ extern JS_PUBLIC_API(JSBool)
1521
+ JS_SetPrototype(JSContext *cx, JSObject *obj, JSObject *proto);
1522
+
1523
+ extern JS_PUBLIC_API(JSObject *)
1524
+ JS_GetParent(JSContext *cx, JSObject *obj);
1525
+
1526
+ extern JS_PUBLIC_API(JSBool)
1527
+ JS_SetParent(JSContext *cx, JSObject *obj, JSObject *parent);
1528
+
1529
+ extern JS_PUBLIC_API(JSObject *)
1530
+ JS_GetConstructor(JSContext *cx, JSObject *proto);
1531
+
1532
+ /*
1533
+ * Get a unique identifier for obj, good for the lifetime of obj (even if it
1534
+ * is moved by a copying GC). Return false on failure (likely out of memory),
1535
+ * and true with *idp containing the unique id on success.
1536
+ */
1537
+ extern JS_PUBLIC_API(JSBool)
1538
+ JS_GetObjectId(JSContext *cx, JSObject *obj, jsid *idp);
1539
+
1540
+ extern JS_PUBLIC_API(JSObject *)
1541
+ JS_NewObject(JSContext *cx, JSClass *clasp, JSObject *proto, JSObject *parent);
1542
+
1543
+ /*
1544
+ * Unlike JS_NewObject, JS_NewObjectWithGivenProto does not compute a default
1545
+ * proto if proto's actual parameter value is null.
1546
+ */
1547
+ extern JS_PUBLIC_API(JSObject *)
1548
+ JS_NewObjectWithGivenProto(JSContext *cx, JSClass *clasp, JSObject *proto,
1549
+ JSObject *parent);
1550
+
1551
+ extern JS_PUBLIC_API(JSBool)
1552
+ JS_SealObject(JSContext *cx, JSObject *obj, JSBool deep);
1553
+
1554
+ extern JS_PUBLIC_API(JSObject *)
1555
+ JS_ConstructObject(JSContext *cx, JSClass *clasp, JSObject *proto,
1556
+ JSObject *parent);
1557
+
1558
+ extern JS_PUBLIC_API(JSObject *)
1559
+ JS_ConstructObjectWithArguments(JSContext *cx, JSClass *clasp, JSObject *proto,
1560
+ JSObject *parent, uintN argc, jsval *argv);
1561
+
1562
+ extern JS_PUBLIC_API(JSObject *)
1563
+ JS_DefineObject(JSContext *cx, JSObject *obj, const char *name, JSClass *clasp,
1564
+ JSObject *proto, uintN attrs);
1565
+
1566
+ extern JS_PUBLIC_API(JSBool)
1567
+ JS_DefineConstDoubles(JSContext *cx, JSObject *obj, JSConstDoubleSpec *cds);
1568
+
1569
+ extern JS_PUBLIC_API(JSBool)
1570
+ JS_DefineProperties(JSContext *cx, JSObject *obj, JSPropertySpec *ps);
1571
+
1572
+ extern JS_PUBLIC_API(JSBool)
1573
+ JS_DefineProperty(JSContext *cx, JSObject *obj, const char *name, jsval value,
1574
+ JSPropertyOp getter, JSPropertyOp setter, uintN attrs);
1575
+
1576
+ extern JS_PUBLIC_API(JSBool)
1577
+ JS_DefinePropertyById(JSContext *cx, JSObject *obj, jsid id, jsval value,
1578
+ JSPropertyOp getter, JSPropertyOp setter, uintN attrs);
1579
+
1580
+ /*
1581
+ * Determine the attributes (JSPROP_* flags) of a property on a given object.
1582
+ *
1583
+ * If the object does not have a property by that name, *foundp will be
1584
+ * JS_FALSE and the value of *attrsp is undefined.
1585
+ */
1586
+ extern JS_PUBLIC_API(JSBool)
1587
+ JS_GetPropertyAttributes(JSContext *cx, JSObject *obj, const char *name,
1588
+ uintN *attrsp, JSBool *foundp);
1589
+
1590
+ /*
1591
+ * The same, but if the property is native, return its getter and setter via
1592
+ * *getterp and *setterp, respectively (and only if the out parameter pointer
1593
+ * is not null).
1594
+ */
1595
+ extern JS_PUBLIC_API(JSBool)
1596
+ JS_GetPropertyAttrsGetterAndSetter(JSContext *cx, JSObject *obj,
1597
+ const char *name,
1598
+ uintN *attrsp, JSBool *foundp,
1599
+ JSPropertyOp *getterp,
1600
+ JSPropertyOp *setterp);
1601
+
1602
+ /*
1603
+ * Set the attributes of a property on a given object.
1604
+ *
1605
+ * If the object does not have a property by that name, *foundp will be
1606
+ * JS_FALSE and nothing will be altered.
1607
+ */
1608
+ extern JS_PUBLIC_API(JSBool)
1609
+ JS_SetPropertyAttributes(JSContext *cx, JSObject *obj, const char *name,
1610
+ uintN attrs, JSBool *foundp);
1611
+
1612
+ extern JS_PUBLIC_API(JSBool)
1613
+ JS_DefinePropertyWithTinyId(JSContext *cx, JSObject *obj, const char *name,
1614
+ int8 tinyid, jsval value,
1615
+ JSPropertyOp getter, JSPropertyOp setter,
1616
+ uintN attrs);
1617
+
1618
+ extern JS_PUBLIC_API(JSBool)
1619
+ JS_AliasProperty(JSContext *cx, JSObject *obj, const char *name,
1620
+ const char *alias);
1621
+
1622
+ extern JS_PUBLIC_API(JSBool)
1623
+ JS_AlreadyHasOwnProperty(JSContext *cx, JSObject *obj, const char *name,
1624
+ JSBool *foundp);
1625
+
1626
+ extern JS_PUBLIC_API(JSBool)
1627
+ JS_AlreadyHasOwnPropertyById(JSContext *cx, JSObject *obj, jsid id,
1628
+ JSBool *foundp);
1629
+
1630
+ extern JS_PUBLIC_API(JSBool)
1631
+ JS_HasProperty(JSContext *cx, JSObject *obj, const char *name, JSBool *foundp);
1632
+
1633
+ extern JS_PUBLIC_API(JSBool)
1634
+ JS_HasPropertyById(JSContext *cx, JSObject *obj, jsid id, JSBool *foundp);
1635
+
1636
+ extern JS_PUBLIC_API(JSBool)
1637
+ JS_LookupProperty(JSContext *cx, JSObject *obj, const char *name, jsval *vp);
1638
+
1639
+ extern JS_PUBLIC_API(JSBool)
1640
+ JS_LookupPropertyById(JSContext *cx, JSObject *obj, jsid id, jsval *vp);
1641
+
1642
+ extern JS_PUBLIC_API(JSBool)
1643
+ JS_LookupPropertyWithFlags(JSContext *cx, JSObject *obj, const char *name,
1644
+ uintN flags, jsval *vp);
1645
+
1646
+ extern JS_PUBLIC_API(JSBool)
1647
+ JS_LookupPropertyWithFlagsById(JSContext *cx, JSObject *obj, jsid id,
1648
+ uintN flags, JSObject **objp, jsval *vp);
1649
+
1650
+ extern JS_PUBLIC_API(JSBool)
1651
+ JS_GetProperty(JSContext *cx, JSObject *obj, const char *name, jsval *vp);
1652
+
1653
+ extern JS_PUBLIC_API(JSBool)
1654
+ JS_GetPropertyById(JSContext *cx, JSObject *obj, jsid id, jsval *vp);
1655
+
1656
+ extern JS_PUBLIC_API(JSBool)
1657
+ JS_GetMethodById(JSContext *cx, JSObject *obj, jsid id, JSObject **objp,
1658
+ jsval *vp);
1659
+
1660
+ extern JS_PUBLIC_API(JSBool)
1661
+ JS_GetMethod(JSContext *cx, JSObject *obj, const char *name, JSObject **objp,
1662
+ jsval *vp);
1663
+
1664
+ extern JS_PUBLIC_API(JSBool)
1665
+ JS_SetProperty(JSContext *cx, JSObject *obj, const char *name, jsval *vp);
1666
+
1667
+ extern JS_PUBLIC_API(JSBool)
1668
+ JS_SetPropertyById(JSContext *cx, JSObject *obj, jsid id, jsval *vp);
1669
+
1670
+ extern JS_PUBLIC_API(JSBool)
1671
+ JS_DeleteProperty(JSContext *cx, JSObject *obj, const char *name);
1672
+
1673
+ extern JS_PUBLIC_API(JSBool)
1674
+ JS_DeleteProperty2(JSContext *cx, JSObject *obj, const char *name,
1675
+ jsval *rval);
1676
+
1677
+ extern JS_PUBLIC_API(JSBool)
1678
+ JS_DeletePropertyById(JSContext *cx, JSObject *obj, jsid id);
1679
+
1680
+ extern JS_PUBLIC_API(JSBool)
1681
+ JS_DeletePropertyById2(JSContext *cx, JSObject *obj, jsid id, jsval *rval);
1682
+
1683
+ extern JS_PUBLIC_API(JSBool)
1684
+ JS_DefineUCProperty(JSContext *cx, JSObject *obj,
1685
+ const jschar *name, size_t namelen, jsval value,
1686
+ JSPropertyOp getter, JSPropertyOp setter,
1687
+ uintN attrs);
1688
+
1689
+ /*
1690
+ * Determine the attributes (JSPROP_* flags) of a property on a given object.
1691
+ *
1692
+ * If the object does not have a property by that name, *foundp will be
1693
+ * JS_FALSE and the value of *attrsp is undefined.
1694
+ */
1695
+ extern JS_PUBLIC_API(JSBool)
1696
+ JS_GetUCPropertyAttributes(JSContext *cx, JSObject *obj,
1697
+ const jschar *name, size_t namelen,
1698
+ uintN *attrsp, JSBool *foundp);
1699
+
1700
+ /*
1701
+ * The same, but if the property is native, return its getter and setter via
1702
+ * *getterp and *setterp, respectively (and only if the out parameter pointer
1703
+ * is not null).
1704
+ */
1705
+ extern JS_PUBLIC_API(JSBool)
1706
+ JS_GetUCPropertyAttrsGetterAndSetter(JSContext *cx, JSObject *obj,
1707
+ const jschar *name, size_t namelen,
1708
+ uintN *attrsp, JSBool *foundp,
1709
+ JSPropertyOp *getterp,
1710
+ JSPropertyOp *setterp);
1711
+
1712
+ /*
1713
+ * Set the attributes of a property on a given object.
1714
+ *
1715
+ * If the object does not have a property by that name, *foundp will be
1716
+ * JS_FALSE and nothing will be altered.
1717
+ */
1718
+ extern JS_PUBLIC_API(JSBool)
1719
+ JS_SetUCPropertyAttributes(JSContext *cx, JSObject *obj,
1720
+ const jschar *name, size_t namelen,
1721
+ uintN attrs, JSBool *foundp);
1722
+
1723
+
1724
+ extern JS_PUBLIC_API(JSBool)
1725
+ JS_DefineUCPropertyWithTinyId(JSContext *cx, JSObject *obj,
1726
+ const jschar *name, size_t namelen,
1727
+ int8 tinyid, jsval value,
1728
+ JSPropertyOp getter, JSPropertyOp setter,
1729
+ uintN attrs);
1730
+
1731
+ extern JS_PUBLIC_API(JSBool)
1732
+ JS_AlreadyHasOwnUCProperty(JSContext *cx, JSObject *obj, const jschar *name,
1733
+ size_t namelen, JSBool *foundp);
1734
+
1735
+ extern JS_PUBLIC_API(JSBool)
1736
+ JS_HasUCProperty(JSContext *cx, JSObject *obj,
1737
+ const jschar *name, size_t namelen,
1738
+ JSBool *vp);
1739
+
1740
+ extern JS_PUBLIC_API(JSBool)
1741
+ JS_LookupUCProperty(JSContext *cx, JSObject *obj,
1742
+ const jschar *name, size_t namelen,
1743
+ jsval *vp);
1744
+
1745
+ extern JS_PUBLIC_API(JSBool)
1746
+ JS_GetUCProperty(JSContext *cx, JSObject *obj,
1747
+ const jschar *name, size_t namelen,
1748
+ jsval *vp);
1749
+
1750
+ extern JS_PUBLIC_API(JSBool)
1751
+ JS_SetUCProperty(JSContext *cx, JSObject *obj,
1752
+ const jschar *name, size_t namelen,
1753
+ jsval *vp);
1754
+
1755
+ extern JS_PUBLIC_API(JSBool)
1756
+ JS_DeleteUCProperty2(JSContext *cx, JSObject *obj,
1757
+ const jschar *name, size_t namelen,
1758
+ jsval *rval);
1759
+
1760
+ extern JS_PUBLIC_API(JSObject *)
1761
+ JS_NewArrayObject(JSContext *cx, jsint length, jsval *vector);
1762
+
1763
+ extern JS_PUBLIC_API(JSBool)
1764
+ JS_IsArrayObject(JSContext *cx, JSObject *obj);
1765
+
1766
+ extern JS_PUBLIC_API(JSBool)
1767
+ JS_GetArrayLength(JSContext *cx, JSObject *obj, jsuint *lengthp);
1768
+
1769
+ extern JS_PUBLIC_API(JSBool)
1770
+ JS_SetArrayLength(JSContext *cx, JSObject *obj, jsuint length);
1771
+
1772
+ extern JS_PUBLIC_API(JSBool)
1773
+ JS_HasArrayLength(JSContext *cx, JSObject *obj, jsuint *lengthp);
1774
+
1775
+ extern JS_PUBLIC_API(JSBool)
1776
+ JS_DefineElement(JSContext *cx, JSObject *obj, jsint index, jsval value,
1777
+ JSPropertyOp getter, JSPropertyOp setter, uintN attrs);
1778
+
1779
+ extern JS_PUBLIC_API(JSBool)
1780
+ JS_AliasElement(JSContext *cx, JSObject *obj, const char *name, jsint alias);
1781
+
1782
+ extern JS_PUBLIC_API(JSBool)
1783
+ JS_AlreadyHasOwnElement(JSContext *cx, JSObject *obj, jsint index,
1784
+ JSBool *foundp);
1785
+
1786
+ extern JS_PUBLIC_API(JSBool)
1787
+ JS_HasElement(JSContext *cx, JSObject *obj, jsint index, JSBool *foundp);
1788
+
1789
+ extern JS_PUBLIC_API(JSBool)
1790
+ JS_LookupElement(JSContext *cx, JSObject *obj, jsint index, jsval *vp);
1791
+
1792
+ extern JS_PUBLIC_API(JSBool)
1793
+ JS_GetElement(JSContext *cx, JSObject *obj, jsint index, jsval *vp);
1794
+
1795
+ extern JS_PUBLIC_API(JSBool)
1796
+ JS_SetElement(JSContext *cx, JSObject *obj, jsint index, jsval *vp);
1797
+
1798
+ extern JS_PUBLIC_API(JSBool)
1799
+ JS_DeleteElement(JSContext *cx, JSObject *obj, jsint index);
1800
+
1801
+ extern JS_PUBLIC_API(JSBool)
1802
+ JS_DeleteElement2(JSContext *cx, JSObject *obj, jsint index, jsval *rval);
1803
+
1804
+ extern JS_PUBLIC_API(void)
1805
+ JS_ClearScope(JSContext *cx, JSObject *obj);
1806
+
1807
+ extern JS_PUBLIC_API(JSIdArray *)
1808
+ JS_Enumerate(JSContext *cx, JSObject *obj);
1809
+
1810
+ /*
1811
+ * Create an object to iterate over enumerable properties of obj, in arbitrary
1812
+ * property definition order. NB: This differs from longstanding for..in loop
1813
+ * order, which uses order of property definition in obj.
1814
+ */
1815
+ extern JS_PUBLIC_API(JSObject *)
1816
+ JS_NewPropertyIterator(JSContext *cx, JSObject *obj);
1817
+
1818
+ /*
1819
+ * Return true on success with *idp containing the id of the next enumerable
1820
+ * property to visit using iterobj, or JSVAL_VOID if there is no such property
1821
+ * left to visit. Return false on error.
1822
+ */
1823
+ extern JS_PUBLIC_API(JSBool)
1824
+ JS_NextProperty(JSContext *cx, JSObject *iterobj, jsid *idp);
1825
+
1826
+ extern JS_PUBLIC_API(JSBool)
1827
+ JS_CheckAccess(JSContext *cx, JSObject *obj, jsid id, JSAccessMode mode,
1828
+ jsval *vp, uintN *attrsp);
1829
+
1830
+ extern JS_PUBLIC_API(JSBool)
1831
+ JS_GetReservedSlot(JSContext *cx, JSObject *obj, uint32 index, jsval *vp);
1832
+
1833
+ extern JS_PUBLIC_API(JSBool)
1834
+ JS_SetReservedSlot(JSContext *cx, JSObject *obj, uint32 index, jsval v);
1835
+
1836
+ /************************************************************************/
1837
+
1838
+ /*
1839
+ * Security protocol.
1840
+ */
1841
+ struct JSPrincipals {
1842
+ char *codebase;
1843
+
1844
+ /* XXX unspecified and unused by Mozilla code -- can we remove these? */
1845
+ void * (* getPrincipalArray)(JSContext *cx, JSPrincipals *);
1846
+ JSBool (* globalPrivilegesEnabled)(JSContext *cx, JSPrincipals *);
1847
+
1848
+ /* Don't call "destroy"; use reference counting macros below. */
1849
+ jsrefcount refcount;
1850
+
1851
+ void (* destroy)(JSContext *cx, JSPrincipals *);
1852
+ JSBool (* subsume)(JSPrincipals *, JSPrincipals *);
1853
+ };
1854
+
1855
+ #ifdef JS_THREADSAFE
1856
+ #define JSPRINCIPALS_HOLD(cx, principals) JS_HoldPrincipals(cx,principals)
1857
+ #define JSPRINCIPALS_DROP(cx, principals) JS_DropPrincipals(cx,principals)
1858
+
1859
+ extern JS_PUBLIC_API(jsrefcount)
1860
+ JS_HoldPrincipals(JSContext *cx, JSPrincipals *principals);
1861
+
1862
+ extern JS_PUBLIC_API(jsrefcount)
1863
+ JS_DropPrincipals(JSContext *cx, JSPrincipals *principals);
1864
+
1865
+ #else
1866
+ #define JSPRINCIPALS_HOLD(cx, principals) (++(principals)->refcount)
1867
+ #define JSPRINCIPALS_DROP(cx, principals) \
1868
+ ((--(principals)->refcount == 0) \
1869
+ ? ((*(principals)->destroy)((cx), (principals)), 0) \
1870
+ : (principals)->refcount)
1871
+ #endif
1872
+
1873
+
1874
+ struct JSSecurityCallbacks {
1875
+ JSCheckAccessOp checkObjectAccess;
1876
+ JSPrincipalsTranscoder principalsTranscoder;
1877
+ JSObjectPrincipalsFinder findObjectPrincipals;
1878
+ };
1879
+
1880
+ extern JS_PUBLIC_API(JSSecurityCallbacks *)
1881
+ JS_SetRuntimeSecurityCallbacks(JSRuntime *rt, JSSecurityCallbacks *callbacks);
1882
+
1883
+ extern JS_PUBLIC_API(JSSecurityCallbacks *)
1884
+ JS_GetRuntimeSecurityCallbacks(JSRuntime *rt);
1885
+
1886
+ extern JS_PUBLIC_API(JSSecurityCallbacks *)
1887
+ JS_SetContextSecurityCallbacks(JSContext *cx, JSSecurityCallbacks *callbacks);
1888
+
1889
+ extern JS_PUBLIC_API(JSSecurityCallbacks *)
1890
+ JS_GetSecurityCallbacks(JSContext *cx);
1891
+
1892
+ /************************************************************************/
1893
+
1894
+ /*
1895
+ * Functions and scripts.
1896
+ */
1897
+ extern JS_PUBLIC_API(JSFunction *)
1898
+ JS_NewFunction(JSContext *cx, JSNative call, uintN nargs, uintN flags,
1899
+ JSObject *parent, const char *name);
1900
+
1901
+ extern JS_PUBLIC_API(JSObject *)
1902
+ JS_GetFunctionObject(JSFunction *fun);
1903
+
1904
+ /*
1905
+ * Deprecated, useful only for diagnostics. Use JS_GetFunctionId instead for
1906
+ * anonymous vs. "anonymous" disambiguation and Unicode fidelity.
1907
+ */
1908
+ extern JS_PUBLIC_API(const char *)
1909
+ JS_GetFunctionName(JSFunction *fun);
1910
+
1911
+ /*
1912
+ * Return the function's identifier as a JSString, or null if fun is unnamed.
1913
+ * The returned string lives as long as fun, so you don't need to root a saved
1914
+ * reference to it if fun is well-connected or rooted, and provided you bound
1915
+ * the use of the saved reference by fun's lifetime.
1916
+ *
1917
+ * Prefer JS_GetFunctionId over JS_GetFunctionName because it returns null for
1918
+ * truly anonymous functions, and because it doesn't chop to ISO-Latin-1 chars
1919
+ * from UTF-16-ish jschars.
1920
+ */
1921
+ extern JS_PUBLIC_API(JSString *)
1922
+ JS_GetFunctionId(JSFunction *fun);
1923
+
1924
+ /*
1925
+ * Return JSFUN_* flags for fun.
1926
+ */
1927
+ extern JS_PUBLIC_API(uintN)
1928
+ JS_GetFunctionFlags(JSFunction *fun);
1929
+
1930
+ /*
1931
+ * Return the arity (length) of fun.
1932
+ */
1933
+ extern JS_PUBLIC_API(uint16)
1934
+ JS_GetFunctionArity(JSFunction *fun);
1935
+
1936
+ /*
1937
+ * Infallible predicate to test whether obj is a function object (faster than
1938
+ * comparing obj's class name to "Function", but equivalent unless someone has
1939
+ * overwritten the "Function" identifier with a different constructor and then
1940
+ * created instances using that constructor that might be passed in as obj).
1941
+ */
1942
+ extern JS_PUBLIC_API(JSBool)
1943
+ JS_ObjectIsFunction(JSContext *cx, JSObject *obj);
1944
+
1945
+ extern JS_PUBLIC_API(JSBool)
1946
+ JS_DefineFunctions(JSContext *cx, JSObject *obj, JSFunctionSpec *fs);
1947
+
1948
+ extern JS_PUBLIC_API(JSFunction *)
1949
+ JS_DefineFunction(JSContext *cx, JSObject *obj, const char *name, JSNative call,
1950
+ uintN nargs, uintN attrs);
1951
+
1952
+ extern JS_PUBLIC_API(JSFunction *)
1953
+ JS_DefineUCFunction(JSContext *cx, JSObject *obj,
1954
+ const jschar *name, size_t namelen, JSNative call,
1955
+ uintN nargs, uintN attrs);
1956
+
1957
+ extern JS_PUBLIC_API(JSObject *)
1958
+ JS_CloneFunctionObject(JSContext *cx, JSObject *funobj, JSObject *parent);
1959
+
1960
+ /*
1961
+ * Given a buffer, return JS_FALSE if the buffer might become a valid
1962
+ * javascript statement with the addition of more lines. Otherwise return
1963
+ * JS_TRUE. The intent is to support interactive compilation - accumulate
1964
+ * lines in a buffer until JS_BufferIsCompilableUnit is true, then pass it to
1965
+ * the compiler.
1966
+ */
1967
+ extern JS_PUBLIC_API(JSBool)
1968
+ JS_BufferIsCompilableUnit(JSContext *cx, JSObject *obj,
1969
+ const char *bytes, size_t length);
1970
+
1971
+ /*
1972
+ * The JSScript objects returned by the following functions refer to string and
1973
+ * other kinds of literals, including doubles and RegExp objects. These
1974
+ * literals are vulnerable to garbage collection; to root script objects and
1975
+ * prevent literals from being collected, create a rootable object using
1976
+ * JS_NewScriptObject, and root the resulting object using JS_Add[Named]Root.
1977
+ */
1978
+ extern JS_PUBLIC_API(JSScript *)
1979
+ JS_CompileScript(JSContext *cx, JSObject *obj,
1980
+ const char *bytes, size_t length,
1981
+ const char *filename, uintN lineno);
1982
+
1983
+ extern JS_PUBLIC_API(JSScript *)
1984
+ JS_CompileScriptForPrincipals(JSContext *cx, JSObject *obj,
1985
+ JSPrincipals *principals,
1986
+ const char *bytes, size_t length,
1987
+ const char *filename, uintN lineno);
1988
+
1989
+ extern JS_PUBLIC_API(JSScript *)
1990
+ JS_CompileUCScript(JSContext *cx, JSObject *obj,
1991
+ const jschar *chars, size_t length,
1992
+ const char *filename, uintN lineno);
1993
+
1994
+ extern JS_PUBLIC_API(JSScript *)
1995
+ JS_CompileUCScriptForPrincipals(JSContext *cx, JSObject *obj,
1996
+ JSPrincipals *principals,
1997
+ const jschar *chars, size_t length,
1998
+ const char *filename, uintN lineno);
1999
+
2000
+ extern JS_PUBLIC_API(JSScript *)
2001
+ JS_CompileFile(JSContext *cx, JSObject *obj, const char *filename);
2002
+
2003
+ extern JS_PUBLIC_API(JSScript *)
2004
+ JS_CompileFileHandle(JSContext *cx, JSObject *obj, const char *filename,
2005
+ FILE *fh);
2006
+
2007
+ extern JS_PUBLIC_API(JSScript *)
2008
+ JS_CompileFileHandleForPrincipals(JSContext *cx, JSObject *obj,
2009
+ const char *filename, FILE *fh,
2010
+ JSPrincipals *principals);
2011
+
2012
+ /*
2013
+ * NB: you must use JS_NewScriptObject and root a pointer to its return value
2014
+ * in order to keep a JSScript and its atoms safe from garbage collection after
2015
+ * creating the script via JS_Compile* and before a JS_ExecuteScript* call.
2016
+ * E.g., and without error checks:
2017
+ *
2018
+ * JSScript *script = JS_CompileFile(cx, global, filename);
2019
+ * JSObject *scrobj = JS_NewScriptObject(cx, script);
2020
+ * JS_AddNamedRoot(cx, &scrobj, "scrobj");
2021
+ * do {
2022
+ * jsval result;
2023
+ * JS_ExecuteScript(cx, global, script, &result);
2024
+ * JS_GC();
2025
+ * } while (!JSVAL_IS_BOOLEAN(result) || JSVAL_TO_BOOLEAN(result));
2026
+ * JS_RemoveRoot(cx, &scrobj);
2027
+ */
2028
+ extern JS_PUBLIC_API(JSObject *)
2029
+ JS_NewScriptObject(JSContext *cx, JSScript *script);
2030
+
2031
+ /*
2032
+ * Infallible getter for a script's object. If JS_NewScriptObject has not been
2033
+ * called on script yet, the return value will be null.
2034
+ */
2035
+ extern JS_PUBLIC_API(JSObject *)
2036
+ JS_GetScriptObject(JSScript *script);
2037
+
2038
+ extern JS_PUBLIC_API(void)
2039
+ JS_DestroyScript(JSContext *cx, JSScript *script);
2040
+
2041
+ extern JS_PUBLIC_API(JSFunction *)
2042
+ JS_CompileFunction(JSContext *cx, JSObject *obj, const char *name,
2043
+ uintN nargs, const char **argnames,
2044
+ const char *bytes, size_t length,
2045
+ const char *filename, uintN lineno);
2046
+
2047
+ extern JS_PUBLIC_API(JSFunction *)
2048
+ JS_CompileFunctionForPrincipals(JSContext *cx, JSObject *obj,
2049
+ JSPrincipals *principals, const char *name,
2050
+ uintN nargs, const char **argnames,
2051
+ const char *bytes, size_t length,
2052
+ const char *filename, uintN lineno);
2053
+
2054
+ extern JS_PUBLIC_API(JSFunction *)
2055
+ JS_CompileUCFunction(JSContext *cx, JSObject *obj, const char *name,
2056
+ uintN nargs, const char **argnames,
2057
+ const jschar *chars, size_t length,
2058
+ const char *filename, uintN lineno);
2059
+
2060
+ extern JS_PUBLIC_API(JSFunction *)
2061
+ JS_CompileUCFunctionForPrincipals(JSContext *cx, JSObject *obj,
2062
+ JSPrincipals *principals, const char *name,
2063
+ uintN nargs, const char **argnames,
2064
+ const jschar *chars, size_t length,
2065
+ const char *filename, uintN lineno);
2066
+
2067
+ extern JS_PUBLIC_API(JSString *)
2068
+ JS_DecompileScript(JSContext *cx, JSScript *script, const char *name,
2069
+ uintN indent);
2070
+
2071
+ /*
2072
+ * API extension: OR this into indent to avoid pretty-printing the decompiled
2073
+ * source resulting from JS_DecompileFunction{,Body}.
2074
+ */
2075
+ #define JS_DONT_PRETTY_PRINT ((uintN)0x8000)
2076
+
2077
+ extern JS_PUBLIC_API(JSString *)
2078
+ JS_DecompileFunction(JSContext *cx, JSFunction *fun, uintN indent);
2079
+
2080
+ extern JS_PUBLIC_API(JSString *)
2081
+ JS_DecompileFunctionBody(JSContext *cx, JSFunction *fun, uintN indent);
2082
+
2083
+ /*
2084
+ * NB: JS_ExecuteScript, JS_ExecuteScriptPart, and the JS_Evaluate*Script*
2085
+ * quadruplets all use the obj parameter as the initial scope chain header,
2086
+ * the 'this' keyword value, and the variables object (ECMA parlance for where
2087
+ * 'var' and 'function' bind names) of the execution context for script.
2088
+ *
2089
+ * Using obj as the variables object is problematic if obj's parent (which is
2090
+ * the scope chain link; see JS_SetParent and JS_NewObject) is not null: in
2091
+ * this case, variables created by 'var x = 0', e.g., go in obj, but variables
2092
+ * created by assignment to an unbound id, 'x = 0', go in the last object on
2093
+ * the scope chain linked by parent.
2094
+ *
2095
+ * ECMA calls that last scoping object the "global object", but note that many
2096
+ * embeddings have several such objects. ECMA requires that "global code" be
2097
+ * executed with the variables object equal to this global object. But these
2098
+ * JS API entry points provide freedom to execute code against a "sub-global",
2099
+ * i.e., a parented or scoped object, in which case the variables object will
2100
+ * differ from the last object on the scope chain, resulting in confusing and
2101
+ * non-ECMA explicit vs. implicit variable creation.
2102
+ *
2103
+ * Caveat embedders: unless you already depend on this buggy variables object
2104
+ * binding behavior, you should call JS_SetOptions(cx, JSOPTION_VAROBJFIX) or
2105
+ * JS_SetOptions(cx, JS_GetOptions(cx) | JSOPTION_VAROBJFIX) -- the latter if
2106
+ * someone may have set other options on cx already -- for each context in the
2107
+ * application, if you pass parented objects as the obj parameter, or may ever
2108
+ * pass such objects in the future.
2109
+ *
2110
+ * Why a runtime option? The alternative is to add six or so new API entry
2111
+ * points with signatures matching the following six, and that doesn't seem
2112
+ * worth the code bloat cost. Such new entry points would probably have less
2113
+ * obvious names, too, so would not tend to be used. The JS_SetOption call,
2114
+ * OTOH, can be more easily hacked into existing code that does not depend on
2115
+ * the bug; such code can continue to use the familiar JS_EvaluateScript,
2116
+ * etc., entry points.
2117
+ */
2118
+ extern JS_PUBLIC_API(JSBool)
2119
+ JS_ExecuteScript(JSContext *cx, JSObject *obj, JSScript *script, jsval *rval);
2120
+
2121
+ /*
2122
+ * Execute either the function-defining prolog of a script, or the script's
2123
+ * main body, but not both.
2124
+ */
2125
+ typedef enum JSExecPart { JSEXEC_PROLOG, JSEXEC_MAIN } JSExecPart;
2126
+
2127
+ extern JS_PUBLIC_API(JSBool)
2128
+ JS_ExecuteScriptPart(JSContext *cx, JSObject *obj, JSScript *script,
2129
+ JSExecPart part, jsval *rval);
2130
+
2131
+ extern JS_PUBLIC_API(JSBool)
2132
+ JS_EvaluateScript(JSContext *cx, JSObject *obj,
2133
+ const char *bytes, uintN length,
2134
+ const char *filename, uintN lineno,
2135
+ jsval *rval);
2136
+
2137
+ extern JS_PUBLIC_API(JSBool)
2138
+ JS_EvaluateScriptForPrincipals(JSContext *cx, JSObject *obj,
2139
+ JSPrincipals *principals,
2140
+ const char *bytes, uintN length,
2141
+ const char *filename, uintN lineno,
2142
+ jsval *rval);
2143
+
2144
+ extern JS_PUBLIC_API(JSBool)
2145
+ JS_EvaluateUCScript(JSContext *cx, JSObject *obj,
2146
+ const jschar *chars, uintN length,
2147
+ const char *filename, uintN lineno,
2148
+ jsval *rval);
2149
+
2150
+ extern JS_PUBLIC_API(JSBool)
2151
+ JS_EvaluateUCScriptForPrincipals(JSContext *cx, JSObject *obj,
2152
+ JSPrincipals *principals,
2153
+ const jschar *chars, uintN length,
2154
+ const char *filename, uintN lineno,
2155
+ jsval *rval);
2156
+
2157
+ extern JS_PUBLIC_API(JSBool)
2158
+ JS_CallFunction(JSContext *cx, JSObject *obj, JSFunction *fun, uintN argc,
2159
+ jsval *argv, jsval *rval);
2160
+
2161
+ extern JS_PUBLIC_API(JSBool)
2162
+ JS_CallFunctionName(JSContext *cx, JSObject *obj, const char *name, uintN argc,
2163
+ jsval *argv, jsval *rval);
2164
+
2165
+ extern JS_PUBLIC_API(JSBool)
2166
+ JS_CallFunctionValue(JSContext *cx, JSObject *obj, jsval fval, uintN argc,
2167
+ jsval *argv, jsval *rval);
2168
+
2169
+ /*
2170
+ * The maximum value of the operation limit to pass to JS_SetOperationCallback
2171
+ * and JS_SetOperationLimit.
2172
+ */
2173
+ #define JS_MAX_OPERATION_LIMIT ((uint32) 0x7FFFFFFF)
2174
+
2175
+ #define JS_OPERATION_WEIGHT_BASE 4096
2176
+
2177
+ /*
2178
+ * Set the operation callback that the engine calls periodically after
2179
+ * the internal operation count reaches the specified limit.
2180
+ *
2181
+ * When operationLimit is JS_OPERATION_WEIGHT_BASE, the callback will be
2182
+ * called at least after each backward jump in the interpreter. To minimize
2183
+ * the overhead of the callback invocation we suggest at least
2184
+ *
2185
+ * 100 * JS_OPERATION_WEIGHT_BASE
2186
+ *
2187
+ * as a value for operationLimit.
2188
+ */
2189
+ extern JS_PUBLIC_API(void)
2190
+ JS_SetOperationCallback(JSContext *cx, JSOperationCallback callback,
2191
+ uint32 operationLimit);
2192
+
2193
+ extern JS_PUBLIC_API(void)
2194
+ JS_ClearOperationCallback(JSContext *cx);
2195
+
2196
+ extern JS_PUBLIC_API(JSOperationCallback)
2197
+ JS_GetOperationCallback(JSContext *cx);
2198
+
2199
+ /*
2200
+ * Get the operation limit associated with the operation callback. This API
2201
+ * function may be called only when the result of JS_GetOperationCallback(cx)
2202
+ * is not null.
2203
+ */
2204
+ extern JS_PUBLIC_API(uint32)
2205
+ JS_GetOperationLimit(JSContext *cx);
2206
+
2207
+ /*
2208
+ * Change the operation limit associated with the operation callback. This API
2209
+ * function may be called only when the result of JS_GetOperationCallback(cx)
2210
+ * is not null.
2211
+ */
2212
+ extern JS_PUBLIC_API(void)
2213
+ JS_SetOperationLimit(JSContext *cx, uint32 operationLimit);
2214
+
2215
+ /*
2216
+ * Note well: JS_SetBranchCallback is deprecated. It is similar to
2217
+ *
2218
+ * JS_SetOperationCallback(cx, callback, 4096, NULL);
2219
+ *
2220
+ * except that the callback will not be called from a long-running native
2221
+ * function when JSOPTION_NATIVE_BRANCH_CALLBACK is not set and the top-most
2222
+ * frame is native.
2223
+ */
2224
+ extern JS_PUBLIC_API(JSBranchCallback)
2225
+ JS_SetBranchCallback(JSContext *cx, JSBranchCallback cb);
2226
+
2227
+ extern JS_PUBLIC_API(JSBool)
2228
+ JS_IsRunning(JSContext *cx);
2229
+
2230
+ extern JS_PUBLIC_API(JSBool)
2231
+ JS_IsConstructing(JSContext *cx);
2232
+
2233
+ /*
2234
+ * Returns true if a script is executing and its current bytecode is a set
2235
+ * (assignment) operation, even if there are native (no script) stack frames
2236
+ * between the script and the caller to JS_IsAssigning.
2237
+ */
2238
+ extern JS_FRIEND_API(JSBool)
2239
+ JS_IsAssigning(JSContext *cx);
2240
+
2241
+ /*
2242
+ * Set the second return value, which should be a string or int jsval that
2243
+ * identifies a property in the returned object, to form an ECMA reference
2244
+ * type value (obj, id). Only native methods can return reference types,
2245
+ * and if the returned value is used on the left-hand side of an assignment
2246
+ * op, the identified property will be set. If the return value is in an
2247
+ * r-value, the interpreter just gets obj[id]'s value.
2248
+ */
2249
+ extern JS_PUBLIC_API(void)
2250
+ JS_SetCallReturnValue2(JSContext *cx, jsval v);
2251
+
2252
+ /*
2253
+ * Saving and restoring frame chains.
2254
+ *
2255
+ * These two functions are used to set aside cx's call stack while that stack
2256
+ * is inactive. After a call to JS_SaveFrameChain, it looks as if there is no
2257
+ * code running on cx. Before calling JS_RestoreFrameChain, cx's call stack
2258
+ * must be balanced and all nested calls to JS_SaveFrameChain must have had
2259
+ * matching JS_RestoreFrameChain calls.
2260
+ *
2261
+ * JS_SaveFrameChain deals with cx not having any code running on it. A null
2262
+ * return does not signify an error, and JS_RestoreFrameChain handles a null
2263
+ * frame pointer argument safely.
2264
+ */
2265
+ extern JS_PUBLIC_API(JSStackFrame *)
2266
+ JS_SaveFrameChain(JSContext *cx);
2267
+
2268
+ extern JS_PUBLIC_API(void)
2269
+ JS_RestoreFrameChain(JSContext *cx, JSStackFrame *fp);
2270
+
2271
+ /************************************************************************/
2272
+
2273
+ /*
2274
+ * Strings.
2275
+ *
2276
+ * NB: JS_NewString takes ownership of bytes on success, avoiding a copy; but
2277
+ * on error (signified by null return), it leaves bytes owned by the caller.
2278
+ * So the caller must free bytes in the error case, if it has no use for them.
2279
+ * In contrast, all the JS_New*StringCopy* functions do not take ownership of
2280
+ * the character memory passed to them -- they copy it.
2281
+ */
2282
+ extern JS_PUBLIC_API(JSString *)
2283
+ JS_NewString(JSContext *cx, char *bytes, size_t length);
2284
+
2285
+ extern JS_PUBLIC_API(JSString *)
2286
+ JS_NewStringCopyN(JSContext *cx, const char *s, size_t n);
2287
+
2288
+ extern JS_PUBLIC_API(JSString *)
2289
+ JS_NewStringCopyZ(JSContext *cx, const char *s);
2290
+
2291
+ extern JS_PUBLIC_API(JSString *)
2292
+ JS_InternString(JSContext *cx, const char *s);
2293
+
2294
+ extern JS_PUBLIC_API(JSString *)
2295
+ JS_NewUCString(JSContext *cx, jschar *chars, size_t length);
2296
+
2297
+ extern JS_PUBLIC_API(JSString *)
2298
+ JS_NewUCStringCopyN(JSContext *cx, const jschar *s, size_t n);
2299
+
2300
+ extern JS_PUBLIC_API(JSString *)
2301
+ JS_NewUCStringCopyZ(JSContext *cx, const jschar *s);
2302
+
2303
+ extern JS_PUBLIC_API(JSString *)
2304
+ JS_InternUCStringN(JSContext *cx, const jschar *s, size_t length);
2305
+
2306
+ extern JS_PUBLIC_API(JSString *)
2307
+ JS_InternUCString(JSContext *cx, const jschar *s);
2308
+
2309
+ extern JS_PUBLIC_API(char *)
2310
+ JS_GetStringBytes(JSString *str);
2311
+
2312
+ extern JS_PUBLIC_API(jschar *)
2313
+ JS_GetStringChars(JSString *str);
2314
+
2315
+ extern JS_PUBLIC_API(size_t)
2316
+ JS_GetStringLength(JSString *str);
2317
+
2318
+ extern JS_PUBLIC_API(intN)
2319
+ JS_CompareStrings(JSString *str1, JSString *str2);
2320
+
2321
+ /*
2322
+ * Mutable string support. A string's characters are never mutable in this JS
2323
+ * implementation, but a growable string has a buffer that can be reallocated,
2324
+ * and a dependent string is a substring of another (growable, dependent, or
2325
+ * immutable) string. The direct data members of the (opaque to API clients)
2326
+ * JSString struct may be changed in a single-threaded way for growable and
2327
+ * dependent strings.
2328
+ *
2329
+ * Therefore mutable strings cannot be used by more than one thread at a time.
2330
+ * You may call JS_MakeStringImmutable to convert the string from a mutable
2331
+ * (growable or dependent) string to an immutable (and therefore thread-safe)
2332
+ * string. The engine takes care of converting growable and dependent strings
2333
+ * to immutable for you if you store strings in multi-threaded objects using
2334
+ * JS_SetProperty or kindred API entry points.
2335
+ *
2336
+ * If you store a JSString pointer in a native data structure that is (safely)
2337
+ * accessible to multiple threads, you must call JS_MakeStringImmutable before
2338
+ * retiring the store.
2339
+ */
2340
+ extern JS_PUBLIC_API(JSString *)
2341
+ JS_NewGrowableString(JSContext *cx, jschar *chars, size_t length);
2342
+
2343
+ /*
2344
+ * Create a dependent string, i.e., a string that owns no character storage,
2345
+ * but that refers to a slice of another string's chars. Dependent strings
2346
+ * are mutable by definition, so the thread safety comments above apply.
2347
+ */
2348
+ extern JS_PUBLIC_API(JSString *)
2349
+ JS_NewDependentString(JSContext *cx, JSString *str, size_t start,
2350
+ size_t length);
2351
+
2352
+ /*
2353
+ * Concatenate two strings, resulting in a new growable string. If you create
2354
+ * the left string and pass it to JS_ConcatStrings on a single thread, try to
2355
+ * use JS_NewGrowableString to create the left string -- doing so helps Concat
2356
+ * avoid allocating a new buffer for the result and copying left's chars into
2357
+ * the new buffer. See above for thread safety comments.
2358
+ */
2359
+ extern JS_PUBLIC_API(JSString *)
2360
+ JS_ConcatStrings(JSContext *cx, JSString *left, JSString *right);
2361
+
2362
+ /*
2363
+ * Convert a dependent string into an independent one. This function does not
2364
+ * change the string's mutability, so the thread safety comments above apply.
2365
+ */
2366
+ extern JS_PUBLIC_API(const jschar *)
2367
+ JS_UndependString(JSContext *cx, JSString *str);
2368
+
2369
+ /*
2370
+ * Convert a mutable string (either growable or dependent) into an immutable,
2371
+ * thread-safe one.
2372
+ */
2373
+ extern JS_PUBLIC_API(JSBool)
2374
+ JS_MakeStringImmutable(JSContext *cx, JSString *str);
2375
+
2376
+ /*
2377
+ * Return JS_TRUE if C (char []) strings passed via the API and internally
2378
+ * are UTF-8.
2379
+ */
2380
+ JS_PUBLIC_API(JSBool)
2381
+ JS_CStringsAreUTF8(void);
2382
+
2383
+ /*
2384
+ * Update the value to be returned by JS_CStringsAreUTF8(). Once set, it
2385
+ * can never be changed. This API must be called before the first call to
2386
+ * JS_NewRuntime.
2387
+ */
2388
+ JS_PUBLIC_API(void)
2389
+ JS_SetCStringsAreUTF8(void);
2390
+
2391
+ /*
2392
+ * Character encoding support.
2393
+ *
2394
+ * For both JS_EncodeCharacters and JS_DecodeBytes, set *dstlenp to the size
2395
+ * of the destination buffer before the call; on return, *dstlenp contains the
2396
+ * number of bytes (JS_EncodeCharacters) or jschars (JS_DecodeBytes) actually
2397
+ * stored. To determine the necessary destination buffer size, make a sizing
2398
+ * call that passes NULL for dst.
2399
+ *
2400
+ * On errors, the functions report the error. In that case, *dstlenp contains
2401
+ * the number of characters or bytes transferred so far. If cx is NULL, no
2402
+ * error is reported on failure, and the functions simply return JS_FALSE.
2403
+ *
2404
+ * NB: Neither function stores an additional zero byte or jschar after the
2405
+ * transcoded string.
2406
+ *
2407
+ * If JS_CStringsAreUTF8() is true then JS_EncodeCharacters encodes to
2408
+ * UTF-8, and JS_DecodeBytes decodes from UTF-8, which may create additional
2409
+ * errors if the character sequence is malformed. If UTF-8 support is
2410
+ * disabled, the functions deflate and inflate, respectively.
2411
+ */
2412
+ JS_PUBLIC_API(JSBool)
2413
+ JS_EncodeCharacters(JSContext *cx, const jschar *src, size_t srclen, char *dst,
2414
+ size_t *dstlenp);
2415
+
2416
+ JS_PUBLIC_API(JSBool)
2417
+ JS_DecodeBytes(JSContext *cx, const char *src, size_t srclen, jschar *dst,
2418
+ size_t *dstlenp);
2419
+
2420
+ /*
2421
+ * A variation on JS_EncodeCharacters where a null terminated string is
2422
+ * returned that you are expected to call JS_free on when done.
2423
+ */
2424
+ JS_PUBLIC_API(char *)
2425
+ JS_EncodeString(JSContext *cx, JSString *str);
2426
+
2427
+ /************************************************************************/
2428
+ /*
2429
+ * JSON functions
2430
+ */
2431
+ typedef JSBool (* JSONWriteCallback)(const jschar *buf, uint32 len, void *data);
2432
+
2433
+ /*
2434
+ * JSON.stringify as specificed by ES3.1 (draft)
2435
+ */
2436
+ JS_PUBLIC_API(JSBool)
2437
+ JS_Stringify(JSContext *cx, jsval *vp, JSObject *replacer,
2438
+ JSONWriteCallback callback, void *data);
2439
+
2440
+ /*
2441
+ * Retrieve a toJSON function. If found, set vp to its result.
2442
+ */
2443
+ JS_PUBLIC_API(JSBool)
2444
+ JS_TryJSON(JSContext *cx, jsval *vp);
2445
+
2446
+ /*
2447
+ * JSON.parse as specificed by ES3.1 (draft)
2448
+ */
2449
+ JS_PUBLIC_API(JSONParser *)
2450
+ JS_BeginJSONParse(JSContext *cx, jsval *vp);
2451
+
2452
+ JS_PUBLIC_API(JSBool)
2453
+ JS_ConsumeJSONText(JSContext *cx, JSONParser *jp, const jschar *data, uint32 len);
2454
+
2455
+ JS_PUBLIC_API(JSBool)
2456
+ JS_FinishJSONParse(JSContext *cx, JSONParser *jp);
2457
+
2458
+ /************************************************************************/
2459
+
2460
+ /*
2461
+ * Locale specific string conversion and error message callbacks.
2462
+ */
2463
+ struct JSLocaleCallbacks {
2464
+ JSLocaleToUpperCase localeToUpperCase;
2465
+ JSLocaleToLowerCase localeToLowerCase;
2466
+ JSLocaleCompare localeCompare;
2467
+ JSLocaleToUnicode localeToUnicode;
2468
+ JSErrorCallback localeGetErrorMessage;
2469
+ };
2470
+
2471
+ /*
2472
+ * Establish locale callbacks. The pointer must persist as long as the
2473
+ * JSContext. Passing NULL restores the default behaviour.
2474
+ */
2475
+ extern JS_PUBLIC_API(void)
2476
+ JS_SetLocaleCallbacks(JSContext *cx, JSLocaleCallbacks *callbacks);
2477
+
2478
+ /*
2479
+ * Return the address of the current locale callbacks struct, which may
2480
+ * be NULL.
2481
+ */
2482
+ extern JS_PUBLIC_API(JSLocaleCallbacks *)
2483
+ JS_GetLocaleCallbacks(JSContext *cx);
2484
+
2485
+ /************************************************************************/
2486
+
2487
+ /*
2488
+ * Error reporting.
2489
+ */
2490
+
2491
+ /*
2492
+ * Report an exception represented by the sprintf-like conversion of format
2493
+ * and its arguments. This exception message string is passed to a pre-set
2494
+ * JSErrorReporter function (set by JS_SetErrorReporter; see jspubtd.h for
2495
+ * the JSErrorReporter typedef).
2496
+ */
2497
+ extern JS_PUBLIC_API(void)
2498
+ JS_ReportError(JSContext *cx, const char *format, ...);
2499
+
2500
+ /*
2501
+ * Use an errorNumber to retrieve the format string, args are char *
2502
+ */
2503
+ extern JS_PUBLIC_API(void)
2504
+ JS_ReportErrorNumber(JSContext *cx, JSErrorCallback errorCallback,
2505
+ void *userRef, const uintN errorNumber, ...);
2506
+
2507
+ /*
2508
+ * Use an errorNumber to retrieve the format string, args are jschar *
2509
+ */
2510
+ extern JS_PUBLIC_API(void)
2511
+ JS_ReportErrorNumberUC(JSContext *cx, JSErrorCallback errorCallback,
2512
+ void *userRef, const uintN errorNumber, ...);
2513
+
2514
+ /*
2515
+ * As above, but report a warning instead (JSREPORT_IS_WARNING(report.flags)).
2516
+ * Return true if there was no error trying to issue the warning, and if the
2517
+ * warning was not converted into an error due to the JSOPTION_WERROR option
2518
+ * being set, false otherwise.
2519
+ */
2520
+ extern JS_PUBLIC_API(JSBool)
2521
+ JS_ReportWarning(JSContext *cx, const char *format, ...);
2522
+
2523
+ extern JS_PUBLIC_API(JSBool)
2524
+ JS_ReportErrorFlagsAndNumber(JSContext *cx, uintN flags,
2525
+ JSErrorCallback errorCallback, void *userRef,
2526
+ const uintN errorNumber, ...);
2527
+
2528
+ extern JS_PUBLIC_API(JSBool)
2529
+ JS_ReportErrorFlagsAndNumberUC(JSContext *cx, uintN flags,
2530
+ JSErrorCallback errorCallback, void *userRef,
2531
+ const uintN errorNumber, ...);
2532
+
2533
+ /*
2534
+ * Complain when out of memory.
2535
+ */
2536
+ extern JS_PUBLIC_API(void)
2537
+ JS_ReportOutOfMemory(JSContext *cx);
2538
+
2539
+ /*
2540
+ * Complain when an allocation size overflows the maximum supported limit.
2541
+ */
2542
+ extern JS_PUBLIC_API(void)
2543
+ JS_ReportAllocationOverflow(JSContext *cx);
2544
+
2545
+ struct JSErrorReport {
2546
+ const char *filename; /* source file name, URL, etc., or null */
2547
+ uintN lineno; /* source line number */
2548
+ const char *linebuf; /* offending source line without final \n */
2549
+ const char *tokenptr; /* pointer to error token in linebuf */
2550
+ const jschar *uclinebuf; /* unicode (original) line buffer */
2551
+ const jschar *uctokenptr; /* unicode (original) token pointer */
2552
+ uintN flags; /* error/warning, etc. */
2553
+ uintN errorNumber; /* the error number, e.g. see js.msg */
2554
+ const jschar *ucmessage; /* the (default) error message */
2555
+ const jschar **messageArgs; /* arguments for the error message */
2556
+ };
2557
+
2558
+ /*
2559
+ * JSErrorReport flag values. These may be freely composed.
2560
+ */
2561
+ #define JSREPORT_ERROR 0x0 /* pseudo-flag for default case */
2562
+ #define JSREPORT_WARNING 0x1 /* reported via JS_ReportWarning */
2563
+ #define JSREPORT_EXCEPTION 0x2 /* exception was thrown */
2564
+ #define JSREPORT_STRICT 0x4 /* error or warning due to strict option */
2565
+
2566
+ /*
2567
+ * If JSREPORT_EXCEPTION is set, then a JavaScript-catchable exception
2568
+ * has been thrown for this runtime error, and the host should ignore it.
2569
+ * Exception-aware hosts should also check for JS_IsExceptionPending if
2570
+ * JS_ExecuteScript returns failure, and signal or propagate the exception, as
2571
+ * appropriate.
2572
+ */
2573
+ #define JSREPORT_IS_WARNING(flags) (((flags) & JSREPORT_WARNING) != 0)
2574
+ #define JSREPORT_IS_EXCEPTION(flags) (((flags) & JSREPORT_EXCEPTION) != 0)
2575
+ #define JSREPORT_IS_STRICT(flags) (((flags) & JSREPORT_STRICT) != 0)
2576
+
2577
+ extern JS_PUBLIC_API(JSErrorReporter)
2578
+ JS_SetErrorReporter(JSContext *cx, JSErrorReporter er);
2579
+
2580
+ /************************************************************************/
2581
+
2582
+ /*
2583
+ * Regular Expressions.
2584
+ */
2585
+ #define JSREG_FOLD 0x01 /* fold uppercase to lowercase */
2586
+ #define JSREG_GLOB 0x02 /* global exec, creates array of matches */
2587
+ #define JSREG_MULTILINE 0x04 /* treat ^ and $ as begin and end of line */
2588
+ #define JSREG_STICKY 0x08 /* only match starting at lastIndex */
2589
+
2590
+ extern JS_PUBLIC_API(JSObject *)
2591
+ JS_NewRegExpObject(JSContext *cx, char *bytes, size_t length, uintN flags);
2592
+
2593
+ extern JS_PUBLIC_API(JSObject *)
2594
+ JS_NewUCRegExpObject(JSContext *cx, jschar *chars, size_t length, uintN flags);
2595
+
2596
+ extern JS_PUBLIC_API(void)
2597
+ JS_SetRegExpInput(JSContext *cx, JSString *input, JSBool multiline);
2598
+
2599
+ extern JS_PUBLIC_API(void)
2600
+ JS_ClearRegExpStatics(JSContext *cx);
2601
+
2602
+ extern JS_PUBLIC_API(void)
2603
+ JS_ClearRegExpRoots(JSContext *cx);
2604
+
2605
+ /* TODO: compile, exec, get/set other statics... */
2606
+
2607
+ /************************************************************************/
2608
+
2609
+ extern JS_PUBLIC_API(JSBool)
2610
+ JS_IsExceptionPending(JSContext *cx);
2611
+
2612
+ extern JS_PUBLIC_API(JSBool)
2613
+ JS_GetPendingException(JSContext *cx, jsval *vp);
2614
+
2615
+ extern JS_PUBLIC_API(void)
2616
+ JS_SetPendingException(JSContext *cx, jsval v);
2617
+
2618
+ extern JS_PUBLIC_API(void)
2619
+ JS_ClearPendingException(JSContext *cx);
2620
+
2621
+ extern JS_PUBLIC_API(JSBool)
2622
+ JS_ReportPendingException(JSContext *cx);
2623
+
2624
+ /*
2625
+ * Save the current exception state. This takes a snapshot of cx's current
2626
+ * exception state without making any change to that state.
2627
+ *
2628
+ * The returned state pointer MUST be passed later to JS_RestoreExceptionState
2629
+ * (to restore that saved state, overriding any more recent state) or else to
2630
+ * JS_DropExceptionState (to free the state struct in case it is not correct
2631
+ * or desirable to restore it). Both Restore and Drop free the state struct,
2632
+ * so callers must stop using the pointer returned from Save after calling the
2633
+ * Release or Drop API.
2634
+ */
2635
+ extern JS_PUBLIC_API(JSExceptionState *)
2636
+ JS_SaveExceptionState(JSContext *cx);
2637
+
2638
+ extern JS_PUBLIC_API(void)
2639
+ JS_RestoreExceptionState(JSContext *cx, JSExceptionState *state);
2640
+
2641
+ extern JS_PUBLIC_API(void)
2642
+ JS_DropExceptionState(JSContext *cx, JSExceptionState *state);
2643
+
2644
+ /*
2645
+ * If the given value is an exception object that originated from an error,
2646
+ * the exception will contain an error report struct, and this API will return
2647
+ * the address of that struct. Otherwise, it returns NULL. The lifetime of
2648
+ * the error report struct that might be returned is the same as the lifetime
2649
+ * of the exception object.
2650
+ */
2651
+ extern JS_PUBLIC_API(JSErrorReport *)
2652
+ JS_ErrorFromException(JSContext *cx, jsval v);
2653
+
2654
+ /*
2655
+ * Given a reported error's message and JSErrorReport struct pointer, throw
2656
+ * the corresponding exception on cx.
2657
+ */
2658
+ extern JS_PUBLIC_API(JSBool)
2659
+ JS_ThrowReportedError(JSContext *cx, const char *message,
2660
+ JSErrorReport *reportp);
2661
+
2662
+ /*
2663
+ * Throws a StopIteration exception on cx.
2664
+ */
2665
+ extern JS_PUBLIC_API(JSBool)
2666
+ JS_ThrowStopIteration(JSContext *cx);
2667
+
2668
+ /*
2669
+ * Associate the current thread with the given context. This is done
2670
+ * implicitly by JS_NewContext.
2671
+ *
2672
+ * Returns the old thread id for this context, which should be treated as
2673
+ * an opaque value. This value is provided for comparison to 0, which
2674
+ * indicates that ClearContextThread has been called on this context
2675
+ * since the last SetContextThread, or non-0, which indicates the opposite.
2676
+ */
2677
+ extern JS_PUBLIC_API(jsword)
2678
+ JS_GetContextThread(JSContext *cx);
2679
+
2680
+ extern JS_PUBLIC_API(jsword)
2681
+ JS_SetContextThread(JSContext *cx);
2682
+
2683
+ extern JS_PUBLIC_API(jsword)
2684
+ JS_ClearContextThread(JSContext *cx);
2685
+
2686
+ /************************************************************************/
2687
+
2688
+ #ifdef DEBUG
2689
+ #define JS_GC_ZEAL 1
2690
+ #endif
2691
+
2692
+ #ifdef JS_GC_ZEAL
2693
+ extern JS_PUBLIC_API(void)
2694
+ JS_SetGCZeal(JSContext *cx, uint8 zeal);
2695
+ #endif
2696
+
2697
+ JS_END_EXTERN_C
2698
+
2699
+ #endif /* jsapi_h___ */