@everyonesoftware/common 12.0.0 → 14.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (773) hide show
  1. package/outputs/sources/ANSIStyles.d.ts +10 -0
  2. package/outputs/sources/ANSIStyles.d.ts.map +1 -0
  3. package/outputs/sources/ANSIStyles.js +23 -0
  4. package/outputs/sources/ANSIStyles.js.map +1 -0
  5. package/outputs/sources/CharacterTable.d.ts +11 -0
  6. package/outputs/sources/CharacterTable.d.ts.map +1 -0
  7. package/outputs/sources/CharacterTable.js +28 -0
  8. package/outputs/sources/CharacterTable.js.map +1 -0
  9. package/outputs/sources/Clock.d.ts +12 -0
  10. package/outputs/sources/Clock.d.ts.map +1 -0
  11. package/outputs/sources/Clock.js +10 -0
  12. package/outputs/sources/Clock.js.map +1 -0
  13. package/outputs/sources/FetchError.d.ts +7 -0
  14. package/outputs/sources/FetchError.d.ts.map +1 -0
  15. package/outputs/sources/FetchError.js +20 -0
  16. package/outputs/sources/FetchError.js.map +1 -0
  17. package/outputs/sources/HttpRequestHandler.d.ts +8 -0
  18. package/outputs/sources/HttpRequestHandler.d.ts.map +1 -0
  19. package/outputs/sources/HttpRequestHandler.js +2 -0
  20. package/outputs/sources/HttpRequestHandler.js.map +1 -0
  21. package/outputs/sources/IndentedCharacterWriteStream.d.ts +21 -0
  22. package/outputs/sources/IndentedCharacterWriteStream.d.ts.map +1 -0
  23. package/outputs/sources/IndentedCharacterWriteStream.js +110 -0
  24. package/outputs/sources/IndentedCharacterWriteStream.js.map +1 -0
  25. package/outputs/sources/Indexable.d.ts +51 -0
  26. package/outputs/sources/Indexable.d.ts.map +1 -0
  27. package/outputs/sources/Indexable.js +122 -0
  28. package/outputs/sources/Indexable.js.map +1 -0
  29. package/outputs/sources/MutableIndexable.d.ts +51 -0
  30. package/outputs/sources/MutableIndexable.d.ts.map +1 -0
  31. package/outputs/sources/MutableIndexable.js +96 -0
  32. package/outputs/sources/MutableIndexable.js.map +1 -0
  33. package/outputs/sources/NodeJSHttpOutgoingResponse.d.ts +25 -0
  34. package/outputs/sources/NodeJSHttpOutgoingResponse.d.ts.map +1 -0
  35. package/outputs/sources/NodeJSHttpOutgoingResponse.js +77 -0
  36. package/outputs/sources/NodeJSHttpOutgoingResponse.js.map +1 -0
  37. package/outputs/sources/RealClock.d.ts +11 -0
  38. package/outputs/sources/RealClock.d.ts.map +1 -0
  39. package/outputs/sources/RealClock.js +15 -0
  40. package/outputs/sources/RealClock.js.map +1 -0
  41. package/outputs/sources/Token.d.ts +31 -0
  42. package/outputs/sources/Token.d.ts.map +1 -0
  43. package/outputs/sources/Token.js +80 -0
  44. package/outputs/sources/Token.js.map +1 -0
  45. package/outputs/sources/TokenType.d.ts +19 -0
  46. package/outputs/sources/TokenType.d.ts.map +1 -0
  47. package/outputs/sources/TokenType.js +27 -0
  48. package/outputs/sources/TokenType.js.map +1 -0
  49. package/outputs/sources/Tokenizer.d.ts +37 -0
  50. package/outputs/sources/Tokenizer.d.ts.map +1 -0
  51. package/outputs/sources/Tokenizer.js +163 -0
  52. package/outputs/sources/Tokenizer.js.map +1 -0
  53. package/outputs/sources/assertMessageParameters.d.ts +22 -0
  54. package/outputs/sources/assertMessageParameters.d.ts.map +1 -0
  55. package/outputs/sources/assertMessageParameters.js +2 -0
  56. package/outputs/sources/assertMessageParameters.js.map +1 -0
  57. package/outputs/sources/asyncIterator.d.ts +155 -0
  58. package/outputs/sources/asyncIterator.d.ts.map +1 -0
  59. package/outputs/sources/asyncIterator.js +303 -0
  60. package/outputs/sources/asyncIterator.js.map +1 -0
  61. package/outputs/sources/asyncIteratorToJavascriptAsyncIteratorAdapter.d.ts +13 -0
  62. package/outputs/sources/asyncIteratorToJavascriptAsyncIteratorAdapter.d.ts.map +1 -0
  63. package/outputs/sources/asyncIteratorToJavascriptAsyncIteratorAdapter.js +34 -0
  64. package/outputs/sources/asyncIteratorToJavascriptAsyncIteratorAdapter.js.map +1 -0
  65. package/outputs/sources/asyncResult.d.ts +73 -0
  66. package/outputs/sources/asyncResult.d.ts.map +1 -0
  67. package/outputs/sources/asyncResult.js +33 -0
  68. package/outputs/sources/asyncResult.js.map +1 -0
  69. package/outputs/sources/basicDisposable.d.ts +21 -0
  70. package/outputs/sources/basicDisposable.d.ts.map +1 -0
  71. package/outputs/sources/basicDisposable.js +42 -0
  72. package/outputs/sources/basicDisposable.js.map +1 -0
  73. package/outputs/sources/byteList.d.ts +43 -0
  74. package/outputs/sources/byteList.d.ts.map +1 -0
  75. package/outputs/sources/byteList.js +128 -0
  76. package/outputs/sources/byteList.js.map +1 -0
  77. package/outputs/sources/byteListStream.d.ts +20 -0
  78. package/outputs/sources/byteListStream.d.ts.map +1 -0
  79. package/outputs/sources/byteListStream.js +84 -0
  80. package/outputs/sources/byteListStream.js.map +1 -0
  81. package/outputs/sources/byteReadStream.d.ts +23 -0
  82. package/outputs/sources/byteReadStream.d.ts.map +1 -0
  83. package/outputs/sources/byteReadStream.js +6 -0
  84. package/outputs/sources/byteReadStream.js.map +1 -0
  85. package/outputs/sources/byteWriteStream.d.ts +15 -0
  86. package/outputs/sources/byteWriteStream.d.ts.map +1 -0
  87. package/outputs/sources/byteWriteStream.js +6 -0
  88. package/outputs/sources/byteWriteStream.js.map +1 -0
  89. package/outputs/sources/bytes.d.ts +20 -0
  90. package/outputs/sources/bytes.d.ts.map +1 -0
  91. package/outputs/sources/bytes.js +22 -0
  92. package/outputs/sources/bytes.js.map +1 -0
  93. package/outputs/sources/characterList.d.ts +39 -0
  94. package/outputs/sources/characterList.d.ts.map +1 -0
  95. package/outputs/sources/characterList.js +122 -0
  96. package/outputs/sources/characterList.js.map +1 -0
  97. package/outputs/sources/characterListStream.d.ts +27 -0
  98. package/outputs/sources/characterListStream.d.ts.map +1 -0
  99. package/outputs/sources/characterListStream.js +103 -0
  100. package/outputs/sources/characterListStream.js.map +1 -0
  101. package/outputs/sources/characterReadStream.d.ts +25 -0
  102. package/outputs/sources/characterReadStream.d.ts.map +1 -0
  103. package/outputs/sources/characterReadStream.js +57 -0
  104. package/outputs/sources/characterReadStream.js.map +1 -0
  105. package/outputs/sources/characterReadStreamIterator.d.ts +31 -0
  106. package/outputs/sources/characterReadStreamIterator.d.ts.map +1 -0
  107. package/outputs/sources/characterReadStreamIterator.js +79 -0
  108. package/outputs/sources/characterReadStreamIterator.js.map +1 -0
  109. package/outputs/sources/characterWriteStream.d.ts +18 -0
  110. package/outputs/sources/characterWriteStream.d.ts.map +1 -0
  111. package/outputs/sources/characterWriteStream.js +27 -0
  112. package/outputs/sources/characterWriteStream.js.map +1 -0
  113. package/outputs/sources/commandLineParameter.d.ts +30 -0
  114. package/outputs/sources/commandLineParameter.d.ts.map +1 -0
  115. package/outputs/sources/commandLineParameter.js +73 -0
  116. package/outputs/sources/commandLineParameter.js.map +1 -0
  117. package/outputs/sources/commandLineParameters.d.ts +23 -0
  118. package/outputs/sources/commandLineParameters.d.ts.map +1 -0
  119. package/outputs/sources/commandLineParameters.js +82 -0
  120. package/outputs/sources/commandLineParameters.js.map +1 -0
  121. package/outputs/sources/comparable.d.ts +79 -0
  122. package/outputs/sources/comparable.d.ts.map +1 -0
  123. package/outputs/sources/comparable.js +106 -0
  124. package/outputs/sources/comparable.js.map +1 -0
  125. package/outputs/sources/comparer.d.ts +62 -0
  126. package/outputs/sources/comparer.d.ts.map +1 -0
  127. package/outputs/sources/comparer.js +102 -0
  128. package/outputs/sources/comparer.js.map +1 -0
  129. package/outputs/sources/comparison.d.ts +18 -0
  130. package/outputs/sources/comparison.d.ts.map +1 -0
  131. package/outputs/sources/comparison.js +19 -0
  132. package/outputs/sources/comparison.js.map +1 -0
  133. package/outputs/sources/concatenateIterable.d.ts +28 -0
  134. package/outputs/sources/concatenateIterable.d.ts.map +1 -0
  135. package/outputs/sources/concatenateIterable.js +74 -0
  136. package/outputs/sources/concatenateIterable.js.map +1 -0
  137. package/outputs/sources/concatenateIterator.d.ts +30 -0
  138. package/outputs/sources/concatenateIterator.d.ts.map +1 -0
  139. package/outputs/sources/concatenateIterator.js +104 -0
  140. package/outputs/sources/concatenateIterator.js.map +1 -0
  141. package/outputs/sources/condition.d.ts +248 -0
  142. package/outputs/sources/condition.d.ts.map +1 -0
  143. package/outputs/sources/condition.js +166 -0
  144. package/outputs/sources/condition.js.map +1 -0
  145. package/outputs/sources/currentProcess.d.ts +31 -0
  146. package/outputs/sources/currentProcess.d.ts.map +1 -0
  147. package/outputs/sources/currentProcess.js +106 -0
  148. package/outputs/sources/currentProcess.js.map +1 -0
  149. package/outputs/sources/dateTime.d.ts +44 -0
  150. package/outputs/sources/dateTime.d.ts.map +1 -0
  151. package/outputs/sources/dateTime.js +76 -0
  152. package/outputs/sources/dateTime.js.map +1 -0
  153. package/outputs/sources/depthFirstSearch.d.ts +9 -0
  154. package/outputs/sources/depthFirstSearch.d.ts.map +1 -0
  155. package/outputs/sources/depthFirstSearch.js +148 -0
  156. package/outputs/sources/depthFirstSearch.js.map +1 -0
  157. package/outputs/sources/disposable.d.ts +25 -0
  158. package/outputs/sources/disposable.d.ts.map +1 -0
  159. package/outputs/sources/disposable.js +16 -0
  160. package/outputs/sources/disposable.js.map +1 -0
  161. package/outputs/sources/emptyError.d.ts +7 -0
  162. package/outputs/sources/emptyError.d.ts.map +1 -0
  163. package/outputs/sources/emptyError.js +9 -0
  164. package/outputs/sources/emptyError.js.map +1 -0
  165. package/outputs/sources/english.d.ts +4 -0
  166. package/outputs/sources/english.d.ts.map +1 -0
  167. package/outputs/sources/english.js +33 -0
  168. package/outputs/sources/english.js.map +1 -0
  169. package/outputs/sources/equalFunctions.d.ts +18 -0
  170. package/outputs/sources/equalFunctions.d.ts.map +1 -0
  171. package/outputs/sources/equalFunctions.js +88 -0
  172. package/outputs/sources/equalFunctions.js.map +1 -0
  173. package/outputs/sources/fetchHttpClient.d.ts +16 -0
  174. package/outputs/sources/fetchHttpClient.d.ts.map +1 -0
  175. package/outputs/sources/fetchHttpClient.js +86 -0
  176. package/outputs/sources/fetchHttpClient.js.map +1 -0
  177. package/outputs/sources/fetchHttpResponse.d.ts +19 -0
  178. package/outputs/sources/fetchHttpResponse.d.ts.map +1 -0
  179. package/outputs/sources/fetchHttpResponse.js +72 -0
  180. package/outputs/sources/fetchHttpResponse.js.map +1 -0
  181. package/outputs/sources/flatMapIterable.d.ts +29 -0
  182. package/outputs/sources/flatMapIterable.d.ts.map +1 -0
  183. package/outputs/sources/flatMapIterable.js +61 -0
  184. package/outputs/sources/flatMapIterable.js.map +1 -0
  185. package/outputs/sources/flatMapIterator.d.ts +33 -0
  186. package/outputs/sources/flatMapIterator.d.ts.map +1 -0
  187. package/outputs/sources/flatMapIterator.js +95 -0
  188. package/outputs/sources/flatMapIterator.js.map +1 -0
  189. package/outputs/sources/generator.d.ts +55 -0
  190. package/outputs/sources/generator.d.ts.map +1 -0
  191. package/outputs/sources/generator.js +139 -0
  192. package/outputs/sources/generator.js.map +1 -0
  193. package/outputs/sources/httpClient.d.ts +21 -0
  194. package/outputs/sources/httpClient.d.ts.map +1 -0
  195. package/outputs/sources/httpClient.js +22 -0
  196. package/outputs/sources/httpClient.js.map +1 -0
  197. package/outputs/sources/httpHeader.d.ts +10 -0
  198. package/outputs/sources/httpHeader.d.ts.map +1 -0
  199. package/outputs/sources/httpHeader.js +25 -0
  200. package/outputs/sources/httpHeader.js.map +1 -0
  201. package/outputs/sources/httpHeaders.d.ts +68 -0
  202. package/outputs/sources/httpHeaders.d.ts.map +1 -0
  203. package/outputs/sources/httpHeaders.js +122 -0
  204. package/outputs/sources/httpHeaders.js.map +1 -0
  205. package/outputs/sources/httpIncomingRequest.d.ts +40 -0
  206. package/outputs/sources/httpIncomingRequest.d.ts.map +1 -0
  207. package/outputs/sources/httpIncomingRequest.js +6 -0
  208. package/outputs/sources/httpIncomingRequest.js.map +1 -0
  209. package/outputs/sources/httpIncomingResponse.d.ts +28 -0
  210. package/outputs/sources/httpIncomingResponse.d.ts.map +1 -0
  211. package/outputs/sources/httpIncomingResponse.js +6 -0
  212. package/outputs/sources/httpIncomingResponse.js.map +1 -0
  213. package/outputs/sources/httpMethod.d.ts +62 -0
  214. package/outputs/sources/httpMethod.d.ts.map +1 -0
  215. package/outputs/sources/httpMethod.js +136 -0
  216. package/outputs/sources/httpMethod.js.map +1 -0
  217. package/outputs/sources/httpOutgoingRequest.d.ts +50 -0
  218. package/outputs/sources/httpOutgoingRequest.d.ts.map +1 -0
  219. package/outputs/sources/httpOutgoingRequest.js +84 -0
  220. package/outputs/sources/httpOutgoingRequest.js.map +1 -0
  221. package/outputs/sources/httpOutgoingResponse.d.ts +46 -0
  222. package/outputs/sources/httpOutgoingResponse.d.ts.map +1 -0
  223. package/outputs/sources/httpOutgoingResponse.js +6 -0
  224. package/outputs/sources/httpOutgoingResponse.js.map +1 -0
  225. package/outputs/sources/httpServer.d.ts +29 -0
  226. package/outputs/sources/httpServer.d.ts.map +1 -0
  227. package/outputs/sources/httpServer.js +3 -0
  228. package/outputs/sources/httpServer.js.map +1 -0
  229. package/outputs/sources/inMemoryCharacterWriteStream.d.ts +15 -0
  230. package/outputs/sources/inMemoryCharacterWriteStream.d.ts.map +1 -0
  231. package/outputs/sources/inMemoryCharacterWriteStream.js +52 -0
  232. package/outputs/sources/inMemoryCharacterWriteStream.js.map +1 -0
  233. package/outputs/sources/index.d.ts +111 -0
  234. package/outputs/sources/index.d.ts.map +1 -0
  235. package/outputs/sources/index.js +111 -0
  236. package/outputs/sources/index.js.map +1 -0
  237. package/outputs/sources/iterable.d.ts +132 -0
  238. package/outputs/sources/iterable.d.ts.map +1 -0
  239. package/outputs/sources/iterable.js +251 -0
  240. package/outputs/sources/iterable.js.map +1 -0
  241. package/outputs/sources/iterator.d.ts +163 -0
  242. package/outputs/sources/iterator.d.ts.map +1 -0
  243. package/outputs/sources/iterator.js +332 -0
  244. package/outputs/sources/iterator.js.map +1 -0
  245. package/outputs/sources/iteratorToJavascriptIteratorAdapter.d.ts +13 -0
  246. package/outputs/sources/iteratorToJavascriptIteratorAdapter.d.ts.map +1 -0
  247. package/outputs/sources/iteratorToJavascriptIteratorAdapter.js +34 -0
  248. package/outputs/sources/iteratorToJavascriptIteratorAdapter.js.map +1 -0
  249. package/outputs/sources/javascript.d.ts +51 -0
  250. package/outputs/sources/javascript.d.ts.map +1 -0
  251. package/outputs/sources/javascript.js +8 -0
  252. package/outputs/sources/javascript.js.map +1 -0
  253. package/outputs/sources/javascriptArrayList.d.ts +39 -0
  254. package/outputs/sources/javascriptArrayList.d.ts.map +1 -0
  255. package/outputs/sources/javascriptArrayList.js +104 -0
  256. package/outputs/sources/javascriptArrayList.js.map +1 -0
  257. package/outputs/sources/javascriptAsyncIteratorToAsyncIteratorAdapter.d.ts +29 -0
  258. package/outputs/sources/javascriptAsyncIteratorToAsyncIteratorAdapter.d.ts.map +1 -0
  259. package/outputs/sources/javascriptAsyncIteratorToAsyncIteratorAdapter.js +77 -0
  260. package/outputs/sources/javascriptAsyncIteratorToAsyncIteratorAdapter.js.map +1 -0
  261. package/outputs/sources/javascriptIteratorToIteratorAdapter.d.ts +31 -0
  262. package/outputs/sources/javascriptIteratorToIteratorAdapter.d.ts.map +1 -0
  263. package/outputs/sources/javascriptIteratorToIteratorAdapter.js +83 -0
  264. package/outputs/sources/javascriptIteratorToIteratorAdapter.js.map +1 -0
  265. package/outputs/sources/javascriptMapMap.d.ts +37 -0
  266. package/outputs/sources/javascriptMapMap.d.ts.map +1 -0
  267. package/outputs/sources/javascriptMapMap.js +88 -0
  268. package/outputs/sources/javascriptMapMap.js.map +1 -0
  269. package/outputs/sources/javascriptSetSet.d.ts +33 -0
  270. package/outputs/sources/javascriptSetSet.d.ts.map +1 -0
  271. package/outputs/sources/javascriptSetSet.js +84 -0
  272. package/outputs/sources/javascriptSetSet.js.map +1 -0
  273. package/outputs/sources/list.d.ts +106 -0
  274. package/outputs/sources/list.d.ts.map +1 -0
  275. package/outputs/sources/list.js +211 -0
  276. package/outputs/sources/list.js.map +1 -0
  277. package/outputs/sources/listQueue.d.ts +16 -0
  278. package/outputs/sources/listQueue.d.ts.map +1 -0
  279. package/outputs/sources/listQueue.js +39 -0
  280. package/outputs/sources/listQueue.js.map +1 -0
  281. package/outputs/sources/listStack.d.ts +17 -0
  282. package/outputs/sources/listStack.d.ts.map +1 -0
  283. package/outputs/sources/listStack.js +42 -0
  284. package/outputs/sources/listStack.js.map +1 -0
  285. package/outputs/sources/luxonDateTime.d.ts +26 -0
  286. package/outputs/sources/luxonDateTime.d.ts.map +1 -0
  287. package/outputs/sources/luxonDateTime.js +70 -0
  288. package/outputs/sources/luxonDateTime.js.map +1 -0
  289. package/outputs/sources/map.d.ts +105 -0
  290. package/outputs/sources/map.d.ts.map +1 -0
  291. package/outputs/sources/map.js +185 -0
  292. package/outputs/sources/map.js.map +1 -0
  293. package/outputs/sources/mapAsyncIterator.d.ts +34 -0
  294. package/outputs/sources/mapAsyncIterator.d.ts.map +1 -0
  295. package/outputs/sources/mapAsyncIterator.js +91 -0
  296. package/outputs/sources/mapAsyncIterator.js.map +1 -0
  297. package/outputs/sources/mapIterable.d.ts +31 -0
  298. package/outputs/sources/mapIterable.d.ts.map +1 -0
  299. package/outputs/sources/mapIterable.js +64 -0
  300. package/outputs/sources/mapIterable.js.map +1 -0
  301. package/outputs/sources/mapIterator.d.ts +35 -0
  302. package/outputs/sources/mapIterator.d.ts.map +1 -0
  303. package/outputs/sources/mapIterator.js +93 -0
  304. package/outputs/sources/mapIterator.js.map +1 -0
  305. package/outputs/sources/mutableCondition.d.ts +99 -0
  306. package/outputs/sources/mutableCondition.d.ts.map +1 -0
  307. package/outputs/sources/mutableCondition.js +334 -0
  308. package/outputs/sources/mutableCondition.js.map +1 -0
  309. package/outputs/sources/mutableHttpHeaders.d.ts +44 -0
  310. package/outputs/sources/mutableHttpHeaders.d.ts.map +1 -0
  311. package/outputs/sources/mutableHttpHeaders.js +125 -0
  312. package/outputs/sources/mutableHttpHeaders.js.map +1 -0
  313. package/outputs/sources/mutableMap.d.ts +125 -0
  314. package/outputs/sources/mutableMap.d.ts.map +1 -0
  315. package/outputs/sources/mutableMap.js +179 -0
  316. package/outputs/sources/mutableMap.js.map +1 -0
  317. package/outputs/sources/network.d.ts +16 -0
  318. package/outputs/sources/network.d.ts.map +1 -0
  319. package/outputs/sources/network.js +6 -0
  320. package/outputs/sources/network.js.map +1 -0
  321. package/outputs/sources/node.d.ts +11 -0
  322. package/outputs/sources/node.d.ts.map +1 -0
  323. package/outputs/sources/node.js +24 -0
  324. package/outputs/sources/node.js.map +1 -0
  325. package/outputs/sources/nodeJSCharacterWriteStream.d.ts +9 -0
  326. package/outputs/sources/nodeJSCharacterWriteStream.d.ts.map +1 -0
  327. package/outputs/sources/nodeJSCharacterWriteStream.js +28 -0
  328. package/outputs/sources/nodeJSCharacterWriteStream.js.map +1 -0
  329. package/outputs/sources/nodeJSHttpIncomingRequest.d.ts +21 -0
  330. package/outputs/sources/nodeJSHttpIncomingRequest.d.ts.map +1 -0
  331. package/outputs/sources/nodeJSHttpIncomingRequest.js +88 -0
  332. package/outputs/sources/nodeJSHttpIncomingRequest.js.map +1 -0
  333. package/outputs/sources/nodeJSHttpServer.d.ts +21 -0
  334. package/outputs/sources/nodeJSHttpServer.d.ts.map +1 -0
  335. package/outputs/sources/nodeJSHttpServer.js +83 -0
  336. package/outputs/sources/nodeJSHttpServer.js.map +1 -0
  337. package/outputs/sources/notFoundError.d.ts +7 -0
  338. package/outputs/sources/notFoundError.d.ts.map +1 -0
  339. package/outputs/sources/notFoundError.js +10 -0
  340. package/outputs/sources/notFoundError.js.map +1 -0
  341. package/outputs/sources/postCondition.d.ts +186 -0
  342. package/outputs/sources/postCondition.d.ts.map +1 -0
  343. package/outputs/sources/postCondition.js +224 -0
  344. package/outputs/sources/postCondition.js.map +1 -0
  345. package/outputs/sources/postConditionError.d.ts +7 -0
  346. package/outputs/sources/postConditionError.d.ts.map +1 -0
  347. package/outputs/sources/postConditionError.js +10 -0
  348. package/outputs/sources/postConditionError.js.map +1 -0
  349. package/outputs/sources/preCondition.d.ts +186 -0
  350. package/outputs/sources/preCondition.d.ts.map +1 -0
  351. package/outputs/sources/preCondition.js +224 -0
  352. package/outputs/sources/preCondition.js.map +1 -0
  353. package/outputs/sources/preConditionError.d.ts +7 -0
  354. package/outputs/sources/preConditionError.d.ts.map +1 -0
  355. package/outputs/sources/preConditionError.js +10 -0
  356. package/outputs/sources/preConditionError.js.map +1 -0
  357. package/outputs/sources/promiseAsyncResult.d.ts +22 -0
  358. package/outputs/sources/promiseAsyncResult.d.ts.map +1 -0
  359. package/outputs/sources/promiseAsyncResult.js +131 -0
  360. package/outputs/sources/promiseAsyncResult.js.map +1 -0
  361. package/outputs/sources/property.d.ts +15 -0
  362. package/outputs/sources/property.d.ts.map +1 -0
  363. package/outputs/sources/property.js +44 -0
  364. package/outputs/sources/property.js.map +1 -0
  365. package/outputs/sources/queue.d.ts +39 -0
  366. package/outputs/sources/queue.d.ts.map +1 -0
  367. package/outputs/sources/queue.js +14 -0
  368. package/outputs/sources/queue.js.map +1 -0
  369. package/outputs/sources/realNetwork.d.ts +10 -0
  370. package/outputs/sources/realNetwork.d.ts.map +1 -0
  371. package/outputs/sources/realNetwork.js +18 -0
  372. package/outputs/sources/realNetwork.js.map +1 -0
  373. package/outputs/sources/recreationDotGovClient.d.ts +79 -0
  374. package/outputs/sources/recreationDotGovClient.d.ts.map +1 -0
  375. package/outputs/sources/recreationDotGovClient.js +130 -0
  376. package/outputs/sources/recreationDotGovClient.js.map +1 -0
  377. package/outputs/sources/searchControl.d.ts +36 -0
  378. package/outputs/sources/searchControl.d.ts.map +1 -0
  379. package/outputs/sources/searchControl.js +6 -0
  380. package/outputs/sources/searchControl.js.map +1 -0
  381. package/outputs/sources/set.d.ts +62 -0
  382. package/outputs/sources/set.d.ts.map +1 -0
  383. package/outputs/sources/set.js +145 -0
  384. package/outputs/sources/set.js.map +1 -0
  385. package/outputs/sources/skipAsyncIterator.d.ts +34 -0
  386. package/outputs/sources/skipAsyncIterator.d.ts.map +1 -0
  387. package/outputs/sources/skipAsyncIterator.js +94 -0
  388. package/outputs/sources/skipAsyncIterator.js.map +1 -0
  389. package/outputs/sources/skipIterator.d.ts +36 -0
  390. package/outputs/sources/skipIterator.d.ts.map +1 -0
  391. package/outputs/sources/skipIterator.js +100 -0
  392. package/outputs/sources/skipIterator.js.map +1 -0
  393. package/outputs/sources/stack.d.ts +43 -0
  394. package/outputs/sources/stack.d.ts.map +1 -0
  395. package/outputs/sources/stack.js +14 -0
  396. package/outputs/sources/stack.js.map +1 -0
  397. package/outputs/sources/stringComparer.d.ts +12 -0
  398. package/outputs/sources/stringComparer.d.ts.map +1 -0
  399. package/outputs/sources/stringComparer.js +24 -0
  400. package/outputs/sources/stringComparer.js.map +1 -0
  401. package/outputs/sources/stringIterator.d.ts +36 -0
  402. package/outputs/sources/stringIterator.d.ts.map +1 -0
  403. package/outputs/sources/stringIterator.js +94 -0
  404. package/outputs/sources/stringIterator.js.map +1 -0
  405. package/outputs/sources/strings.d.ts +78 -0
  406. package/outputs/sources/strings.d.ts.map +1 -0
  407. package/outputs/sources/strings.js +218 -0
  408. package/outputs/sources/strings.js.map +1 -0
  409. package/outputs/sources/syncResult.d.ts +32 -0
  410. package/outputs/sources/syncResult.d.ts.map +1 -0
  411. package/outputs/sources/syncResult.js +200 -0
  412. package/outputs/sources/syncResult.js.map +1 -0
  413. package/outputs/sources/takeAsyncIterator.d.ts +34 -0
  414. package/outputs/sources/takeAsyncIterator.d.ts.map +1 -0
  415. package/outputs/sources/takeAsyncIterator.js +92 -0
  416. package/outputs/sources/takeAsyncIterator.js.map +1 -0
  417. package/outputs/sources/takeIterator.d.ts +36 -0
  418. package/outputs/sources/takeIterator.d.ts.map +1 -0
  419. package/outputs/sources/takeIterator.js +98 -0
  420. package/outputs/sources/takeIterator.js.map +1 -0
  421. package/outputs/sources/toStringFunctions.d.ts +21 -0
  422. package/outputs/sources/toStringFunctions.d.ts.map +1 -0
  423. package/outputs/sources/toStringFunctions.js +130 -0
  424. package/outputs/sources/toStringFunctions.js.map +1 -0
  425. package/outputs/sources/types.d.ts +194 -0
  426. package/outputs/sources/types.d.ts.map +1 -0
  427. package/outputs/sources/types.js +277 -0
  428. package/outputs/sources/types.js.map +1 -0
  429. package/outputs/sources/whereAsyncIterator.d.ts +33 -0
  430. package/outputs/sources/whereAsyncIterator.d.ts.map +1 -0
  431. package/outputs/sources/whereAsyncIterator.js +91 -0
  432. package/outputs/sources/whereAsyncIterator.js.map +1 -0
  433. package/outputs/sources/whereIterable.d.ts +32 -0
  434. package/outputs/sources/whereIterable.d.ts.map +1 -0
  435. package/outputs/sources/whereIterable.js +65 -0
  436. package/outputs/sources/whereIterable.js.map +1 -0
  437. package/outputs/sources/whereIterator.d.ts +35 -0
  438. package/outputs/sources/whereIterator.d.ts.map +1 -0
  439. package/outputs/sources/whereIterator.js +102 -0
  440. package/outputs/sources/whereIterator.js.map +1 -0
  441. package/outputs/sources/wonderlandTrailClient.d.ts +202 -0
  442. package/outputs/sources/wonderlandTrailClient.d.ts.map +1 -0
  443. package/outputs/sources/wonderlandTrailClient.js +1094 -0
  444. package/outputs/sources/wonderlandTrailClient.js.map +1 -0
  445. package/outputs/tests/AssertTestCreator.d.ts +11 -0
  446. package/outputs/tests/AssertTestCreator.d.ts.map +1 -0
  447. package/outputs/tests/AssertTestCreator.js +15 -0
  448. package/outputs/tests/AssertTestCreator.js.map +1 -0
  449. package/outputs/tests/BasicTestError.d.ts +14 -0
  450. package/outputs/tests/BasicTestError.d.ts.map +1 -0
  451. package/outputs/tests/BasicTestError.js +94 -0
  452. package/outputs/tests/BasicTestError.js.map +1 -0
  453. package/outputs/tests/BasicTestErrorCreator.d.ts +11 -0
  454. package/outputs/tests/BasicTestErrorCreator.d.ts.map +1 -0
  455. package/outputs/tests/BasicTestErrorCreator.js +15 -0
  456. package/outputs/tests/BasicTestErrorCreator.js.map +1 -0
  457. package/outputs/tests/BasicTestErrorTests.d.ts +3 -0
  458. package/outputs/tests/BasicTestErrorTests.d.ts.map +1 -0
  459. package/outputs/tests/BasicTestErrorTests.js +236 -0
  460. package/outputs/tests/BasicTestErrorTests.js.map +1 -0
  461. package/outputs/tests/CharacterTableTests.d.ts +3 -0
  462. package/outputs/tests/CharacterTableTests.d.ts.map +1 -0
  463. package/outputs/tests/CharacterTableTests.js +24 -0
  464. package/outputs/tests/CharacterTableTests.js.map +1 -0
  465. package/outputs/tests/ClockTests.d.ts +5 -0
  466. package/outputs/tests/ClockTests.d.ts.map +1 -0
  467. package/outputs/tests/ClockTests.js +23 -0
  468. package/outputs/tests/ClockTests.js.map +1 -0
  469. package/outputs/tests/CommandLineParametersTests.d.ts +3 -0
  470. package/outputs/tests/CommandLineParametersTests.d.ts.map +1 -0
  471. package/outputs/tests/CommandLineParametersTests.js +58 -0
  472. package/outputs/tests/CommandLineParametersTests.js.map +1 -0
  473. package/outputs/tests/ConsoleTestRunnerUI.d.ts +49 -0
  474. package/outputs/tests/ConsoleTestRunnerUI.d.ts.map +1 -0
  475. package/outputs/tests/ConsoleTestRunnerUI.js +213 -0
  476. package/outputs/tests/ConsoleTestRunnerUI.js.map +1 -0
  477. package/outputs/tests/ConsoleTestRunnerUITests.d.ts +5 -0
  478. package/outputs/tests/ConsoleTestRunnerUITests.d.ts.map +1 -0
  479. package/outputs/tests/ConsoleTestRunnerUITests.js +26 -0
  480. package/outputs/tests/ConsoleTestRunnerUITests.js.map +1 -0
  481. package/outputs/tests/FakeClock.d.ts +16 -0
  482. package/outputs/tests/FakeClock.d.ts.map +1 -0
  483. package/outputs/tests/FakeClock.js +27 -0
  484. package/outputs/tests/FakeClock.js.map +1 -0
  485. package/outputs/tests/IndentedCharacterWriteStreamTests.d.ts +3 -0
  486. package/outputs/tests/IndentedCharacterWriteStreamTests.d.ts.map +1 -0
  487. package/outputs/tests/IndentedCharacterWriteStreamTests.js +269 -0
  488. package/outputs/tests/IndentedCharacterWriteStreamTests.js.map +1 -0
  489. package/outputs/tests/IndexableTests.d.ts +5 -0
  490. package/outputs/tests/IndexableTests.d.ts.map +1 -0
  491. package/outputs/tests/IndexableTests.js +46 -0
  492. package/outputs/tests/IndexableTests.js.map +1 -0
  493. package/outputs/tests/MutableIndexableTests.d.ts +5 -0
  494. package/outputs/tests/MutableIndexableTests.d.ts.map +1 -0
  495. package/outputs/tests/MutableIndexableTests.js +33 -0
  496. package/outputs/tests/MutableIndexableTests.js.map +1 -0
  497. package/outputs/tests/TestCreator.d.ts +15 -0
  498. package/outputs/tests/TestCreator.d.ts.map +1 -0
  499. package/outputs/tests/TestCreator.js +13 -0
  500. package/outputs/tests/TestCreator.js.map +1 -0
  501. package/outputs/tests/TestError.d.ts +31 -0
  502. package/outputs/tests/TestError.d.ts.map +1 -0
  503. package/outputs/tests/TestError.js +5 -0
  504. package/outputs/tests/TestError.js.map +1 -0
  505. package/outputs/tests/TestErrorCreator.d.ts +6 -0
  506. package/outputs/tests/TestErrorCreator.d.ts.map +1 -0
  507. package/outputs/tests/TestErrorCreator.js +7 -0
  508. package/outputs/tests/TestErrorCreator.js.map +1 -0
  509. package/outputs/tests/TokenizerTests.d.ts +3 -0
  510. package/outputs/tests/TokenizerTests.d.ts.map +1 -0
  511. package/outputs/tests/TokenizerTests.js +100 -0
  512. package/outputs/tests/TokenizerTests.js.map +1 -0
  513. package/outputs/tests/assertTest.d.ts +32 -0
  514. package/outputs/tests/assertTest.d.ts.map +1 -0
  515. package/outputs/tests/assertTest.js +75 -0
  516. package/outputs/tests/assertTest.js.map +1 -0
  517. package/outputs/tests/assertTestTests.d.ts +3 -0
  518. package/outputs/tests/assertTestTests.d.ts.map +1 -0
  519. package/outputs/tests/assertTestTests.js +49 -0
  520. package/outputs/tests/assertTestTests.js.map +1 -0
  521. package/outputs/tests/basicTestSkip.d.ts +20 -0
  522. package/outputs/tests/basicTestSkip.d.ts.map +1 -0
  523. package/outputs/tests/basicTestSkip.js +36 -0
  524. package/outputs/tests/basicTestSkip.js.map +1 -0
  525. package/outputs/tests/byteListStreamTests.d.ts +3 -0
  526. package/outputs/tests/byteListStreamTests.d.ts.map +1 -0
  527. package/outputs/tests/byteListStreamTests.js +247 -0
  528. package/outputs/tests/byteListStreamTests.js.map +1 -0
  529. package/outputs/tests/byteListTests.d.ts +3 -0
  530. package/outputs/tests/byteListTests.d.ts.map +1 -0
  531. package/outputs/tests/byteListTests.js +5 -0
  532. package/outputs/tests/byteListTests.js.map +1 -0
  533. package/outputs/tests/bytesTests.d.ts +3 -0
  534. package/outputs/tests/bytesTests.d.ts.map +1 -0
  535. package/outputs/tests/bytesTests.js +30 -0
  536. package/outputs/tests/bytesTests.js.map +1 -0
  537. package/outputs/tests/characterListStreamTests.d.ts +3 -0
  538. package/outputs/tests/characterListStreamTests.d.ts.map +1 -0
  539. package/outputs/tests/characterListStreamTests.js +247 -0
  540. package/outputs/tests/characterListStreamTests.js.map +1 -0
  541. package/outputs/tests/characterListTests.d.ts +3 -0
  542. package/outputs/tests/characterListTests.d.ts.map +1 -0
  543. package/outputs/tests/characterListTests.js +159 -0
  544. package/outputs/tests/characterListTests.js.map +1 -0
  545. package/outputs/tests/characterWriteStreamTests.d.ts +4 -0
  546. package/outputs/tests/characterWriteStreamTests.d.ts.map +1 -0
  547. package/outputs/tests/characterWriteStreamTests.js +7 -0
  548. package/outputs/tests/characterWriteStreamTests.js.map +1 -0
  549. package/outputs/tests/comparerTests.d.ts +3 -0
  550. package/outputs/tests/comparerTests.d.ts.map +1 -0
  551. package/outputs/tests/comparerTests.js +67 -0
  552. package/outputs/tests/comparerTests.js.map +1 -0
  553. package/outputs/tests/conditionTests.d.ts +3 -0
  554. package/outputs/tests/conditionTests.d.ts.map +1 -0
  555. package/outputs/tests/conditionTests.js +602 -0
  556. package/outputs/tests/conditionTests.js.map +1 -0
  557. package/outputs/tests/consoleTestRunner.d.ts +95 -0
  558. package/outputs/tests/consoleTestRunner.d.ts.map +1 -0
  559. package/outputs/tests/consoleTestRunner.js +351 -0
  560. package/outputs/tests/consoleTestRunner.js.map +1 -0
  561. package/outputs/tests/consoleTestRunnerTests.d.ts +3 -0
  562. package/outputs/tests/consoleTestRunnerTests.d.ts.map +1 -0
  563. package/outputs/tests/consoleTestRunnerTests.js +537 -0
  564. package/outputs/tests/consoleTestRunnerTests.js.map +1 -0
  565. package/outputs/tests/dateTimeTests.d.ts +3 -0
  566. package/outputs/tests/dateTimeTests.d.ts.map +1 -0
  567. package/outputs/tests/dateTimeTests.js +24 -0
  568. package/outputs/tests/dateTimeTests.js.map +1 -0
  569. package/outputs/tests/depthFirstSearchTests.d.ts +3 -0
  570. package/outputs/tests/depthFirstSearchTests.d.ts.map +1 -0
  571. package/outputs/tests/depthFirstSearchTests.js +61 -0
  572. package/outputs/tests/depthFirstSearchTests.js.map +1 -0
  573. package/outputs/tests/disposableTests.d.ts +3 -0
  574. package/outputs/tests/disposableTests.d.ts.map +1 -0
  575. package/outputs/tests/disposableTests.js +81 -0
  576. package/outputs/tests/disposableTests.js.map +1 -0
  577. package/outputs/tests/englishTests.d.ts +3 -0
  578. package/outputs/tests/englishTests.d.ts.map +1 -0
  579. package/outputs/tests/englishTests.js +68 -0
  580. package/outputs/tests/englishTests.js.map +1 -0
  581. package/outputs/tests/equalFunctionsTests.d.ts +3 -0
  582. package/outputs/tests/equalFunctionsTests.d.ts.map +1 -0
  583. package/outputs/tests/equalFunctionsTests.js +187 -0
  584. package/outputs/tests/equalFunctionsTests.js.map +1 -0
  585. package/outputs/tests/failedTest.d.ts +11 -0
  586. package/outputs/tests/failedTest.d.ts.map +1 -0
  587. package/outputs/tests/failedTest.js +21 -0
  588. package/outputs/tests/failedTest.js.map +1 -0
  589. package/outputs/tests/fetchHttpClientTests.d.ts +3 -0
  590. package/outputs/tests/fetchHttpClientTests.d.ts.map +1 -0
  591. package/outputs/tests/fetchHttpClientTests.js +21 -0
  592. package/outputs/tests/fetchHttpClientTests.js.map +1 -0
  593. package/outputs/tests/generatorTests.d.ts +3 -0
  594. package/outputs/tests/generatorTests.d.ts.map +1 -0
  595. package/outputs/tests/generatorTests.js +55 -0
  596. package/outputs/tests/generatorTests.js.map +1 -0
  597. package/outputs/tests/httpClientTests.d.ts +3 -0
  598. package/outputs/tests/httpClientTests.d.ts.map +1 -0
  599. package/outputs/tests/httpClientTests.js +12 -0
  600. package/outputs/tests/httpClientTests.js.map +1 -0
  601. package/outputs/tests/inMemoryCharacterWriteStreamTests.d.ts +3 -0
  602. package/outputs/tests/inMemoryCharacterWriteStreamTests.d.ts.map +1 -0
  603. package/outputs/tests/inMemoryCharacterWriteStreamTests.js +84 -0
  604. package/outputs/tests/inMemoryCharacterWriteStreamTests.js.map +1 -0
  605. package/outputs/tests/index.d.ts +12 -0
  606. package/outputs/tests/index.d.ts.map +1 -0
  607. package/outputs/tests/index.js +12 -0
  608. package/outputs/tests/index.js.map +1 -0
  609. package/outputs/tests/iterableTests.d.ts +5 -0
  610. package/outputs/tests/iterableTests.d.ts.map +1 -0
  611. package/outputs/tests/iterableTests.js +155 -0
  612. package/outputs/tests/iterableTests.js.map +1 -0
  613. package/outputs/tests/iteratorTests.d.ts +5 -0
  614. package/outputs/tests/iteratorTests.d.ts.map +1 -0
  615. package/outputs/tests/iteratorTests.js +728 -0
  616. package/outputs/tests/iteratorTests.js.map +1 -0
  617. package/outputs/tests/javascriptMapMapTests.d.ts +3 -0
  618. package/outputs/tests/javascriptMapMapTests.d.ts.map +1 -0
  619. package/outputs/tests/javascriptMapMapTests.js +14 -0
  620. package/outputs/tests/javascriptMapMapTests.js.map +1 -0
  621. package/outputs/tests/listTests.d.ts +3 -0
  622. package/outputs/tests/listTests.d.ts.map +1 -0
  623. package/outputs/tests/listTests.js +202 -0
  624. package/outputs/tests/listTests.js.map +1 -0
  625. package/outputs/tests/mapIteratorTests.d.ts +3 -0
  626. package/outputs/tests/mapIteratorTests.d.ts.map +1 -0
  627. package/outputs/tests/mapIteratorTests.js +27 -0
  628. package/outputs/tests/mapIteratorTests.js.map +1 -0
  629. package/outputs/tests/mapTests.d.ts +5 -0
  630. package/outputs/tests/mapTests.d.ts.map +1 -0
  631. package/outputs/tests/mapTests.js +64 -0
  632. package/outputs/tests/mapTests.js.map +1 -0
  633. package/outputs/tests/mutableConditionTests.d.ts +3 -0
  634. package/outputs/tests/mutableConditionTests.d.ts.map +1 -0
  635. package/outputs/tests/mutableConditionTests.js +174 -0
  636. package/outputs/tests/mutableConditionTests.js.map +1 -0
  637. package/outputs/tests/mutableMapTests.d.ts +5 -0
  638. package/outputs/tests/mutableMapTests.d.ts.map +1 -0
  639. package/outputs/tests/mutableMapTests.js +102 -0
  640. package/outputs/tests/mutableMapTests.js.map +1 -0
  641. package/outputs/tests/nodeJSHttpServerTests.d.ts +3 -0
  642. package/outputs/tests/nodeJSHttpServerTests.d.ts.map +1 -0
  643. package/outputs/tests/nodeJSHttpServerTests.js +50 -0
  644. package/outputs/tests/nodeJSHttpServerTests.js.map +1 -0
  645. package/outputs/tests/notFoundErrorTests.d.ts +3 -0
  646. package/outputs/tests/notFoundErrorTests.d.ts.map +1 -0
  647. package/outputs/tests/notFoundErrorTests.js +17 -0
  648. package/outputs/tests/notFoundErrorTests.js.map +1 -0
  649. package/outputs/tests/postConditionErrorTests.d.ts +3 -0
  650. package/outputs/tests/postConditionErrorTests.d.ts.map +1 -0
  651. package/outputs/tests/postConditionErrorTests.js +17 -0
  652. package/outputs/tests/postConditionErrorTests.js.map +1 -0
  653. package/outputs/tests/preConditionErrorTests.d.ts +3 -0
  654. package/outputs/tests/preConditionErrorTests.d.ts.map +1 -0
  655. package/outputs/tests/preConditionErrorTests.js +17 -0
  656. package/outputs/tests/preConditionErrorTests.js.map +1 -0
  657. package/outputs/tests/promiseAsyncResultTests.d.ts +3 -0
  658. package/outputs/tests/promiseAsyncResultTests.d.ts.map +1 -0
  659. package/outputs/tests/promiseAsyncResultTests.js +487 -0
  660. package/outputs/tests/promiseAsyncResultTests.js.map +1 -0
  661. package/outputs/tests/propertyTests.d.ts +3 -0
  662. package/outputs/tests/propertyTests.d.ts.map +1 -0
  663. package/outputs/tests/propertyTests.js +41 -0
  664. package/outputs/tests/propertyTests.js.map +1 -0
  665. package/outputs/tests/queueTests.d.ts +3 -0
  666. package/outputs/tests/queueTests.d.ts.map +1 -0
  667. package/outputs/tests/queueTests.js +20 -0
  668. package/outputs/tests/queueTests.js.map +1 -0
  669. package/outputs/tests/recreationDotGovClientTests.d.ts +3 -0
  670. package/outputs/tests/recreationDotGovClientTests.d.ts.map +1 -0
  671. package/outputs/tests/recreationDotGovClientTests.js +111 -0
  672. package/outputs/tests/recreationDotGovClientTests.js.map +1 -0
  673. package/outputs/tests/setTests.d.ts +3 -0
  674. package/outputs/tests/setTests.d.ts.map +1 -0
  675. package/outputs/tests/setTests.js +92 -0
  676. package/outputs/tests/setTests.js.map +1 -0
  677. package/outputs/tests/skippedTest.d.ts +11 -0
  678. package/outputs/tests/skippedTest.d.ts.map +1 -0
  679. package/outputs/tests/skippedTest.js +21 -0
  680. package/outputs/tests/skippedTest.js.map +1 -0
  681. package/outputs/tests/stackTests.d.ts +3 -0
  682. package/outputs/tests/stackTests.d.ts.map +1 -0
  683. package/outputs/tests/stackTests.js +45 -0
  684. package/outputs/tests/stackTests.js.map +1 -0
  685. package/outputs/tests/stringComparerTests.d.ts +3 -0
  686. package/outputs/tests/stringComparerTests.d.ts.map +1 -0
  687. package/outputs/tests/stringComparerTests.js +47 -0
  688. package/outputs/tests/stringComparerTests.js.map +1 -0
  689. package/outputs/tests/stringIteratorTests.d.ts +3 -0
  690. package/outputs/tests/stringIteratorTests.d.ts.map +1 -0
  691. package/outputs/tests/stringIteratorTests.js +81 -0
  692. package/outputs/tests/stringIteratorTests.js.map +1 -0
  693. package/outputs/tests/stringsTests.d.ts +3 -0
  694. package/outputs/tests/stringsTests.d.ts.map +1 -0
  695. package/outputs/tests/stringsTests.js +384 -0
  696. package/outputs/tests/stringsTests.js.map +1 -0
  697. package/outputs/tests/syncResultTests.d.ts +3 -0
  698. package/outputs/tests/syncResultTests.d.ts.map +1 -0
  699. package/outputs/tests/syncResultTests.js +900 -0
  700. package/outputs/tests/syncResultTests.js.map +1 -0
  701. package/outputs/tests/test.d.ts +144 -0
  702. package/outputs/tests/test.d.ts.map +1 -0
  703. package/outputs/tests/test.js +145 -0
  704. package/outputs/tests/test.js.map +1 -0
  705. package/outputs/tests/testAction.d.ts +22 -0
  706. package/outputs/tests/testAction.d.ts.map +1 -0
  707. package/outputs/tests/testAction.js +56 -0
  708. package/outputs/tests/testAction.js.map +1 -0
  709. package/outputs/tests/testActionTests.d.ts +3 -0
  710. package/outputs/tests/testActionTests.d.ts.map +1 -0
  711. package/outputs/tests/testActionTests.js +56 -0
  712. package/outputs/tests/testActionTests.js.map +1 -0
  713. package/outputs/tests/testFailureTests.d.ts +3 -0
  714. package/outputs/tests/testFailureTests.d.ts.map +1 -0
  715. package/outputs/tests/testFailureTests.js +7 -0
  716. package/outputs/tests/testFailureTests.js.map +1 -0
  717. package/outputs/tests/testRunner.d.ts +107 -0
  718. package/outputs/tests/testRunner.d.ts.map +1 -0
  719. package/outputs/tests/testRunner.js +63 -0
  720. package/outputs/tests/testRunner.js.map +1 -0
  721. package/outputs/tests/testRunnerTests.d.ts +4 -0
  722. package/outputs/tests/testRunnerTests.d.ts.map +1 -0
  723. package/outputs/tests/testRunnerTests.js +258 -0
  724. package/outputs/tests/testRunnerTests.js.map +1 -0
  725. package/outputs/tests/testSkip.d.ts +24 -0
  726. package/outputs/tests/testSkip.d.ts.map +1 -0
  727. package/outputs/tests/testSkip.js +19 -0
  728. package/outputs/tests/testSkip.js.map +1 -0
  729. package/outputs/tests/tests.d.ts +2 -0
  730. package/outputs/tests/tests.d.ts.map +1 -0
  731. package/outputs/tests/tests.js +115 -0
  732. package/outputs/tests/tests.js.map +1 -0
  733. package/outputs/tests/toStringFunctionsTests.d.ts +3 -0
  734. package/outputs/tests/toStringFunctionsTests.d.ts.map +1 -0
  735. package/outputs/tests/toStringFunctionsTests.js +43 -0
  736. package/outputs/tests/toStringFunctionsTests.js.map +1 -0
  737. package/outputs/tests/typesTests.d.ts +3 -0
  738. package/outputs/tests/typesTests.d.ts.map +1 -0
  739. package/outputs/tests/typesTests.js +194 -0
  740. package/outputs/tests/typesTests.js.map +1 -0
  741. package/outputs/tests/whereIteratorTests.d.ts +3 -0
  742. package/outputs/tests/whereIteratorTests.d.ts.map +1 -0
  743. package/outputs/tests/whereIteratorTests.js +30 -0
  744. package/outputs/tests/whereIteratorTests.js.map +1 -0
  745. package/outputs/tests/wonderlandTrailClientTests.d.ts +3 -0
  746. package/outputs/tests/wonderlandTrailClientTests.d.ts.map +1 -0
  747. package/outputs/tests/wonderlandTrailClientTests.js +272 -0
  748. package/outputs/tests/wonderlandTrailClientTests.js.map +1 -0
  749. package/package.json +48 -48
  750. package/outputs/characterWriteStream-CzPcNOCD.d.cts +0 -845
  751. package/outputs/characterWriteStream-CzPcNOCD.d.ts +0 -845
  752. package/outputs/chunk-FZ3WRQ7B.js +0 -1199
  753. package/outputs/chunk-FZ3WRQ7B.js.map +0 -1
  754. package/outputs/chunk-MHMLVX2O.js +0 -9590
  755. package/outputs/chunk-MHMLVX2O.js.map +0 -1
  756. package/outputs/sourceIndex.cjs +0 -9790
  757. package/outputs/sourceIndex.cjs.map +0 -1
  758. package/outputs/sourceIndex.d.cts +0 -3532
  759. package/outputs/sourceIndex.d.ts +0 -3532
  760. package/outputs/sourceIndex.js +0 -349
  761. package/outputs/sourceIndex.js.map +0 -1
  762. package/outputs/testIndex.cjs +0 -7046
  763. package/outputs/testIndex.cjs.map +0 -1
  764. package/outputs/testIndex.d.cts +0 -544
  765. package/outputs/testIndex.d.ts +0 -544
  766. package/outputs/testIndex.js +0 -55
  767. package/outputs/testIndex.js.map +0 -1
  768. package/outputs/tests.cjs +0 -19372
  769. package/outputs/tests.cjs.map +0 -1
  770. package/outputs/tests.d.cts +0 -3
  771. package/outputs/tests.d.ts +0 -3
  772. package/outputs/tests.js +0 -10017
  773. package/outputs/tests.js.map +0 -1
