@malloydata/malloy 0.0.22-dev230207144036 → 0.0.22-dev230207180844

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 (359) hide show
  1. package/dist/connection_utils.d.ts +1 -0
  2. package/dist/connection_utils.js +66 -0
  3. package/dist/dialect/dialect.d.ts +66 -0
  4. package/dist/dialect/dialect.js +85 -0
  5. package/dist/dialect/dialect_map.d.ts +3 -0
  6. package/dist/dialect/dialect_map.js +45 -0
  7. package/dist/dialect/duckdb.d.ts +52 -0
  8. package/dist/dialect/duckdb.js +364 -0
  9. package/dist/dialect/index.d.ts +6 -0
  10. package/dist/dialect/index.js +37 -0
  11. package/dist/dialect/postgres.d.ts +52 -0
  12. package/dist/dialect/postgres.js +330 -0
  13. package/dist/dialect/standardsql.d.ts +49 -0
  14. package/dist/dialect/standardsql.js +381 -0
  15. package/dist/index.d.ts +10 -0
  16. package/dist/index.js +59 -0
  17. package/dist/lang/ast/ast-utils.d.ts +10 -0
  18. package/dist/lang/ast/ast-utils.js +42 -0
  19. package/dist/lang/ast/elements/define-query.d.ts +14 -0
  20. package/dist/lang/ast/elements/define-query.js +56 -0
  21. package/dist/lang/ast/elements/define-source.d.ts +17 -0
  22. package/dist/lang/ast/elements/define-source.js +79 -0
  23. package/dist/lang/ast/elements/import-statement.d.ts +9 -0
  24. package/dist/lang/ast/elements/import-statement.js +78 -0
  25. package/dist/lang/ast/elements/pipeline-desc.d.ts +30 -0
  26. package/dist/lang/ast/elements/pipeline-desc.js +102 -0
  27. package/dist/lang/ast/elements/refined-source.d.ts +15 -0
  28. package/dist/lang/ast/elements/refined-source.js +121 -0
  29. package/dist/lang/ast/elements/source.d.ts +12 -0
  30. package/dist/lang/ast/elements/source.js +53 -0
  31. package/dist/lang/ast/error-factory.d.ts +9 -0
  32. package/dist/lang/ast/error-factory.js +61 -0
  33. package/dist/lang/ast/executors/index-executor.d.ts +18 -0
  34. package/dist/lang/ast/executors/index-executor.js +96 -0
  35. package/dist/lang/ast/executors/project-executor.d.ts +10 -0
  36. package/dist/lang/ast/executors/project-executor.js +68 -0
  37. package/dist/lang/ast/executors/reduce-executor.d.ts +21 -0
  38. package/dist/lang/ast/executors/reduce-executor.js +149 -0
  39. package/dist/lang/ast/expressions/apply.d.ts +8 -0
  40. package/dist/lang/ast/expressions/apply.js +37 -0
  41. package/dist/lang/ast/expressions/binary-boolean.d.ts +12 -0
  42. package/dist/lang/ast/expressions/binary-boolean.js +54 -0
  43. package/dist/lang/ast/expressions/binary-numeric.d.ts +11 -0
  44. package/dist/lang/ast/expressions/binary-numeric.js +42 -0
  45. package/dist/lang/ast/expressions/boolean.d.ts +8 -0
  46. package/dist/lang/ast/expressions/boolean.js +39 -0
  47. package/dist/lang/ast/expressions/constant-sub-expression.d.ts +16 -0
  48. package/dist/lang/ast/expressions/constant-sub-expression.js +98 -0
  49. package/dist/lang/ast/expressions/expr-add-sub.d.ts +4 -0
  50. package/dist/lang/ast/expressions/expr-add-sub.js +34 -0
  51. package/dist/lang/ast/expressions/expr-aggregate-function.d.ts +15 -0
  52. package/dist/lang/ast/expressions/expr-aggregate-function.js +99 -0
  53. package/dist/lang/ast/expressions/expr-alternation-tree.d.ts +11 -0
  54. package/dist/lang/ast/expressions/expr-alternation-tree.js +54 -0
  55. package/dist/lang/ast/expressions/expr-asymmetric.d.ts +10 -0
  56. package/dist/lang/ast/expressions/expr-asymmetric.js +27 -0
  57. package/dist/lang/ast/expressions/expr-avg.d.ts +6 -0
  58. package/dist/lang/ast/expressions/expr-avg.js +34 -0
  59. package/dist/lang/ast/expressions/expr-cast.d.ts +13 -0
  60. package/dist/lang/ast/expressions/expr-cast.js +29 -0
  61. package/dist/lang/ast/expressions/expr-compare.d.ts +10 -0
  62. package/dist/lang/ast/expressions/expr-compare.js +58 -0
  63. package/dist/lang/ast/expressions/expr-count-distinct.d.ts +6 -0
  64. package/dist/lang/ast/expressions/expr-count-distinct.js +35 -0
  65. package/dist/lang/ast/expressions/expr-count.d.ts +11 -0
  66. package/dist/lang/ast/expressions/expr-count.js +57 -0
  67. package/dist/lang/ast/expressions/expr-filter.d.ts +12 -0
  68. package/dist/lang/ast/expressions/expr-filter.js +69 -0
  69. package/dist/lang/ast/expressions/expr-func.d.ts +10 -0
  70. package/dist/lang/ast/expressions/expr-func.js +63 -0
  71. package/dist/lang/ast/expressions/expr-granular-time.d.ts +24 -0
  72. package/dist/lang/ast/expressions/expr-granular-time.js +117 -0
  73. package/dist/lang/ast/expressions/expr-id-reference.d.ts +12 -0
  74. package/dist/lang/ast/expressions/expr-id-reference.js +75 -0
  75. package/dist/lang/ast/expressions/expr-logical-op.d.ts +9 -0
  76. package/dist/lang/ast/expressions/expr-logical-op.js +36 -0
  77. package/dist/lang/ast/expressions/expr-max.d.ts +9 -0
  78. package/dist/lang/ast/expressions/expr-max.js +16 -0
  79. package/dist/lang/ast/expressions/expr-min.d.ts +9 -0
  80. package/dist/lang/ast/expressions/expr-min.js +16 -0
  81. package/dist/lang/ast/expressions/expr-minus.d.ts +9 -0
  82. package/dist/lang/ast/expressions/expr-minus.js +48 -0
  83. package/dist/lang/ast/expressions/expr-mul-div.d.ts +4 -0
  84. package/dist/lang/ast/expressions/expr-mul-div.js +34 -0
  85. package/dist/lang/ast/expressions/expr-not.d.ts +10 -0
  86. package/dist/lang/ast/expressions/expr-not.js +49 -0
  87. package/dist/lang/ast/expressions/expr-now.d.ts +7 -0
  88. package/dist/lang/ast/expressions/expr-now.js +46 -0
  89. package/dist/lang/ast/expressions/expr-null.d.ts +6 -0
  90. package/dist/lang/ast/expressions/expr-null.js +41 -0
  91. package/dist/lang/ast/expressions/expr-number.d.ts +10 -0
  92. package/dist/lang/ast/expressions/expr-number.js +42 -0
  93. package/dist/lang/ast/expressions/expr-parens.d.ts +10 -0
  94. package/dist/lang/ast/expressions/expr-parens.js +42 -0
  95. package/dist/lang/ast/expressions/expr-regex.d.ts +8 -0
  96. package/dist/lang/ast/expressions/expr-regex.js +42 -0
  97. package/dist/lang/ast/expressions/expr-string.d.ts +9 -0
  98. package/dist/lang/ast/expressions/expr-string.js +50 -0
  99. package/dist/lang/ast/expressions/expr-sum.d.ts +6 -0
  100. package/dist/lang/ast/expressions/expr-sum.js +12 -0
  101. package/dist/lang/ast/expressions/expr-time-extract.d.ts +13 -0
  102. package/dist/lang/ast/expressions/expr-time-extract.js +117 -0
  103. package/dist/lang/ast/expressions/expr-time.d.ts +11 -0
  104. package/dist/lang/ast/expressions/expr-time.js +62 -0
  105. package/dist/lang/ast/expressions/expr-ungroup.d.ts +14 -0
  106. package/dist/lang/ast/expressions/expr-ungroup.js +83 -0
  107. package/dist/lang/ast/expressions/for-range.d.ts +19 -0
  108. package/dist/lang/ast/expressions/for-range.js +101 -0
  109. package/dist/lang/ast/expressions/granular-literal.d.ts +20 -0
  110. package/dist/lang/ast/expressions/granular-literal.js +148 -0
  111. package/dist/lang/ast/expressions/partial-compare.d.ts +14 -0
  112. package/dist/lang/ast/expressions/partial-compare.js +50 -0
  113. package/dist/lang/ast/expressions/pick-when.d.ts +19 -0
  114. package/dist/lang/ast/expressions/pick-when.js +156 -0
  115. package/dist/lang/ast/expressions/range.d.ts +12 -0
  116. package/dist/lang/ast/expressions/range.js +80 -0
  117. package/dist/lang/ast/expressions/time-frame.d.ts +7 -0
  118. package/dist/lang/ast/expressions/time-frame.js +40 -0
  119. package/dist/lang/ast/expressions/top-by.d.ts +10 -0
  120. package/dist/lang/ast/expressions/top-by.js +51 -0
  121. package/dist/lang/ast/expressions/unary.d.ts +5 -0
  122. package/dist/lang/ast/expressions/unary.js +34 -0
  123. package/dist/lang/ast/expressions/utils.d.ts +12 -0
  124. package/dist/lang/ast/expressions/utils.js +87 -0
  125. package/dist/lang/ast/field-space/column-space-field.d.ts +9 -0
  126. package/dist/lang/ast/field-space/column-space-field.js +40 -0
  127. package/dist/lang/ast/field-space/dynamic-space.d.ts +22 -0
  128. package/dist/lang/ast/field-space/dynamic-space.js +140 -0
  129. package/dist/lang/ast/field-space/field-definition-value.d.ts +16 -0
  130. package/dist/lang/ast/field-space/field-definition-value.js +55 -0
  131. package/dist/lang/ast/field-space/index-field-space.d.ts +10 -0
  132. package/dist/lang/ast/field-space/index-field-space.js +57 -0
  133. package/dist/lang/ast/field-space/join-space-field.d.ts +8 -0
  134. package/dist/lang/ast/field-space/join-space-field.js +35 -0
  135. package/dist/lang/ast/field-space/project-field-space.d.ts +6 -0
  136. package/dist/lang/ast/field-space/project-field-space.js +51 -0
  137. package/dist/lang/ast/field-space/query-field-struct.d.ts +10 -0
  138. package/dist/lang/ast/field-space/query-field-struct.js +46 -0
  139. package/dist/lang/ast/field-space/query-space-field.d.ts +11 -0
  140. package/dist/lang/ast/field-space/query-space-field.js +37 -0
  141. package/dist/lang/ast/field-space/query-spaces.d.ts +50 -0
  142. package/dist/lang/ast/field-space/query-spaces.js +233 -0
  143. package/dist/lang/ast/field-space/reference-field.d.ts +11 -0
  144. package/dist/lang/ast/field-space/reference-field.js +45 -0
  145. package/dist/lang/ast/field-space/refined-space.d.ts +13 -0
  146. package/dist/lang/ast/field-space/refined-space.js +100 -0
  147. package/dist/lang/ast/field-space/rename-space-field.d.ts +11 -0
  148. package/dist/lang/ast/field-space/rename-space-field.js +50 -0
  149. package/dist/lang/ast/field-space/static-space.d.ts +29 -0
  150. package/dist/lang/ast/field-space/static-space.js +156 -0
  151. package/dist/lang/ast/field-space/struct-space-field-base.d.ts +11 -0
  152. package/dist/lang/ast/field-space/struct-space-field-base.js +40 -0
  153. package/dist/lang/ast/field-space/wild-space-field.d.ts +10 -0
  154. package/dist/lang/ast/field-space/wild-space-field.js +40 -0
  155. package/dist/lang/ast/fragtype-utils.d.ts +39 -0
  156. package/dist/lang/ast/fragtype-utils.js +100 -0
  157. package/dist/lang/ast/index.d.ts +90 -0
  158. package/dist/lang/ast/index.js +129 -0
  159. package/dist/lang/ast/parameters/constant-parameter.d.ts +8 -0
  160. package/dist/lang/ast/parameters/constant-parameter.js +54 -0
  161. package/dist/lang/ast/parameters/has-parameter.d.ts +19 -0
  162. package/dist/lang/ast/parameters/has-parameter.js +64 -0
  163. package/dist/lang/ast/query-elements/anonymous-query.d.ts +9 -0
  164. package/dist/lang/ast/query-elements/anonymous-query.js +41 -0
  165. package/dist/lang/ast/query-elements/existing-query.d.ts +11 -0
  166. package/dist/lang/ast/query-elements/existing-query.js +79 -0
  167. package/dist/lang/ast/query-elements/full-query.d.ts +10 -0
  168. package/dist/lang/ast/query-elements/full-query.js +85 -0
  169. package/dist/lang/ast/query-elements/query-head-struct.d.ts +9 -0
  170. package/dist/lang/ast/query-elements/query-head-struct.js +48 -0
  171. package/dist/lang/ast/query-items/field-declaration.d.ts +31 -0
  172. package/dist/lang/ast/query-items/field-declaration.js +137 -0
  173. package/dist/lang/ast/query-items/field-references.d.ts +25 -0
  174. package/dist/lang/ast/query-items/field-references.js +80 -0
  175. package/dist/lang/ast/query-properties/aggregate.d.ts +5 -0
  176. package/dist/lang/ast/query-properties/aggregate.js +39 -0
  177. package/dist/lang/ast/query-properties/declare-fields.d.ts +5 -0
  178. package/dist/lang/ast/query-properties/declare-fields.js +33 -0
  179. package/dist/lang/ast/query-properties/dimmensions.d.ts +5 -0
  180. package/dist/lang/ast/query-properties/dimmensions.js +36 -0
  181. package/dist/lang/ast/query-properties/filters.d.ts +18 -0
  182. package/dist/lang/ast/query-properties/filters.js +89 -0
  183. package/dist/lang/ast/query-properties/group-by.d.ts +5 -0
  184. package/dist/lang/ast/query-properties/group-by.js +39 -0
  185. package/dist/lang/ast/query-properties/indexing.d.ts +10 -0
  186. package/dist/lang/ast/query-properties/indexing.js +39 -0
  187. package/dist/lang/ast/query-properties/joins.d.ts +36 -0
  188. package/dist/lang/ast/query-properties/joins.js +143 -0
  189. package/dist/lang/ast/query-properties/limit.d.ts +6 -0
  190. package/dist/lang/ast/query-properties/limit.js +35 -0
  191. package/dist/lang/ast/query-properties/measures.d.ts +5 -0
  192. package/dist/lang/ast/query-properties/measures.js +36 -0
  193. package/dist/lang/ast/query-properties/nest-reference.d.ts +7 -0
  194. package/dist/lang/ast/query-properties/nest-reference.js +35 -0
  195. package/dist/lang/ast/query-properties/nest.d.ts +31 -0
  196. package/dist/lang/ast/query-properties/nest.js +133 -0
  197. package/dist/lang/ast/query-properties/nests.d.ts +5 -0
  198. package/dist/lang/ast/query-properties/nests.js +33 -0
  199. package/dist/lang/ast/query-properties/ordering.d.ts +15 -0
  200. package/dist/lang/ast/query-properties/ordering.js +66 -0
  201. package/dist/lang/ast/query-properties/project-statement.d.ts +5 -0
  202. package/dist/lang/ast/query-properties/project-statement.js +33 -0
  203. package/dist/lang/ast/query-properties/qop-desc.d.ts +17 -0
  204. package/dist/lang/ast/query-properties/qop-desc.js +124 -0
  205. package/dist/lang/ast/query-properties/sampling.d.ts +8 -0
  206. package/dist/lang/ast/query-properties/sampling.js +38 -0
  207. package/dist/lang/ast/query-properties/top.d.ts +13 -0
  208. package/dist/lang/ast/query-properties/top.js +60 -0
  209. package/dist/lang/ast/source-properties/field-list-edit.d.ts +8 -0
  210. package/dist/lang/ast/source-properties/field-list-edit.js +36 -0
  211. package/dist/lang/ast/source-properties/primary-key.d.ts +7 -0
  212. package/dist/lang/ast/source-properties/primary-key.js +35 -0
  213. package/dist/lang/ast/source-properties/renames.d.ts +11 -0
  214. package/dist/lang/ast/source-properties/renames.js +43 -0
  215. package/dist/lang/ast/source-properties/turtles.d.ts +5 -0
  216. package/dist/lang/ast/source-properties/turtles.js +33 -0
  217. package/dist/lang/ast/sources/named-source.d.ts +19 -0
  218. package/dist/lang/ast/sources/named-source.js +147 -0
  219. package/dist/lang/ast/sources/query-source.d.ts +9 -0
  220. package/dist/lang/ast/sources/query-source.js +41 -0
  221. package/dist/lang/ast/sources/sql-source.d.ts +7 -0
  222. package/dist/lang/ast/sources/sql-source.js +54 -0
  223. package/dist/lang/ast/sources/table-source.d.ts +8 -0
  224. package/dist/lang/ast/sources/table-source.js +60 -0
  225. package/dist/lang/ast/space-seed.d.ts +16 -0
  226. package/dist/lang/ast/space-seed.js +59 -0
  227. package/dist/lang/ast/sql-elements/sql-statement.d.ts +19 -0
  228. package/dist/lang/ast/sql-elements/sql-statement.js +80 -0
  229. package/dist/lang/ast/sql-elements/sql-string.d.ts +12 -0
  230. package/dist/lang/ast/sql-elements/sql-string.js +60 -0
  231. package/dist/lang/ast/struct-utils.d.ts +4 -0
  232. package/dist/lang/ast/struct-utils.js +48 -0
  233. package/dist/lang/ast/time-utils.d.ts +12 -0
  234. package/dist/lang/ast/time-utils.js +140 -0
  235. package/dist/lang/ast/types/comparison.d.ts +11 -0
  236. package/dist/lang/ast/types/comparison.js +41 -0
  237. package/dist/lang/ast/types/document-compile-result.d.ts +8 -0
  238. package/dist/lang/ast/types/document-compile-result.js +25 -0
  239. package/dist/lang/ast/types/equality.d.ts +7 -0
  240. package/dist/lang/ast/types/equality.js +37 -0
  241. package/dist/lang/ast/types/executor.d.ts +9 -0
  242. package/dist/lang/ast/types/executor.js +25 -0
  243. package/dist/lang/ast/types/explore-desc.d.ts +5 -0
  244. package/dist/lang/ast/types/explore-desc.js +33 -0
  245. package/dist/lang/ast/types/explore-field.d.ts +5 -0
  246. package/dist/lang/ast/types/explore-field.js +32 -0
  247. package/dist/lang/ast/types/expr-result.d.ts +5 -0
  248. package/dist/lang/ast/types/expr-result.js +25 -0
  249. package/dist/lang/ast/types/expr-value.d.ts +3 -0
  250. package/dist/lang/ast/types/expr-value.js +25 -0
  251. package/dist/lang/ast/types/expression-def.d.ts +69 -0
  252. package/dist/lang/ast/types/expression-def.js +346 -0
  253. package/dist/lang/ast/types/field-collection-member.d.ts +5 -0
  254. package/dist/lang/ast/types/field-collection-member.js +34 -0
  255. package/dist/lang/ast/types/field-decl.d.ts +7 -0
  256. package/dist/lang/ast/types/field-decl.js +37 -0
  257. package/dist/lang/ast/types/field-space.d.ts +24 -0
  258. package/dist/lang/ast/types/field-space.js +44 -0
  259. package/dist/lang/ast/types/granular-result.d.ts +7 -0
  260. package/dist/lang/ast/types/granular-result.js +11 -0
  261. package/dist/lang/ast/types/lookup-result.d.ts +10 -0
  262. package/dist/lang/ast/types/lookup-result.js +25 -0
  263. package/dist/lang/ast/types/malloy-element.d.ts +106 -0
  264. package/dist/lang/ast/types/malloy-element.js +398 -0
  265. package/dist/lang/ast/types/model-entry.d.ts +6 -0
  266. package/dist/lang/ast/types/model-entry.js +25 -0
  267. package/dist/lang/ast/types/name-space.d.ts +5 -0
  268. package/dist/lang/ast/types/name-space.js +25 -0
  269. package/dist/lang/ast/types/nested-query.d.ts +3 -0
  270. package/dist/lang/ast/types/nested-query.js +25 -0
  271. package/dist/lang/ast/types/op-desc.d.ts +6 -0
  272. package/dist/lang/ast/types/op-desc.js +25 -0
  273. package/dist/lang/ast/types/query-comp.d.ts +5 -0
  274. package/dist/lang/ast/types/query-comp.js +25 -0
  275. package/dist/lang/ast/types/query-element.d.ts +5 -0
  276. package/dist/lang/ast/types/query-element.js +32 -0
  277. package/dist/lang/ast/types/query-item.d.ts +5 -0
  278. package/dist/lang/ast/types/query-item.js +25 -0
  279. package/dist/lang/ast/types/query-property.d.ts +17 -0
  280. package/dist/lang/ast/types/query-property.js +55 -0
  281. package/dist/lang/ast/types/source-property.d.ts +10 -0
  282. package/dist/lang/ast/types/source-property.js +43 -0
  283. package/dist/lang/ast/types/space-entry.d.ts +5 -0
  284. package/dist/lang/ast/types/space-entry.js +29 -0
  285. package/dist/lang/ast/types/space-field.d.ts +10 -0
  286. package/dist/lang/ast/types/space-field.js +48 -0
  287. package/dist/lang/ast/types/space-param.d.ts +20 -0
  288. package/dist/lang/ast/types/space-param.js +61 -0
  289. package/dist/lang/ast/types/time-result.d.ts +6 -0
  290. package/dist/lang/ast/types/time-result.js +25 -0
  291. package/dist/lang/ast/types/turtle-headed-pipe.d.ts +7 -0
  292. package/dist/lang/ast/types/turtle-headed-pipe.js +37 -0
  293. package/dist/lang/ast/types/type-desc.d.ts +7 -0
  294. package/dist/lang/ast/types/type-desc.js +25 -0
  295. package/dist/lang/field-utils.d.ts +5 -0
  296. package/dist/lang/field-utils.js +43 -0
  297. package/dist/lang/index.d.ts +10 -0
  298. package/dist/lang/index.js +32 -0
  299. package/dist/lang/lib/Malloy/MalloyLexer.d.ts +165 -0
  300. package/dist/lang/lib/Malloy/MalloyLexer.js +1232 -0
  301. package/dist/lang/lib/Malloy/MalloyParser.d.ts +1947 -0
  302. package/dist/lang/lib/Malloy/MalloyParser.js +11909 -0
  303. package/dist/lang/lib/Malloy/MalloyParserListener.d.ts +2022 -0
  304. package/dist/lang/lib/Malloy/MalloyParserListener.js +4 -0
  305. package/dist/lang/lib/Malloy/MalloyParserVisitor.d.ts +1274 -0
  306. package/dist/lang/lib/Malloy/MalloyParserVisitor.js +4 -0
  307. package/dist/lang/malloy-to-ast.d.ts +155 -0
  308. package/dist/lang/malloy-to-ast.js +990 -0
  309. package/dist/lang/parse-error-handler.d.ts +9 -0
  310. package/dist/lang/parse-error-handler.js +44 -0
  311. package/dist/lang/parse-log.d.ts +27 -0
  312. package/dist/lang/parse-log.js +51 -0
  313. package/dist/lang/parse-malloy.d.ts +182 -0
  314. package/dist/lang/parse-malloy.js +728 -0
  315. package/dist/lang/parse-tree-walkers/document-completion-walker.d.ts +10 -0
  316. package/dist/lang/parse-tree-walkers/document-completion-walker.js +148 -0
  317. package/dist/lang/parse-tree-walkers/document-help-context-walker.d.ts +9 -0
  318. package/dist/lang/parse-tree-walkers/document-help-context-walker.js +107 -0
  319. package/dist/lang/parse-tree-walkers/document-highlight-walker.d.ts +83 -0
  320. package/dist/lang/parse-tree-walkers/document-highlight-walker.js +385 -0
  321. package/dist/lang/parse-tree-walkers/document-symbol-walker.d.ts +11 -0
  322. package/dist/lang/parse-tree-walkers/document-symbol-walker.js +182 -0
  323. package/dist/lang/parse-tree-walkers/explore-query-walker.d.ts +34 -0
  324. package/dist/lang/parse-tree-walkers/explore-query-walker.js +74 -0
  325. package/dist/lang/parse-tree-walkers/find-external-references.d.ts +11 -0
  326. package/dist/lang/parse-tree-walkers/find-external-references.js +61 -0
  327. package/dist/lang/reference-list.d.ts +10 -0
  328. package/dist/lang/reference-list.js +90 -0
  329. package/dist/lang/test/document-help-context-walker.spec.d.ts +1 -0
  330. package/dist/lang/test/document-help-context-walker.spec.js +55 -0
  331. package/dist/lang/test/document-symbol-walker.spec.d.ts +1 -0
  332. package/dist/lang/test/document-symbol-walker.spec.js +110 -0
  333. package/dist/lang/test/field-symbols.spec.d.ts +1 -0
  334. package/dist/lang/test/field-symbols.spec.js +184 -0
  335. package/dist/lang/test/parse.spec.d.ts +14 -0
  336. package/dist/lang/test/parse.spec.js +2135 -0
  337. package/dist/lang/test/test-translator.d.ts +41 -0
  338. package/dist/lang/test/test-translator.js +344 -0
  339. package/dist/lang/translate-response.d.ts +59 -0
  340. package/dist/lang/translate-response.js +30 -0
  341. package/dist/lang/zone.d.ts +57 -0
  342. package/dist/lang/zone.js +107 -0
  343. package/dist/malloy.d.ts +1146 -0
  344. package/dist/malloy.js +2413 -0
  345. package/dist/model/index.d.ts +2 -0
  346. package/dist/model/index.js +45 -0
  347. package/dist/model/malloy_query.d.ts +351 -0
  348. package/dist/model/malloy_query.js +3174 -0
  349. package/dist/model/malloy_types.d.ts +551 -0
  350. package/dist/model/malloy_types.js +378 -0
  351. package/dist/model/sql_block.d.ts +7 -0
  352. package/dist/model/sql_block.js +56 -0
  353. package/dist/model/utils.d.ts +22 -0
  354. package/dist/model/utils.js +102 -0
  355. package/dist/run_sql_options.d.ts +3 -0
  356. package/dist/run_sql_options.js +25 -0
  357. package/dist/runtime_types.d.ts +105 -0
  358. package/dist/runtime_types.js +25 -0
  359. package/package.json +2 -2