@@ -0,0 +1,1094 @@
1
+ import { HttpClient } from "./httpClient.js";
2
+ import { Iterable } from "./iterable.js";
3
+ import { PreCondition } from "./preCondition.js";
4
+ import { RecreationDotGovClient } from "./recreationDotGovClient.js";
5
+ import { Map } from "./map.js";
6
+ import { List } from "./list.js";
7
+ import { hasProperty, isNumber, isObject, isUndefinedOrNull } from "./types.js";
8
+ import { MutableMap } from "./mutableMap.js";
9
+ import { NotFoundError } from "./notFoundError.js";
10
+ import { Stack } from "./stack.js";
11
+ import { PromiseAsyncResult } from "./promiseAsyncResult.js";
12
+ export function isWonderlandTrailLocation(value) {
13
+ return isObject(value) &&
14
+ hasProperty(value, "name") &&
15
+ hasProperty(value, "trailhead") &&
16
+ hasProperty(value, "foodCacheStorage") &&
17
+ hasProperty(value, "divisionId") &&
18
+ hasProperty(value, "groupSiteDivisionId");
19
+ }
20
+ export class WonderlandTrailLocations {
21
+ static graniteCreek = {
22
+ name: "Granite Creek",
23
+ trailhead: false,
24
+ foodCacheStorage: false,
25
+ divisionId: "46753170009",
26
+ groupSiteDivisionId: "46753170010",
27
+ latitude: 46.92058,
28
+ longitude: -121.70800,
29
+ elevationFeet: 5851,
30
+ };
31
+ static sunriseCamp = {
32
+ name: "Sunrise Camp",
33
+ trailhead: false,
34
+ foodCacheStorage: false,
35
+ divisionId: "46753170058",
36
+ groupSiteDivisionId: "46753170059",
37
+ latitude: 46.91129,
38
+ longitude: -121.66002,
39
+ elevationFeet: 6258,
40
+ };
41
+ static sunriseVisitorCenter = {
42
+ name: "Sunrise Visitor Center",
43
+ trailhead: true,
44
+ foodCacheStorage: true,
45
+ divisionId: "",
46
+ groupSiteDivisionId: "",
47
+ latitude: 46.91448,
48
+ longitude: -121.64337,
49
+ elevationFeet: 6410,
50
+ };
51
+ static whiteRiver = {
52
+ name: "White River",
53
+ trailhead: true,
54
+ foodCacheStorage: true,
55
+ divisionId: "46753170066",
56
+ groupSiteDivisionId: "46753170067",
57
+ latitude: 46.90255,
58
+ longitude: -121.63869,
59
+ elevationFeet: 4229,
60
+ };
61
+ static fryingPanCreek = {
62
+ name: "Fryingpan Creek",
63
+ trailhead: true,
64
+ foodCacheStorage: false,
65
+ divisionId: "",
66
+ groupSiteDivisionId: "",
67
+ latitude: 46.88809,
68
+ longitude: -121.61019,
69
+ elevationFeet: 3835,
70
+ };
71
+ static summerland = {
72
+ name: "Summerland",
73
+ trailhead: false,
74
+ foodCacheStorage: false,
75
+ divisionId: "46753170056",
76
+ groupSiteDivisionId: "46753170057",
77
+ latitude: 46.86616,
78
+ longitude: -121.65843,
79
+ elevationFeet: 5988,
80
+ };
81
+ static indianBar = {
82
+ name: "Indian Bar",
83
+ trailhead: false,
84
+ foodCacheStorage: false,
85
+ divisionId: "46753170046",
86
+ groupSiteDivisionId: "46753170047",
87
+ latitude: 46.82593,
88
+ longitude: -121.63942,
89
+ elevationFeet: 5101,
90
+ };
91
+ static nickelCreek = {
92
+ name: "Nickel Creek",
93
+ trailhead: false,
94
+ foodCacheStorage: false,
95
+ divisionId: "46753170051",
96
+ groupSiteDivisionId: "46753170052",
97
+ latitude: 46.77204,
98
+ longitude: -121.62402,
99
+ elevationFeet: 3383,
100
+ };
101
+ static boxCanyon = {
102
+ name: "Box Canyon",
103
+ trailhead: true,
104
+ foodCacheStorage: false,
105
+ divisionId: "",
106
+ groupSiteDivisionId: "",
107
+ latitude: 46.76570,
108
+ longitude: -121.63517,
109
+ elevationFeet: 3025,
110
+ };
111
+ static mapleCreek = {
112
+ name: "Maple Creek",
113
+ trailhead: false,
114
+ foodCacheStorage: false,
115
+ divisionId: "46753170027",
116
+ groupSiteDivisionId: "46753170028",
117
+ latitude: 46.75745,
118
+ longitude: -121.65764,
119
+ elevationFeet: 2806,
120
+ };
121
+ static reflectionLakes = {
122
+ name: "Reflection Lakes",
123
+ trailhead: true,
124
+ foodCacheStorage: false,
125
+ divisionId: "",
126
+ groupSiteDivisionId: "",
127
+ latitude: 46.76824,
128
+ longitude: -121.72890,
129
+ elevationFeet: 4862,
130
+ };
131
+ static paradiseRiver = {
132
+ name: "Paradise River",
133
+ trailhead: false,
134
+ foodCacheStorage: false,
135
+ divisionId: "46753170031",
136
+ groupSiteDivisionId: "46753170032",
137
+ latitude: 46.77076,
138
+ longitude: -121.75909,
139
+ elevationFeet: 3960,
140
+ };
141
+ static longmire = {
142
+ name: "Longmire",
143
+ trailhead: true,
144
+ foodCacheStorage: true,
145
+ divisionId: "",
146
+ groupSiteDivisionId: "",
147
+ latitude: 46.75011,
148
+ longitude: -121.81253,
149
+ elevationFeet: 2750,
150
+ };
151
+ static pyramidCreek = {
152
+ name: "Pyramid Creek",
153
+ trailhead: false,
154
+ foodCacheStorage: false,
155
+ divisionId: "46753170033",
156
+ groupSiteDivisionId: "",
157
+ latitude: 46.77832,
158
+ longitude: -121.80963,
159
+ elevationFeet: 3721,
160
+ };
161
+ static devilsDream = {
162
+ name: "Devil's Dream",
163
+ trailhead: false,
164
+ foodCacheStorage: false,
165
+ divisionId: "46753170040",
166
+ groupSiteDivisionId: "46753170041",
167
+ latitude: 46.78196,
168
+ longitude: -121.83297,
169
+ elevationFeet: 4929,
170
+ };
171
+ static southPuyallupRiver = {
172
+ name: "South Puyallup River",
173
+ trailhead: false,
174
+ foodCacheStorage: false,
175
+ divisionId: "46753170035",
176
+ groupSiteDivisionId: "46753170036",
177
+ latitude: 46.81331,
178
+ longitude: -121.86445,
179
+ elevationFeet: 4183,
180
+ };
181
+ static klapatchePark = {
182
+ name: "Klapatche Park",
183
+ trailhead: false,
184
+ foodCacheStorage: false,
185
+ divisionId: "46753170024",
186
+ groupSiteDivisionId: "",
187
+ latitude: 46.83571,
188
+ longitude: -121.87752,
189
+ elevationFeet: 5496,
190
+ };
191
+ static northPuyallupRiver = {
192
+ name: "North Puyallup River",
193
+ trailhead: false,
194
+ foodCacheStorage: false,
195
+ divisionId: "46753170029",
196
+ groupSiteDivisionId: "46753170030",
197
+ latitude: 46.84751,
198
+ longitude: -121.87005,
199
+ elevationFeet: 3733,
200
+ };
201
+ static goldenLakes = {
202
+ name: "Golden Lakes",
203
+ trailhead: false,
204
+ foodCacheStorage: false,
205
+ divisionId: "46753170022",
206
+ groupSiteDivisionId: "46753170023",
207
+ latitude: 46.88327,
208
+ longitude: -121.89919,
209
+ elevationFeet: 4927,
210
+ };
211
+ static southMowichRiver = {
212
+ name: "South Mowich River",
213
+ trailhead: false,
214
+ foodCacheStorage: false,
215
+ divisionId: "46753170019",
216
+ groupSiteDivisionId: "46753170020",
217
+ latitude: 46.91146,
218
+ longitude: -121.89314,
219
+ elevationFeet: 2686,
220
+ };
221
+ static mowichLake = {
222
+ name: "Mowich Lake",
223
+ trailhead: false,
224
+ foodCacheStorage: false,
225
+ divisionId: "46753170015",
226
+ groupSiteDivisionId: "46753170016",
227
+ latitude: 46.93204,
228
+ longitude: -121.86351,
229
+ elevationFeet: 4868,
230
+ };
231
+ static eaglesRoost = {
232
+ name: "Eagle's Roost",
233
+ trailhead: false,
234
+ foodCacheStorage: false,
235
+ divisionId: "46753170006",
236
+ groupSiteDivisionId: "",
237
+ latitude: 46.91529,
238
+ longitude: -121.84816,
239
+ elevationFeet: 4834,
240
+ };
241
+ static cataractValley = {
242
+ name: "Cataract Valley",
243
+ trailhead: false,
244
+ foodCacheStorage: false,
245
+ divisionId: "46753170003",
246
+ groupSiteDivisionId: "46753170004",
247
+ latitude: 46.94049,
248
+ longitude: -121.80486,
249
+ elevationFeet: 4488,
250
+ };
251
+ static ipsutCreek = {
252
+ name: "Ipsut Creek",
253
+ trailhead: false,
254
+ foodCacheStorage: false,
255
+ divisionId: "46753170011",
256
+ groupSiteDivisionId: "46753170012",
257
+ latitude: 46.97615,
258
+ longitude: -121.83022,
259
+ elevationFeet: 2359,
260
+ };
261
+ static carbonRiver = {
262
+ name: "Carbon River",
263
+ trailhead: false,
264
+ foodCacheStorage: false,
265
+ divisionId: "46753170001",
266
+ groupSiteDivisionId: "46753170002",
267
+ latitude: 46.95063,
268
+ longitude: -121.79991,
269
+ elevationFeet: 3255,
270
+ };
271
+ static dickCreek = {
272
+ name: "Dick Creek",
273
+ trailhead: false,
274
+ foodCacheStorage: false,
275
+ divisionId: "46753170005",
276
+ groupSiteDivisionId: "",
277
+ latitude: 46.94071,
278
+ longitude: -121.78431,
279
+ elevationFeet: 4114,
280
+ };
281
+ static mysticLake = {
282
+ name: "Mystic Lake",
283
+ trailhead: false,
284
+ foodCacheStorage: false,
285
+ divisionId: "46753170017",
286
+ groupSiteDivisionId: "46753170018",
287
+ latitude: 46.91570,
288
+ longitude: -121.75045,
289
+ elevationFeet: 5538,
290
+ };
291
+ static getLocations() {
292
+ return Iterable.create([
293
+ this.graniteCreek,
294
+ this.sunriseCamp,
295
+ this.sunriseVisitorCenter,
296
+ this.whiteRiver,
297
+ this.fryingPanCreek,
298
+ this.summerland,
299
+ this.indianBar,
300
+ this.nickelCreek,
301
+ this.boxCanyon,
302
+ this.mapleCreek,
303
+ this.reflectionLakes,
304
+ this.paradiseRiver,
305
+ this.longmire,
306
+ this.pyramidCreek,
307
+ this.devilsDream,
308
+ this.southPuyallupRiver,
309
+ this.klapatchePark,
310
+ this.northPuyallupRiver,
311
+ this.goldenLakes,
312
+ this.southMowichRiver,
313
+ this.mowichLake,
314
+ this.eaglesRoost,
315
+ this.cataractValley,
316
+ this.ipsutCreek,
317
+ this.carbonRiver,
318
+ this.dickCreek,
319
+ this.mysticLake,
320
+ ]);
321
+ }
322
+ static getTrailheads() {
323
+ return this.getLocations().where(location => location.trailhead);
324
+ }
325
+ }
326
+ export var WonderlandTrailReservationType;
327
+ (function (WonderlandTrailReservationType) {
328
+ WonderlandTrailReservationType[WonderlandTrailReservationType["Reserved"] = 0] = "Reserved";
329
+ WonderlandTrailReservationType[WonderlandTrailReservationType["Walkup"] = 1] = "Walkup";
330
+ })(WonderlandTrailReservationType || (WonderlandTrailReservationType = {}));
331
+ export class WonderlandTrailAvailability {
332
+ availabilityMap;
333
+ constructor() {
334
+ this.availabilityMap = Map.create();
335
+ }
336
+ static create() {
337
+ return new WonderlandTrailAvailability();
338
+ }
339
+ any() {
340
+ return this.availabilityMap.any().await();
341
+ }
342
+ addAvailability(location, date, individualSite, groupSite) {
343
+ PreCondition.assertNotUndefinedAndNotNull(location, "location");
344
+ PreCondition.assertNotUndefinedAndNotNull(date, "date");
345
+ const locationAvailability = this.getAvailability(location);
346
+ const dateString = date.toDateString();
347
+ const locationDayAvailability = locationAvailability.getOrSet(dateString, () => { return {}; }).await();
348
+ locationAvailability.set(dateString, {
349
+ individualSite: individualSite ?? locationDayAvailability.individualSite,
350
+ groupSite: groupSite ?? locationDayAvailability.groupSite,
351
+ });
352
+ }
353
+ getAvailability(location) {
354
+ PreCondition.assertNotUndefinedAndNotNull(location, "location");
355
+ return this.availabilityMap.getOrSet(location, () => MutableMap.create()).await();
356
+ }
357
+ getDayAvailability(location, date) {
358
+ PreCondition.assertNotUndefinedAndNotNull(location, "location");
359
+ PreCondition.assertNotUndefinedAndNotNull(date, "date");
360
+ return this.getAvailability(location).get(date.toDateString())
361
+ .convertError(NotFoundError, () => new NotFoundError(`No availability was found for ${location.name} on ${date.toDateString()}.`));
362
+ }
363
+ }
364
+ export class WonderlandTrailDirection {
365
+ value;
366
+ constructor(value) {
367
+ PreCondition.assertNotEmpty(value, "value");
368
+ this.value = value;
369
+ }
370
+ static clockwise = new WonderlandTrailDirection("Clockwise");
371
+ static counterClockwise = new WonderlandTrailDirection("CounterClockwise");
372
+ toString() {
373
+ return this.value;
374
+ }
375
+ reverse() {
376
+ return this === WonderlandTrailDirection.clockwise ? WonderlandTrailDirection.counterClockwise : WonderlandTrailDirection.clockwise;
377
+ }
378
+ }
379
+ export class WonderlandTrailConnection {
380
+ startLocation;
381
+ endLocation;
382
+ distanceMiles;
383
+ ascentFeet;
384
+ descentFeet;
385
+ direction;
386
+ intermediateLocations;
387
+ constructor(startLocation, endLocation, distanceMiles, ascentFeet, descentFeet, direction, intermediateLocations) {
388
+ PreCondition.assertNotUndefinedAndNotNull(startLocation, "startLocation");
389
+ PreCondition.assertNotUndefinedAndNotNull(endLocation, "endLocation");
390
+ PreCondition.assertGreaterThanOrEqualTo(distanceMiles, 0, "distanceMiles");
391
+ PreCondition.assertGreaterThanOrEqualTo(ascentFeet, 0, "ascentFeet");
392
+ PreCondition.assertGreaterThanOrEqualTo(descentFeet, 0, "descentFeet");
393
+ PreCondition.assertNotUndefinedAndNotNull(intermediateLocations, "intermediateLocations");
394
+ this.startLocation = startLocation;
395
+ this.endLocation = endLocation;
396
+ this.distanceMiles = distanceMiles;
397
+ this.ascentFeet = ascentFeet;
398
+ this.descentFeet = descentFeet;
399
+ this.direction = direction;
400
+ this.intermediateLocations = intermediateLocations;
401
+ }
402
+ static create(startLocation, endLocation, distanceMiles, ascentFeet, descentFeet, direction, intermediateLocations) {
403
+ return new WonderlandTrailConnection(startLocation, endLocation, distanceMiles, ascentFeet, descentFeet, direction, intermediateLocations);
404
+ }
405
+ getLocations() {
406
+ const result = List.create();
407
+ WonderlandTrailConnection.ensureExists(result, this.startLocation);
408
+ WonderlandTrailConnection.ensureAllExist(result, this.intermediateLocations);
409
+ WonderlandTrailConnection.ensureExists(result, this.endLocation);
410
+ return result;
411
+ }
412
+ static ensureExists(list, location) {
413
+ if (!list.contains(location).await()) {
414
+ list.add(location);
415
+ }
416
+ }
417
+ static ensureAllExist(list, locations) {
418
+ for (const location of locations) {
419
+ WonderlandTrailConnection.ensureExists(list, location);
420
+ }
421
+ }
422
+ reverseDirection() {
423
+ return WonderlandTrailConnection.create(this.endLocation, this.startLocation, this.distanceMiles, this.descentFeet, this.ascentFeet, this.direction.reverse(), this.intermediateLocations);
424
+ }
425
+ join(connection) {
426
+ const intermediateLocations = List.create();
427
+ WonderlandTrailConnection.ensureAllExist(intermediateLocations, this.intermediateLocations);
428
+ WonderlandTrailConnection.ensureExists(intermediateLocations, this.endLocation);
429
+ WonderlandTrailConnection.ensureExists(intermediateLocations, connection.startLocation);
430
+ WonderlandTrailConnection.ensureAllExist(intermediateLocations, connection.intermediateLocations);
431
+ return WonderlandTrailConnection.create(this.startLocation, connection.endLocation, this.distanceMiles + connection.distanceMiles, this.ascentFeet + connection.ascentFeet, this.descentFeet + connection.descentFeet, this.direction, intermediateLocations);
432
+ }
433
+ containsLocation(location) {
434
+ return this.getLocations().contains(location).await();
435
+ }
436
+ isLoop() {
437
+ return this.startLocation === this.endLocation;
438
+ }
439
+ }
440
+ export class WonderlandTrailConnections {
441
+ connections;
442
+ addReverseConnectionDefault;
443
+ constructor(addReverseConnectionDefault) {
444
+ this.connections = Map.create();
445
+ this.addReverseConnectionDefault = addReverseConnectionDefault;
446
+ }
447
+ static create(addReverseConnectionDefault) {
448
+ return new WonderlandTrailConnections(!!addReverseConnectionDefault);
449
+ }
450
+ static createDefault() {
451
+ return WonderlandTrailConnections.create(true)
452
+ .addConnection({
453
+ startLocation: WonderlandTrailLocations.whiteRiver,
454
+ endLocation: WonderlandTrailLocations.fryingPanCreek,
455
+ distanceMiles: 2.7,
456
+ ascentFeet: 100,
457
+ descentFeet: 600,
458
+ })
459
+ .addConnection({
460
+ startLocation: WonderlandTrailLocations.fryingPanCreek,
461
+ endLocation: WonderlandTrailLocations.summerland,
462
+ distanceMiles: 4.3,
463
+ ascentFeet: 2200,
464
+ descentFeet: 100,
465
+ })
466
+ .addConnection({
467
+ startLocation: WonderlandTrailLocations.summerland,
468
+ endLocation: WonderlandTrailLocations.indianBar,
469
+ distanceMiles: 4.7,
470
+ ascentFeet: 1200,
471
+ descentFeet: 2100,
472
+ })
473
+ .addConnection({
474
+ startLocation: WonderlandTrailLocations.indianBar,
475
+ endLocation: WonderlandTrailLocations.nickelCreek,
476
+ distanceMiles: 6.8,
477
+ ascentFeet: 1400,
478
+ descentFeet: 3200,
479
+ })
480
+ .addConnection({
481
+ startLocation: WonderlandTrailLocations.nickelCreek,
482
+ endLocation: WonderlandTrailLocations.boxCanyon,
483
+ distanceMiles: 0.9,
484
+ ascentFeet: 100,
485
+ descentFeet: 400,
486
+ })
487
+ .addConnection({
488
+ startLocation: WonderlandTrailLocations.boxCanyon,
489
+ endLocation: WonderlandTrailLocations.mapleCreek,
490
+ distanceMiles: 2.7,
491
+ ascentFeet: 500,
492
+ descentFeet: 700,
493
+ })
494
+ .addConnection({
495
+ startLocation: WonderlandTrailLocations.mapleCreek,
496
+ endLocation: WonderlandTrailLocations.reflectionLakes,
497
+ distanceMiles: 4.7,
498
+ ascentFeet: 2300,
499
+ descentFeet: 200,
500
+ })
501
+ .addConnection({
502
+ startLocation: WonderlandTrailLocations.reflectionLakes,
503
+ endLocation: WonderlandTrailLocations.paradiseRiver,
504
+ distanceMiles: 2.6,
505
+ ascentFeet: 200,
506
+ descentFeet: 1200,
507
+ })
508
+ .addConnection({
509
+ startLocation: WonderlandTrailLocations.paradiseRiver,
510
+ endLocation: WonderlandTrailLocations.longmire,
511
+ distanceMiles: 3.6,
512
+ ascentFeet: 100,
513
+ descentFeet: 1200,
514
+ })
515
+ .addConnection({
516
+ startLocation: WonderlandTrailLocations.longmire,
517
+ endLocation: WonderlandTrailLocations.pyramidCreek,
518
+ distanceMiles: 3.3,
519
+ ascentFeet: 1400,
520
+ descentFeet: 400,
521
+ })
522
+ .addConnection({
523
+ startLocation: WonderlandTrailLocations.pyramidCreek,
524
+ endLocation: WonderlandTrailLocations.devilsDream,
525
+ distanceMiles: 2.5,
526
+ ascentFeet: 1400,
527
+ descentFeet: 100,
528
+ })
529
+ .addConnection({
530
+ startLocation: WonderlandTrailLocations.devilsDream,
531
+ endLocation: WonderlandTrailLocations.southPuyallupRiver,
532
+ distanceMiles: 6.5,
533
+ ascentFeet: 1900,
534
+ descentFeet: 2700,
535
+ })
536
+ .addConnection({
537
+ startLocation: WonderlandTrailLocations.southPuyallupRiver,
538
+ endLocation: WonderlandTrailLocations.klapatchePark,
539
+ distanceMiles: 4.1,
540
+ ascentFeet: 2100,
541
+ descentFeet: 800,
542
+ })
543
+ .addConnection({
544
+ startLocation: WonderlandTrailLocations.klapatchePark,
545
+ endLocation: WonderlandTrailLocations.northPuyallupRiver,
546
+ distanceMiles: 2.6,
547
+ ascentFeet: 100,
548
+ descentFeet: 1900,
549
+ })
550
+ .addConnection({
551
+ startLocation: WonderlandTrailLocations.northPuyallupRiver,
552
+ endLocation: WonderlandTrailLocations.goldenLakes,
553
+ distanceMiles: 5.1,
554
+ ascentFeet: 1900,
555
+ descentFeet: 600,
556
+ })
557
+ .addConnection({
558
+ startLocation: WonderlandTrailLocations.goldenLakes,
559
+ endLocation: WonderlandTrailLocations.southMowichRiver,
560
+ distanceMiles: 5.8,
561
+ ascentFeet: 200,
562
+ descentFeet: 2400,
563
+ })
564
+ .addConnection({
565
+ startLocation: WonderlandTrailLocations.southMowichRiver,
566
+ endLocation: WonderlandTrailLocations.mowichLake,
567
+ distanceMiles: 4.4,
568
+ ascentFeet: 2400,
569
+ descentFeet: 300,
570
+ })
571
+ .addConnection({
572
+ startLocation: WonderlandTrailLocations.mowichLake,
573
+ endLocation: WonderlandTrailLocations.ipsutCreek,
574
+ distanceMiles: 5.6,
575
+ ascentFeet: 400,
576
+ descentFeet: 3000,
577
+ })
578
+ .addConnection({
579
+ startLocation: WonderlandTrailLocations.ipsutCreek,
580
+ endLocation: WonderlandTrailLocations.carbonRiver,
581
+ distanceMiles: 4,
582
+ ascentFeet: 1300,
583
+ descentFeet: 400,
584
+ })
585
+ .addConnection({
586
+ startLocation: WonderlandTrailLocations.mowichLake,
587
+ endLocation: WonderlandTrailLocations.eaglesRoost,
588
+ distanceMiles: 2,
589
+ ascentFeet: 500,
590
+ descentFeet: 600,
591
+ })
592
+ .addConnection({
593
+ startLocation: WonderlandTrailLocations.eaglesRoost,
594
+ endLocation: WonderlandTrailLocations.cataractValley,
595
+ distanceMiles: 12.4,
596
+ ascentFeet: 3300,
597
+ descentFeet: 3700,
598
+ })
599
+ .addConnection({
600
+ startLocation: WonderlandTrailLocations.cataractValley,
601
+ endLocation: WonderlandTrailLocations.carbonRiver,
602
+ distanceMiles: 1.6,
603
+ ascentFeet: 100,
604
+ descentFeet: 1300,
605
+ })
606
+ .addConnection({
607
+ startLocation: WonderlandTrailLocations.carbonRiver,
608
+ endLocation: WonderlandTrailLocations.dickCreek,
609
+ distanceMiles: 1.3,
610
+ ascentFeet: 1000,
611
+ descentFeet: 100,
612
+ })
613
+ .addConnection({
614
+ startLocation: WonderlandTrailLocations.dickCreek,
615
+ endLocation: WonderlandTrailLocations.mysticLake,
616
+ distanceMiles: 3.7,
617
+ ascentFeet: 2100,
618
+ descentFeet: 600,
619
+ })
620
+ .addConnection({
621
+ startLocation: WonderlandTrailLocations.mysticLake,
622
+ endLocation: WonderlandTrailLocations.graniteCreek,
623
+ distanceMiles: 4.1,
624
+ ascentFeet: 1500,
625
+ descentFeet: 1200,
626
+ })
627
+ .addConnection({
628
+ startLocation: WonderlandTrailLocations.graniteCreek,
629
+ endLocation: WonderlandTrailLocations.sunriseCamp,
630
+ distanceMiles: 4.6,
631
+ ascentFeet: 1400,
632
+ descentFeet: 1000,
633
+ })
634
+ .addConnection({
635
+ startLocation: WonderlandTrailLocations.sunriseCamp,
636
+ endLocation: WonderlandTrailLocations.whiteRiver,
637
+ distanceMiles: 3.5,
638
+ ascentFeet: 100,
639
+ descentFeet: 2100,
640
+ })
641
+ .addConnection({
642
+ startLocation: WonderlandTrailLocations.sunriseCamp,
643
+ endLocation: WonderlandTrailLocations.sunriseVisitorCenter,
644
+ distanceMiles: 1.4,
645
+ ascentFeet: 400,
646
+ descentFeet: 200,
647
+ })
648
+ .addConnection({
649
+ startLocation: WonderlandTrailLocations.sunriseVisitorCenter,
650
+ endLocation: WonderlandTrailLocations.whiteRiver,
651
+ distanceMiles: 3.1,
652
+ ascentFeet: 0,
653
+ descentFeet: 2200,
654
+ });
655
+ }
656
+ iterateConnections(startLocationOrProperties, endLocation, direction) {
657
+ let startLocation;
658
+ if (isWonderlandTrailLocation(startLocationOrProperties)) {
659
+ startLocation = startLocationOrProperties;
660
+ }
661
+ else if (startLocationOrProperties) {
662
+ startLocation = startLocationOrProperties.startLocation;
663
+ endLocation = startLocationOrProperties.endLocation;
664
+ direction = startLocationOrProperties.direction;
665
+ }
666
+ let result;
667
+ if (!startLocation) {
668
+ result = this.connections.iterateValues().flatMap(x => x);
669
+ }
670
+ else {
671
+ result = this.connections.get(startLocation)
672
+ .catch(NotFoundError, () => Iterable.create())
673
+ .await()
674
+ .iterate();
675
+ }
676
+ if (endLocation) {
677
+ result = result.where(connection => connection.endLocation == endLocation);
678
+ }
679
+ if (direction != null) {
680
+ result = result.where(connection => connection.direction == direction);
681
+ }
682
+ return result;
683
+ }
684
+ addConnectionInner(connection) {
685
+ const startLocationConnections = this.connections.getOrSet(connection.startLocation, () => List.create()).await();
686
+ startLocationConnections.add(connection);
687
+ }
688
+ addConnection(connectionStartLocationOrProperties, addReverseConnectionOrEndLocation, distanceMiles, ascentFeet, descentFeet, direction, intermediateLocations, addReverseConnection) {
689
+ let startLocation;
690
+ let endLocation;
691
+ if (isWonderlandTrailLocation(connectionStartLocationOrProperties)) {
692
+ startLocation = connectionStartLocationOrProperties;
693
+ }
694
+ else if (connectionStartLocationOrProperties instanceof WonderlandTrailConnection) {
695
+ startLocation = connectionStartLocationOrProperties.startLocation;
696
+ endLocation = connectionStartLocationOrProperties.endLocation;
697
+ distanceMiles = connectionStartLocationOrProperties.distanceMiles;
698
+ ascentFeet = connectionStartLocationOrProperties.ascentFeet;
699
+ descentFeet = connectionStartLocationOrProperties.descentFeet;
700
+ direction = connectionStartLocationOrProperties.direction;
701
+ intermediateLocations = connectionStartLocationOrProperties.intermediateLocations;
702
+ addReverseConnection = !!addReverseConnectionOrEndLocation;
703
+ }
704
+ else {
705
+ startLocation = connectionStartLocationOrProperties.startLocation;
706
+ endLocation = connectionStartLocationOrProperties.endLocation;
707
+ distanceMiles = connectionStartLocationOrProperties.distanceMiles;
708
+ ascentFeet = connectionStartLocationOrProperties.ascentFeet;
709
+ descentFeet = connectionStartLocationOrProperties.descentFeet;
710
+ direction = connectionStartLocationOrProperties.direction;
711
+ intermediateLocations = connectionStartLocationOrProperties.intermediateLocations;
712
+ addReverseConnection = connectionStartLocationOrProperties.addReverseConnection;
713
+ }
714
+ const connection = WonderlandTrailConnection.create(startLocation, endLocation, distanceMiles, ascentFeet, descentFeet, direction ?? WonderlandTrailDirection.clockwise, intermediateLocations ?? Iterable.create());
715
+ this.addConnectionInner(connection);
716
+ if (addReverseConnection ?? this.addReverseConnectionDefault) {
717
+ this.addConnectionInner(connection.reverseDirection());
718
+ }
719
+ return this;
720
+ }
721
+ containsConnection(connection) {
722
+ PreCondition.assertNotUndefinedAndNotNull(connection, "connection");
723
+ const startLocationConnections = this.connections.get(connection.startLocation).catch(() => undefined).await();
724
+ return startLocationConnections?.contains(connection)?.await() === true;
725
+ }
726
+ reverseDirection() {
727
+ const result = WonderlandTrailConnections.create(this.addReverseConnectionDefault);
728
+ for (const connection of this.iterateConnections()) {
729
+ result.addConnection(connection.reverseDirection());
730
+ }
731
+ return result;
732
+ }
733
+ expandConnections(startLocation, endLocation, direction) {
734
+ if (isUndefinedOrNull(direction)) {
735
+ direction = WonderlandTrailDirection.clockwise;
736
+ }
737
+ const result = WonderlandTrailConnections.create(this.addReverseConnectionDefault);
738
+ const toVisit = Stack.create();
739
+ toVisit.addAll(this.iterateConnections(startLocation, undefined, direction));
740
+ while (toVisit.any().await()) {
741
+ const currentConnection = toVisit.remove().await();
742
+ result.addConnection(currentConnection, false);
743
+ if (!currentConnection.isLoop() && currentConnection.endLocation !== endLocation) {
744
+ for (const endLocationConnection of this.iterateConnections(currentConnection.endLocation, undefined, direction)) {
745
+ if (!result.containsConnection(endLocationConnection) &&
746
+ !toVisit.contains(endLocationConnection)) {
747
+ toVisit.add(endLocationConnection);
748
+ }
749
+ if (!currentConnection.intermediateLocations.contains(endLocationConnection.endLocation)) {
750
+ toVisit.add(currentConnection.join(endLocationConnection));
751
+ }
752
+ }
753
+ }
754
+ }
755
+ return result;
756
+ }
757
+ }
758
+ export class WonderlandTrailItinerary {
759
+ startDay;
760
+ connections;
761
+ availabilityTypes;
762
+ constructor(startDay) {
763
+ PreCondition.assertNotUndefinedAndNotNull(startDay, "startDay");
764
+ this.startDay = startDay;
765
+ this.connections = List.create();
766
+ this.availabilityTypes = List.create();
767
+ }
768
+ static create(startDay) {
769
+ return new WonderlandTrailItinerary(startDay);
770
+ }
771
+ clone() {
772
+ return WonderlandTrailItinerary.create(this.startDay)
773
+ .addConnections(this.connections)
774
+ .addAvailabilityTypes(this.availabilityTypes);
775
+ }
776
+ getConnections() {
777
+ return this.connections;
778
+ }
779
+ getEndDay() {
780
+ return this.startDay.addDays(this.getDayCount() - 1);
781
+ }
782
+ getDayCount() {
783
+ return this.connections.getCount().await();
784
+ }
785
+ getStartLocation() {
786
+ return this.connections.first().then(firstConnection => firstConnection.startLocation);
787
+ }
788
+ getIntermediateLocations() {
789
+ const result = List.create();
790
+ for (const connection of this.connections) {
791
+ if (result.any().await()) {
792
+ result.add(connection.startLocation);
793
+ }
794
+ result.addAll(connection.intermediateLocations);
795
+ }
796
+ return result;
797
+ }
798
+ getEndLocation() {
799
+ return this.connections.last().then(lastConnection => lastConnection.endLocation);
800
+ }
801
+ getPath() {
802
+ const result = List.create();
803
+ for (const connection of this.connections) {
804
+ if (!result.any().await()) {
805
+ result.add(connection.startLocation);
806
+ }
807
+ result.add(connection.endLocation);
808
+ }
809
+ return result;
810
+ }
811
+ getPathStrings(includeAvailabilityTypes) {
812
+ includeAvailabilityTypes = includeAvailabilityTypes ?? true;
813
+ const result = List.create();
814
+ let availabilityTypeIndex = 0;
815
+ const availabilityTypeCount = this.availabilityTypes.getCount().await();
816
+ for (const connection of this.connections) {
817
+ if (!result.any().await()) {
818
+ result.add(connection.startLocation.name);
819
+ }
820
+ let pathString = connection.endLocation.name;
821
+ if (includeAvailabilityTypes && availabilityTypeIndex < availabilityTypeCount) {
822
+ pathString += " ";
823
+ const availabilityType = this.availabilityTypes.get(availabilityTypeIndex).await();
824
+ availabilityTypeIndex++;
825
+ if (availabilityType.individualSite !== undefined) {
826
+ if (availabilityType.groupSite !== undefined) {
827
+ pathString += `(Individual ${availabilityType.individualSite}/Group ${availabilityType.groupSite})`;
828
+ }
829
+ else {
830
+ pathString += `(Individual ${availabilityType.individualSite})`;
831
+ }
832
+ }
833
+ else {
834
+ pathString += `(Group ${availabilityType.groupSite})`;
835
+ }
836
+ }
837
+ result.add(pathString);
838
+ }
839
+ return result;
840
+ }
841
+ contains(parameters) {
842
+ PreCondition.assertNotUndefinedAndNotNull(parameters, "parameters");
843
+ const location = parameters.location;
844
+ const checkItineraryStartLocation = parameters.checkItineraryStartLocation ?? true;
845
+ const checkItineraryIntermediateLocations = parameters.checkItineraryIntermediateLocations ?? true;
846
+ const checkItineraryEndLocation = parameters.checkItineraryEndLocation ?? true;
847
+ PreCondition.assertNotUndefinedAndNotNull(location, "location");
848
+ let result = false;
849
+ const connectionCount = this.connections.getCount().await();
850
+ for (let i = 0; i < connectionCount; i++) {
851
+ if (i !== 0 || checkItineraryStartLocation) {
852
+ result = (this.connections.get(i).await().startLocation === location);
853
+ if (result) {
854
+ break;
855
+ }
856
+ }
857
+ if (checkItineraryIntermediateLocations) {
858
+ result = this.connections.get(i).await().intermediateLocations.contains(location).await();
859
+ if (result) {
860
+ break;
861
+ }
862
+ }
863
+ if (i === connectionCount - 1 && checkItineraryEndLocation) {
864
+ result = (this.connections.get(i).await().endLocation === location);
865
+ if (result) {
866
+ break;
867
+ }
868
+ }
869
+ }
870
+ return result;
871
+ }
872
+ containsAny(parameters) {
873
+ PreCondition.assertNotUndefinedAndNotNull(parameters, "parameters");
874
+ const connection = parameters.connection;
875
+ const checkConnectionStartLocation = parameters.checkConnectionStartLocation ?? true;
876
+ const checkConnectionIntermediateLocations = parameters.checkConnectionIntermediateLocations ?? true;
877
+ const checkConnectionEndLocation = parameters.checkConnectionEndLocation ?? true;
878
+ const checkItineraryStartLocation = parameters.checkItineraryStartLocation ?? true;
879
+ const checkItineraryIntermediateLocations = parameters.checkItineraryIntermediateLocations ?? true;
880
+ const checkItineraryEndLocation = parameters.checkItineraryEndLocation ?? true;
881
+ PreCondition.assertNotUndefinedAndNotNull(connection, "connection");
882
+ let result = false;
883
+ if (!result && checkConnectionStartLocation) {
884
+ result = this.contains({
885
+ location: connection.startLocation,
886
+ checkItineraryStartLocation,
887
+ checkItineraryIntermediateLocations,
888
+ checkItineraryEndLocation,
889
+ });
890
+ }
891
+ if (!result && checkConnectionIntermediateLocations) {
892
+ for (const connectionIntermediateLocation of connection.intermediateLocations) {
893
+ result = this.contains({
894
+ location: connectionIntermediateLocation,
895
+ checkItineraryStartLocation,
896
+ checkItineraryIntermediateLocations,
897
+ checkItineraryEndLocation,
898
+ });
899
+ if (result) {
900
+ break;
901
+ }
902
+ }
903
+ }
904
+ if (!result && checkConnectionEndLocation) {
905
+ result = this.contains({
906
+ location: connection.endLocation,
907
+ checkItineraryStartLocation,
908
+ checkItineraryIntermediateLocations,
909
+ checkItineraryEndLocation,
910
+ });
911
+ }
912
+ return result;
913
+ }
914
+ addConnection(connection) {
915
+ PreCondition.assertNotUndefinedAndNotNull(connection, "connection");
916
+ this.connections.add(connection);
917
+ return this;
918
+ }
919
+ addConnections(connections) {
920
+ PreCondition.assertNotUndefinedAndNotNull(connections, "connections");
921
+ this.connections.addAll(connections);
922
+ return this;
923
+ }
924
+ addAvailabilityType(availabilityType) {
925
+ PreCondition.assertNotUndefinedAndNotNull(availabilityType, "availabilityType");
926
+ this.availabilityTypes.add(availabilityType);
927
+ return this;
928
+ }
929
+ addAvailabilityTypes(availabilityTypes) {
930
+ PreCondition.assertNotUndefinedAndNotNull(availabilityTypes, "availabilityTypes");
931
+ this.availabilityTypes.addAll(availabilityTypes);
932
+ return this;
933
+ }
934
+ toString(includeAvailabilityTypes) {
935
+ includeAvailabilityTypes = includeAvailabilityTypes ?? true;
936
+ return `startDay:${this.startDay.toDateString()},path:${this.getPathStrings(includeAvailabilityTypes)}`;
937
+ }
938
+ }
939
+ export class WonderlandTrailClient {
940
+ static permitItineraryId = "4675317";
941
+ httpClient;
942
+ recreationDotGovClient;
943
+ constructor(httpClient) {
944
+ PreCondition.assertNotUndefinedAndNotNull(httpClient, "httpClient");
945
+ this.httpClient = httpClient;
946
+ this.recreationDotGovClient = RecreationDotGovClient.create(httpClient);
947
+ }
948
+ static create(httpClient) {
949
+ return new WonderlandTrailClient(httpClient);
950
+ }
951
+ sendRequest(request) {
952
+ return this.httpClient.sendRequest(request);
953
+ }
954
+ sendGetRequest(url) {
955
+ return HttpClient.sendGetRequest(this, url);
956
+ }
957
+ getAvailability(monthOrOptions, year, allowWalkupPermits, allowIndividualSites, allowGroupSites, earlyAccessPermitLotteryId) {
958
+ let month;
959
+ if (isNumber(monthOrOptions)) {
960
+ month = monthOrOptions;
961
+ year = year;
962
+ allowWalkupPermits = allowWalkupPermits;
963
+ allowIndividualSites = allowIndividualSites;
964
+ allowGroupSites = allowGroupSites;
965
+ }
966
+ else {
967
+ month = monthOrOptions.month;
968
+ year = monthOrOptions.year;
969
+ allowWalkupPermits = monthOrOptions.allowWalkupPermits;
970
+ allowIndividualSites = monthOrOptions.allowIndividualSites;
971
+ allowGroupSites = monthOrOptions.allowGroupSites;
972
+ earlyAccessPermitLotteryId = monthOrOptions.earlyAccessPermitLotteryId;
973
+ }
974
+ return PromiseAsyncResult.create(async () => {
975
+ const result = WonderlandTrailAvailability.create();
976
+ for (const location of WonderlandTrailLocations.getLocations()) {
977
+ if (allowIndividualSites && location.divisionId) {
978
+ const divisionAvailability = await this.recreationDotGovClient.getDivisionAvailability(WonderlandTrailClient.permitItineraryId, location.divisionId, month, year, earlyAccessPermitLotteryId);
979
+ const divisionDayAvailabilities = divisionAvailability.dayAvailabilities;
980
+ if (divisionDayAvailabilities) {
981
+ for (const divisionDayAvailability of divisionDayAvailabilities) {
982
+ const hasWalkupPermits = (allowWalkupPermits && divisionDayAvailability.walkup);
983
+ const hasReservationPermits = (divisionDayAvailability.reservationsRemaining > 0);
984
+ if (hasWalkupPermits || hasReservationPermits) {
985
+ result.addAvailability(location, divisionDayAvailability.date, hasWalkupPermits ? WonderlandTrailReservationType.Walkup : WonderlandTrailReservationType.Reserved, undefined);
986
+ }
987
+ }
988
+ }
989
+ }
990
+ if (allowGroupSites && location.groupSiteDivisionId) {
991
+ const groupSiteDivisionAvailability = await this.recreationDotGovClient.getDivisionAvailability(WonderlandTrailClient.permitItineraryId, location.groupSiteDivisionId, month, year, earlyAccessPermitLotteryId);
992
+ const groupSiteDivisionDayAvailabilities = groupSiteDivisionAvailability.dayAvailabilities;
993
+ if (groupSiteDivisionDayAvailabilities) {
994
+ for (const groupSiteDayAvailability of groupSiteDivisionDayAvailabilities) {
995
+ const hasWalkupPermits = (allowWalkupPermits && groupSiteDayAvailability.walkup);
996
+ const hasReservationPermits = (groupSiteDayAvailability.reservationsRemaining > 0);
997
+ if (hasWalkupPermits || hasReservationPermits) {
998
+ result.addAvailability(location, groupSiteDayAvailability.date, undefined, hasWalkupPermits ? WonderlandTrailReservationType.Walkup : WonderlandTrailReservationType.Reserved);
999
+ }
1000
+ }
1001
+ }
1002
+ }
1003
+ }
1004
+ return result;
1005
+ });
1006
+ }
1007
+ findItineraries(parameters) {
1008
+ PreCondition.assertNotUndefinedAndNotNull(parameters, "parameters");
1009
+ const availability = parameters.availability;
1010
+ const startDate = parameters.startDate;
1011
+ const startLocation = parameters.startLocation;
1012
+ const endLocation = parameters.endLocation;
1013
+ const direction = parameters.direction;
1014
+ const maximumDayDistanceMiles = parameters.maximumDayDistanceMiles;
1015
+ const maximumItineraryDays = parameters.maximumItineraryDays;
1016
+ const campsitesToAvoid = Iterable.create(parameters.campsitesToAvoid ?? []);
1017
+ const result = List.create();
1018
+ const connections = WonderlandTrailConnections.createDefault()
1019
+ .expandConnections(startLocation, endLocation, direction);
1020
+ let startLocationConnections = connections.iterateConnections(startLocation, undefined, direction);
1021
+ if (!isUndefinedOrNull(maximumDayDistanceMiles)) {
1022
+ startLocationConnections = startLocationConnections.where(connection => connection.distanceMiles <= maximumDayDistanceMiles);
1023
+ }
1024
+ const possibleItineraries = Stack.create();
1025
+ possibleItineraries.addAll(startLocationConnections.map(c => WonderlandTrailItinerary.create(startDate).addConnection(c)));
1026
+ while (possibleItineraries.any().await()) {
1027
+ const currentItinerary = possibleItineraries.remove().await();
1028
+ const currentItineraryEndLocation = currentItinerary.getEndLocation().await();
1029
+ if ((maximumItineraryDays === undefined || currentItinerary.getDayCount() <= maximumItineraryDays) &&
1030
+ (startLocation === currentItineraryEndLocation || endLocation === currentItineraryEndLocation || !campsitesToAvoid.contains(currentItineraryEndLocation).await())) {
1031
+ if (currentItineraryEndLocation === endLocation) {
1032
+ result.add(currentItinerary);
1033
+ }
1034
+ else {
1035
+ const dayAvailability = availability.getDayAvailability(currentItineraryEndLocation, currentItinerary.getEndDay())
1036
+ .catch(() => undefined)
1037
+ .await();
1038
+ if (dayAvailability) {
1039
+ currentItinerary.addAvailabilityType(dayAvailability);
1040
+ for (const nextDayConnection of connections.iterateConnections(currentItineraryEndLocation, undefined, direction)) {
1041
+ if (!currentItinerary.containsAny({
1042
+ connection: nextDayConnection,
1043
+ checkConnectionStartLocation: false,
1044
+ checkItineraryStartLocation: false,
1045
+ checkItineraryEndLocation: false,
1046
+ })) {
1047
+ if (maximumDayDistanceMiles === undefined || nextDayConnection.distanceMiles <= maximumDayDistanceMiles) {
1048
+ possibleItineraries.add(currentItinerary.clone().addConnection(nextDayConnection));
1049
+ }
1050
+ }
1051
+ }
1052
+ }
1053
+ }
1054
+ }
1055
+ }
1056
+ return result;
1057
+ }
1058
+ findItinerariesAsync(parameters) {
1059
+ PreCondition.assertNotUndefinedAndNotNull(parameters, "parameters");
1060
+ const startDay = parameters.startDay;
1061
+ const startLocation = parameters.startLocation;
1062
+ const endLocation = parameters.endLocation;
1063
+ const direction = parameters.direction;
1064
+ const maximumDayDistanceMiles = parameters.maximumDayDistanceMiles;
1065
+ const maximumItineraryDays = parameters.maximumItineraryDays;
1066
+ const allowWalkupPermits = parameters.allowWalkupPermits ?? true;
1067
+ const allowIndividualSites = parameters.allowIndividualSites ?? true;
1068
+ const allowGroupSites = parameters.allowGroupSites ?? false;
1069
+ const campsitesToAvoid = parameters.campsitesToAvoid ?? [];
1070
+ PreCondition.assertNotUndefinedAndNotNull(startDay, "startDay");
1071
+ return PromiseAsyncResult.create(async () => {
1072
+ const result = List.create();
1073
+ const startLocationsToCheck = (!isUndefinedOrNull(startLocation) ? Iterable.create([startLocation]) : WonderlandTrailLocations.getTrailheads());
1074
+ const directionsToCheck = (!isUndefinedOrNull(direction) ? Iterable.create([direction]) : Iterable.create([WonderlandTrailDirection.clockwise, WonderlandTrailDirection.counterClockwise]));
1075
+ const availability = await this.getAvailability(startDay.getMonth(), startDay.getYear(), allowWalkupPermits, allowIndividualSites, allowGroupSites);
1076
+ for (const startLocationToCheck of startLocationsToCheck) {
1077
+ for (const directionToCheck of directionsToCheck) {
1078
+ result.addAll(this.findItineraries({
1079
+ availability,
1080
+ startDate: startDay,
1081
+ startLocation: startLocationToCheck,
1082
+ endLocation: endLocation ?? startLocationToCheck,
1083
+ direction: directionToCheck,
1084
+ maximumDayDistanceMiles,
1085
+ maximumItineraryDays,
1086
+ campsitesToAvoid,
1087
+ }));
1088
+ }
1089
+ }
1090
+ return result;
1091
+ });
1092
+ }
1093
+ }
1094
+ //# sourceMappingURL=wonderlandTrailClient.js.map