@@ -0,0 +1,156 @@
1
+ "use strict";
2
+ /*
3
+ * Copyright 2023 Google LLC
4
+ *
5
+ * Permission is hereby granted, free of charge, to any person obtaining
6
+ * a copy of this software and associated documentation files
7
+ * (the "Software"), to deal in the Software without restriction,
8
+ * including without limitation the rights to use, copy, modify, merge,
9
+ * publish, distribute, sublicense, and/or sell copies of the Software,
10
+ * and to permit persons to whom the Software is furnished to do so,
11
+ * subject to the following conditions:
12
+ *
13
+ * The above copyright notice and this permission notice shall be
14
+ * included in all copies or substantial portions of the Software.
15
+ *
16
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
19
+ * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
20
+ * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
21
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
22
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23
+ */
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.StructSpaceField = exports.StaticSpace = void 0;
26
+ const dialect_map_1 = require("../../../dialect/dialect_map");
27
+ const malloy_types_1 = require("../../../model/malloy_types");
28
+ const space_param_1 = require("../types/space-param");
29
+ const space_field_1 = require("../types/space-field");
30
+ const struct_space_field_base_1 = require("./struct-space-field-base");
31
+ const column_space_field_1 = require("./column-space-field");
32
+ const query_field_struct_1 = require("./query-field-struct");
33
+ class StaticSpace {
34
+ constructor(sourceStructDef) {
35
+ this.type = "fieldSpace";
36
+ this.fromStruct = sourceStructDef;
37
+ }
38
+ whenComplete(step) {
39
+ step();
40
+ }
41
+ dialectObj() {
42
+ try {
43
+ return (0, dialect_map_1.getDialect)(this.fromStruct.dialect);
44
+ }
45
+ catch {
46
+ return undefined;
47
+ }
48
+ }
49
+ defToSpaceField(from) {
50
+ if (from.type === "struct") {
51
+ return new StructSpaceField(from);
52
+ }
53
+ else if ((0, malloy_types_1.isTurtleDef)(from)) {
54
+ return new query_field_struct_1.QueryFieldStruct(this, from);
55
+ }
56
+ return new column_space_field_1.ColumnSpaceField(from);
57
+ }
58
+ get map() {
59
+ if (this.memoMap === undefined) {
60
+ this.memoMap = {};
61
+ for (const f of this.fromStruct.fields) {
62
+ const name = f.as || f.name;
63
+ this.memoMap[name] = this.defToSpaceField(f);
64
+ }
65
+ if (this.fromStruct.parameters) {
66
+ for (const [paramName, paramDef] of Object.entries(this.fromStruct.parameters)) {
67
+ if (this.memoMap[paramName]) {
68
+ throw new Error(`In struct '${this.fromStruct.as || this.fromStruct.name}': ` +
69
+ ` : Field and parameter name conflict '${paramName}`);
70
+ }
71
+ this.memoMap[paramName] = new space_param_1.DefinedParameter(paramDef);
72
+ }
73
+ }
74
+ }
75
+ return this.memoMap;
76
+ }
77
+ dropEntries() {
78
+ this.memoMap = {};
79
+ }
80
+ dropEntry(name) {
81
+ delete this.map[name];
82
+ }
83
+ entry(name) {
84
+ return this.map[name];
85
+ }
86
+ setEntry(name, value) {
87
+ this.map[name] = value;
88
+ }
89
+ entries() {
90
+ return Object.entries(this.map);
91
+ }
92
+ structDef() {
93
+ return this.fromStruct;
94
+ }
95
+ emptyStructDef() {
96
+ return { ...this.fromStruct, fields: [] };
97
+ }
98
+ lookup(path) {
99
+ const head = path[0];
100
+ const rest = path.slice(1);
101
+ const found = this.entry(head.refString);
102
+ if (!found) {
103
+ return { error: `'${head}' is not defined`, found };
104
+ }
105
+ if (found instanceof space_field_1.SpaceField) {
106
+ /*
107
+ * TODO cache defs, post the addReference call to whenComplete
108
+ *
109
+ * In the cleanup phase of query space construction, it may check
110
+ * the output space for ungrouping variables. However if an
111
+ * ungrouping variable is a measure, the field expression value
112
+ * needed to get the definition needs to be computed in the
113
+ * input space of the query. There is a test which failed which
114
+ * caused this code to be here, but this is really a bandaid.
115
+ *
116
+ * Some re-work of how to get the definition of a SpaceField
117
+ * no matter what it is contained in needs to be thought out.
118
+ *
119
+ * ... or this check would look at the finalized output of
120
+ * the namespace and not re-compile ...
121
+ */
122
+ const definition = found.fieldDef();
123
+ if (definition) {
124
+ head.addReference({
125
+ type: found instanceof struct_space_field_base_1.StructSpaceFieldBase
126
+ ? "joinReference"
127
+ : "fieldReference",
128
+ definition,
129
+ location: head.location,
130
+ text: head.refString,
131
+ });
132
+ }
133
+ }
134
+ if (rest.length) {
135
+ if (found instanceof struct_space_field_base_1.StructSpaceFieldBase) {
136
+ return found.fieldSpace.lookup(rest);
137
+ }
138
+ return {
139
+ error: `'${head}' cannot contain a '${rest[0]}'`,
140
+ found: undefined,
141
+ };
142
+ }
143
+ return { found, error: undefined };
144
+ }
145
+ }
146
+ exports.StaticSpace = StaticSpace;
147
+ class StructSpaceField extends struct_space_field_base_1.StructSpaceFieldBase {
148
+ constructor(def) {
149
+ super(def);
150
+ }
151
+ get fieldSpace() {
152
+ return new StaticSpace(this.sourceDef);
153
+ }
154
+ }
155
+ exports.StructSpaceField = StructSpaceField;
156
+ //# sourceMappingURL=static-space.js.map
@@ -0,0 +1,11 @@
1
+ import { FieldDef, StructDef } from "../../../model/malloy_types";
2
+ import { FieldSpace } from "../types/field-space";
3
+ import { SpaceField } from "../types/space-field";
4
+ import { TypeDesc } from "../types/type-desc";
5
+ export declare abstract class StructSpaceFieldBase extends SpaceField {
6
+ protected sourceDef: StructDef;
7
+ constructor(sourceDef: StructDef);
8
+ abstract get fieldSpace(): FieldSpace;
9
+ fieldDef(): FieldDef;
10
+ typeDesc(): TypeDesc;
11
+ }
@@ -0,0 +1,40 @@
1
+ "use strict";
2
+ /*
3
+ * Copyright 2023 Google LLC
4
+ *
5
+ * Permission is hereby granted, free of charge, to any person obtaining
6
+ * a copy of this software and associated documentation files
7
+ * (the "Software"), to deal in the Software without restriction,
8
+ * including without limitation the rights to use, copy, modify, merge,
9
+ * publish, distribute, sublicense, and/or sell copies of the Software,
10
+ * and to permit persons to whom the Software is furnished to do so,
11
+ * subject to the following conditions:
12
+ *
13
+ * The above copyright notice and this permission notice shall be
14
+ * included in all copies or substantial portions of the Software.
15
+ *
16
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
19
+ * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
20
+ * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
21
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
22
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23
+ */
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.StructSpaceFieldBase = void 0;
26
+ const space_field_1 = require("../types/space-field");
27
+ class StructSpaceFieldBase extends space_field_1.SpaceField {
28
+ constructor(sourceDef) {
29
+ super();
30
+ this.sourceDef = sourceDef;
31
+ }
32
+ fieldDef() {
33
+ return this.sourceDef;
34
+ }
35
+ typeDesc() {
36
+ return { dataType: "struct", expressionType: "scalar" };
37
+ }
38
+ }
39
+ exports.StructSpaceFieldBase = StructSpaceFieldBase;
40
+ //# sourceMappingURL=struct-space-field-base.js.map
@@ -0,0 +1,10 @@
1
+ import { QueryFieldDef } from "../../../model/malloy_types";
2
+ import { FieldSpace } from "../types/field-space";
3
+ import { SpaceField } from "../types/space-field";
4
+ import { TypeDesc } from "../types/type-desc";
5
+ export declare class WildSpaceField extends SpaceField {
6
+ readonly wildText: string;
7
+ constructor(wildText: string);
8
+ typeDesc(): TypeDesc;
9
+ getQueryFieldDef(_fs: FieldSpace): QueryFieldDef;
10
+ }
@@ -0,0 +1,40 @@
1
+ "use strict";
2
+ /*
3
+ * Copyright 2023 Google LLC
4
+ *
5
+ * Permission is hereby granted, free of charge, to any person obtaining
6
+ * a copy of this software and associated documentation files
7
+ * (the "Software"), to deal in the Software without restriction,
8
+ * including without limitation the rights to use, copy, modify, merge,
9
+ * publish, distribute, sublicense, and/or sell copies of the Software,
10
+ * and to permit persons to whom the Software is furnished to do so,
11
+ * subject to the following conditions:
12
+ *
13
+ * The above copyright notice and this permission notice shall be
14
+ * included in all copies or substantial portions of the Software.
15
+ *
16
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
19
+ * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
20
+ * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
21
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
22
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23
+ */
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.WildSpaceField = void 0;
26
+ const space_field_1 = require("../types/space-field");
27
+ class WildSpaceField extends space_field_1.SpaceField {
28
+ constructor(wildText) {
29
+ super();
30
+ this.wildText = wildText;
31
+ }
32
+ typeDesc() {
33
+ throw new Error("should never ask a wild field for its type");
34
+ }
35
+ getQueryFieldDef(_fs) {
36
+ return this.wildText;
37
+ }
38
+ }
39
+ exports.WildSpaceField = WildSpaceField;
40
+ //# sourceMappingURL=wild-space-field.js.map
@@ -0,0 +1,39 @@
1
+ import { TypeDesc } from "./types/type-desc";
2
+ /**
3
+ * Collects functions which operate on fragtype compatible objects
4
+ */
5
+ export declare class FT {
6
+ /**
7
+ * Checks if a given type is in a list
8
+ * @param check The type to check (can be undefined)
9
+ * @param from List of types which are OK
10
+ */
11
+ static in(check: TypeDesc | undefined, from: TypeDesc[]): boolean;
12
+ /**
13
+ * Checks if a possibly undefined candidate matches a type
14
+ * @param good The real type
15
+ * @param checkThis The possibly undefined candidate
16
+ */
17
+ static eq(good: TypeDesc, checkThis: TypeDesc | undefined): boolean;
18
+ /**
19
+ * Checks if the base types, ignoring aggregate, are equal
20
+ * @param left Left type
21
+ * @param right Right type
22
+ * @param nullOk True if a NULL is an acceptable match
23
+ */
24
+ static typeEq(left: TypeDesc, right: TypeDesc, nullOk?: boolean): boolean;
25
+ /**
26
+ *
27
+ * For error messages, returns a comma seperated list of readable names
28
+ * for a list of types.
29
+ * @param types List of type or objects with types
30
+ */
31
+ static inspect(...types: (TypeDesc | undefined)[]): string;
32
+ static nullT: TypeDesc;
33
+ static numberT: TypeDesc;
34
+ static stringT: TypeDesc;
35
+ static dateT: TypeDesc;
36
+ static timestampT: TypeDesc;
37
+ static boolT: TypeDesc;
38
+ static anyAtomicT: TypeDesc[];
39
+ }
@@ -0,0 +1,100 @@
1
+ "use strict";
2
+ /*
3
+ * Copyright 2023 Google LLC
4
+ *
5
+ * Permission is hereby granted, free of charge, to any person obtaining
6
+ * a copy of this software and associated documentation files
7
+ * (the "Software"), to deal in the Software without restriction,
8
+ * including without limitation the rights to use, copy, modify, merge,
9
+ * publish, distribute, sublicense, and/or sell copies of the Software,
10
+ * and to permit persons to whom the Software is furnished to do so,
11
+ * subject to the following conditions:
12
+ *
13
+ * The above copyright notice and this permission notice shall be
14
+ * included in all copies or substantial portions of the Software.
15
+ *
16
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
19
+ * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
20
+ * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
21
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
22
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23
+ */
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.FT = void 0;
26
+ function mkFragType(dType) {
27
+ return { dataType: dType, expressionType: "scalar" };
28
+ }
29
+ /**
30
+ * Collects functions which operate on fragtype compatible objects
31
+ */
32
+ class FT {
33
+ /**
34
+ * Checks if a given type is in a list
35
+ * @param check The type to check (can be undefined)
36
+ * @param from List of types which are OK
37
+ */
38
+ static in(check, from) {
39
+ if (check) {
40
+ const found = from.find((okType) => FT.eq(okType, check));
41
+ return found !== undefined;
42
+ }
43
+ return false;
44
+ }
45
+ /**
46
+ * Checks if a possibly undefined candidate matches a type
47
+ * @param good The real type
48
+ * @param checkThis The possibly undefined candidate
49
+ */
50
+ static eq(good, checkThis) {
51
+ return (checkThis !== undefined &&
52
+ good.dataType === checkThis.dataType &&
53
+ good.expressionType === checkThis.expressionType);
54
+ }
55
+ /**
56
+ * Checks if the base types, ignoring aggregate, are equal
57
+ * @param left Left type
58
+ * @param right Right type
59
+ * @param nullOk True if a NULL is an acceptable match
60
+ */
61
+ static typeEq(left, right, nullOk = false) {
62
+ const maybeEq = left.dataType === right.dataType;
63
+ const nullEq = nullOk && (left.dataType === "null" || right.dataType === "null");
64
+ return maybeEq || nullEq;
65
+ }
66
+ /**
67
+ *
68
+ * For error messages, returns a comma seperated list of readable names
69
+ * for a list of types.
70
+ * @param types List of type or objects with types
71
+ */
72
+ static inspect(...types) {
73
+ const strings = types.map((type) => {
74
+ if (type) {
75
+ let inspected = type.dataType;
76
+ if (type.expressionType != "scalar") {
77
+ inspected = `${type.expressionType} ${inspected}`;
78
+ }
79
+ return inspected;
80
+ }
81
+ return "undefined";
82
+ });
83
+ return strings.join(",");
84
+ }
85
+ }
86
+ exports.FT = FT;
87
+ FT.nullT = mkFragType("null");
88
+ FT.numberT = mkFragType("number");
89
+ FT.stringT = mkFragType("string");
90
+ FT.dateT = mkFragType("date");
91
+ FT.timestampT = mkFragType("timestamp");
92
+ FT.boolT = mkFragType("boolean");
93
+ FT.anyAtomicT = [
94
+ FT.numberT,
95
+ FT.stringT,
96
+ FT.dateT,
97
+ FT.timestampT,
98
+ FT.boolT,
99
+ ];
100
+ //# sourceMappingURL=fragtype-utils.js.map
@@ -0,0 +1,90 @@
1
+ export * from "./query-properties/nest";
2
+ export * from "./elements/define-source";
3
+ export * from "./elements/define-query";
4
+ export * from "./elements/source";
5
+ export * from "./elements/refined-source";
6
+ export * from "./source-properties/field-list-edit";
7
+ export * from "./source-properties/primary-key";
8
+ export * from "./source-properties/renames";
9
+ export * from "./source-properties/turtles";
10
+ export * from "./expressions/apply";
11
+ export * from "./expressions/binary-numeric";
12
+ export * from "./expressions/boolean";
13
+ export * from "./expressions/expr-add-sub";
14
+ export * from "./expressions/expr-aggregate-function";
15
+ export * from "./expressions/expr-alternation-tree";
16
+ export * from "./expressions/expr-asymmetric";
17
+ export * from "./expressions/expr-avg";
18
+ export * from "./expressions/expr-cast";
19
+ export * from "./expressions/expr-compare";
20
+ export * from "./expressions/expr-count";
21
+ export * from "./expressions/expr-count-distinct";
22
+ export * from "./expressions/expr-filter";
23
+ export * from "./expressions/expr-func";
24
+ export * from "./expressions/expr-granular-time";
25
+ export * from "./expressions/expr-id-reference";
26
+ export * from "./expressions/expr-logical-op";
27
+ export * from "./expressions/expr-max";
28
+ export * from "./expressions/expr-min";
29
+ export * from "./expressions/expr-minus";
30
+ export * from "./expressions/expr-mul-div";
31
+ export * from "./expressions/expr-not";
32
+ export * from "./expressions/expr-now";
33
+ export * from "./expressions/expr-null";
34
+ export * from "./expressions/expr-number";
35
+ export * from "./expressions/expr-parens";
36
+ export * from "./expressions/expr-regex";
37
+ export * from "./expressions/expr-string";
38
+ export * from "./expressions/expr-sum";
39
+ export * from "./expressions/expr-time-extract";
40
+ export * from "./expressions/expr-ungroup";
41
+ export * from "./expressions/for-range";
42
+ export * from "./expressions/granular-literal";
43
+ export * from "./expressions/partial-compare";
44
+ export * from "./expressions/pick-when";
45
+ export * from "./expressions/range";
46
+ export * from "./expressions/time-frame";
47
+ export * from "./expressions/top-by";
48
+ export * from "./expressions/unary";
49
+ export * from "./expressions/utils";
50
+ export * from "./elements/import-statement";
51
+ export * from "./query-properties/nest-reference";
52
+ export * from "./parameters/has-parameter";
53
+ export * from "./query-elements/anonymous-query";
54
+ export * from "./query-elements/existing-query";
55
+ export * from "./query-elements/full-query";
56
+ export * from "./query-items/field-declaration";
57
+ export * from "./query-items/field-references";
58
+ export * from "./query-properties/aggregate";
59
+ export * from "./query-properties/declare-fields";
60
+ export * from "./query-properties/dimmensions";
61
+ export * from "./query-properties/filters";
62
+ export * from "./query-properties/group-by";
63
+ export * from "./query-properties/indexing";
64
+ export * from "./query-properties/joins";
65
+ export * from "./query-properties/limit";
66
+ export * from "./query-properties/measures";
67
+ export * from "./query-properties/nests";
68
+ export * from "./query-properties/ordering";
69
+ export * from "./query-properties/project-statement";
70
+ export * from "./query-properties/qop-desc";
71
+ export * from "./query-properties/sampling";
72
+ export * from "./query-properties/top";
73
+ export * from "./sources/named-source";
74
+ export * from "./sources/query-source";
75
+ export * from "./sources/sql-source";
76
+ export * from "./sources/table-source";
77
+ export * from "./sql-elements/sql-statement";
78
+ export * from "./sql-elements/sql-string";
79
+ export * from "./types/comparison";
80
+ export * from "./types/explore-desc";
81
+ export * from "./types/source-property";
82
+ export * from "./types/expression-def";
83
+ export * from "./types/field-collection-member";
84
+ export * from "./types/field-space";
85
+ export * from "./types/malloy-element";
86
+ export * from "./types/nested-query";
87
+ export * from "./types/query-element";
88
+ export * from "./types/query-item";
89
+ export * from "./types/query-property";
90
+ export * from "./types/turtle-headed-pipe";
@@ -0,0 +1,129 @@
1
+ "use strict";
2
+ /*
3
+ * Copyright 2023 Google LLC
4
+ *
5
+ * Permission is hereby granted, free of charge, to any person obtaining
6
+ * a copy of this software and associated documentation files
7
+ * (the "Software"), to deal in the Software without restriction,
8
+ * including without limitation the rights to use, copy, modify, merge,
9
+ * publish, distribute, sublicense, and/or sell copies of the Software,
10
+ * and to permit persons to whom the Software is furnished to do so,
11
+ * subject to the following conditions:
12
+ *
13
+ * The above copyright notice and this permission notice shall be
14
+ * included in all copies or substantial portions of the Software.
15
+ *
16
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
19
+ * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
20
+ * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
21
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
22
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23
+ */
24
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
25
+ if (k2 === undefined) k2 = k;
26
+ var desc = Object.getOwnPropertyDescriptor(m, k);
27
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
28
+ desc = { enumerable: true, get: function() { return m[k]; } };
29
+ }
30
+ Object.defineProperty(o, k2, desc);
31
+ }) : (function(o, m, k, k2) {
32
+ if (k2 === undefined) k2 = k;
33
+ o[k2] = m[k];
34
+ }));
35
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
36
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
37
+ };
38
+ Object.defineProperty(exports, "__esModule", { value: true });
39
+ __exportStar(require("./query-properties/nest"), exports);
40
+ __exportStar(require("./elements/define-source"), exports);
41
+ __exportStar(require("./elements/define-query"), exports);
42
+ __exportStar(require("./elements/source"), exports);
43
+ __exportStar(require("./elements/refined-source"), exports);
44
+ __exportStar(require("./source-properties/field-list-edit"), exports);
45
+ __exportStar(require("./source-properties/primary-key"), exports);
46
+ __exportStar(require("./source-properties/renames"), exports);
47
+ __exportStar(require("./source-properties/turtles"), exports);
48
+ __exportStar(require("./expressions/apply"), exports);
49
+ __exportStar(require("./expressions/binary-numeric"), exports);
50
+ __exportStar(require("./expressions/boolean"), exports);
51
+ __exportStar(require("./expressions/expr-add-sub"), exports);
52
+ __exportStar(require("./expressions/expr-aggregate-function"), exports);
53
+ __exportStar(require("./expressions/expr-alternation-tree"), exports);
54
+ __exportStar(require("./expressions/expr-asymmetric"), exports);
55
+ __exportStar(require("./expressions/expr-avg"), exports);
56
+ __exportStar(require("./expressions/expr-cast"), exports);
57
+ __exportStar(require("./expressions/expr-compare"), exports);
58
+ __exportStar(require("./expressions/expr-count"), exports);
59
+ __exportStar(require("./expressions/expr-count-distinct"), exports);
60
+ __exportStar(require("./expressions/expr-filter"), exports);
61
+ __exportStar(require("./expressions/expr-func"), exports);
62
+ __exportStar(require("./expressions/expr-granular-time"), exports);
63
+ __exportStar(require("./expressions/expr-id-reference"), exports);
64
+ __exportStar(require("./expressions/expr-logical-op"), exports);
65
+ __exportStar(require("./expressions/expr-max"), exports);
66
+ __exportStar(require("./expressions/expr-min"), exports);
67
+ __exportStar(require("./expressions/expr-minus"), exports);
68
+ __exportStar(require("./expressions/expr-mul-div"), exports);
69
+ __exportStar(require("./expressions/expr-not"), exports);
70
+ __exportStar(require("./expressions/expr-now"), exports);
71
+ __exportStar(require("./expressions/expr-null"), exports);
72
+ __exportStar(require("./expressions/expr-number"), exports);
73
+ __exportStar(require("./expressions/expr-parens"), exports);
74
+ __exportStar(require("./expressions/expr-regex"), exports);
75
+ __exportStar(require("./expressions/expr-string"), exports);
76
+ __exportStar(require("./expressions/expr-sum"), exports);
77
+ __exportStar(require("./expressions/expr-time-extract"), exports);
78
+ __exportStar(require("./expressions/expr-ungroup"), exports);
79
+ __exportStar(require("./expressions/for-range"), exports);
80
+ __exportStar(require("./expressions/granular-literal"), exports);
81
+ __exportStar(require("./expressions/partial-compare"), exports);
82
+ __exportStar(require("./expressions/pick-when"), exports);
83
+ __exportStar(require("./expressions/range"), exports);
84
+ __exportStar(require("./expressions/time-frame"), exports);
85
+ __exportStar(require("./expressions/top-by"), exports);
86
+ __exportStar(require("./expressions/unary"), exports);
87
+ __exportStar(require("./expressions/utils"), exports);
88
+ __exportStar(require("./elements/import-statement"), exports);
89
+ __exportStar(require("./query-properties/nest-reference"), exports);
90
+ __exportStar(require("./parameters/has-parameter"), exports);
91
+ __exportStar(require("./query-elements/anonymous-query"), exports);
92
+ __exportStar(require("./query-elements/existing-query"), exports);
93
+ __exportStar(require("./query-elements/full-query"), exports);
94
+ __exportStar(require("./query-items/field-declaration"), exports);
95
+ __exportStar(require("./query-items/field-references"), exports);
96
+ __exportStar(require("./query-properties/aggregate"), exports);
97
+ __exportStar(require("./query-properties/declare-fields"), exports);
98
+ __exportStar(require("./query-properties/dimmensions"), exports);
99
+ __exportStar(require("./query-properties/filters"), exports);
100
+ __exportStar(require("./query-properties/group-by"), exports);
101
+ __exportStar(require("./query-properties/indexing"), exports);
102
+ __exportStar(require("./query-properties/joins"), exports);
103
+ __exportStar(require("./query-properties/limit"), exports);
104
+ __exportStar(require("./query-properties/measures"), exports);
105
+ __exportStar(require("./query-properties/nests"), exports);
106
+ __exportStar(require("./query-properties/ordering"), exports);
107
+ __exportStar(require("./query-properties/project-statement"), exports);
108
+ __exportStar(require("./query-properties/qop-desc"), exports);
109
+ __exportStar(require("./query-properties/sampling"), exports);
110
+ __exportStar(require("./query-properties/top"), exports);
111
+ __exportStar(require("./sources/named-source"), exports);
112
+ __exportStar(require("./sources/query-source"), exports);
113
+ __exportStar(require("./sources/sql-source"), exports);
114
+ __exportStar(require("./sources/table-source"), exports);
115
+ __exportStar(require("./sql-elements/sql-statement"), exports);
116
+ __exportStar(require("./sql-elements/sql-string"), exports);
117
+ __exportStar(require("./types/comparison"), exports);
118
+ __exportStar(require("./types/explore-desc"), exports);
119
+ __exportStar(require("./types/source-property"), exports);
120
+ __exportStar(require("./types/expression-def"), exports);
121
+ __exportStar(require("./types/field-collection-member"), exports);
122
+ __exportStar(require("./types/field-space"), exports);
123
+ __exportStar(require("./types/malloy-element"), exports);
124
+ __exportStar(require("./types/nested-query"), exports);
125
+ __exportStar(require("./types/query-element"), exports);
126
+ __exportStar(require("./types/query-item"), exports);
127
+ __exportStar(require("./types/query-property"), exports);
128
+ __exportStar(require("./types/turtle-headed-pipe"), exports);
129
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,8 @@
1
+ import { Parameter } from "../../../model/malloy_types";
2
+ import { ConstantSubExpression } from "../expressions/constant-sub-expression";
3
+ import { HasParameter } from "./has-parameter";
4
+ export declare class ConstantParameter extends HasParameter {
5
+ readonly value: ConstantSubExpression;
6
+ constructor(name: string, value: ConstantSubExpression);
7
+ parameter(): Parameter;
8
+ }