@osdk/generator 2.0.0-beta.13 → 2.0.0-beta.14

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 (293) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/build/browser/GenerateContext/EnhanceCommon.d.ts +9 -0
  3. package/build/browser/GenerateContext/EnhanceCommon.d.ts.map +1 -0
  4. package/build/browser/GenerateContext/EnhanceCommon.js +17 -0
  5. package/build/browser/GenerateContext/EnhanceCommon.js.map +1 -0
  6. package/build/browser/GenerateContext/EnhancedAction.d.ts +14 -0
  7. package/build/browser/GenerateContext/EnhancedAction.d.ts.map +1 -0
  8. package/build/browser/GenerateContext/EnhancedAction.js +42 -0
  9. package/build/browser/GenerateContext/EnhancedAction.js.map +1 -0
  10. package/build/browser/GenerateContext/EnhancedBase.d.ts +23 -0
  11. package/build/browser/GenerateContext/EnhancedBase.d.ts.map +1 -0
  12. package/build/browser/GenerateContext/EnhancedBase.js +72 -0
  13. package/build/browser/GenerateContext/EnhancedBase.js.map +1 -0
  14. package/build/browser/GenerateContext/EnhancedInterfaceType.d.ts +13 -0
  15. package/build/browser/GenerateContext/EnhancedInterfaceType.d.ts.map +1 -0
  16. package/build/browser/GenerateContext/EnhancedInterfaceType.js +38 -0
  17. package/build/browser/GenerateContext/EnhancedInterfaceType.js.map +1 -0
  18. package/build/browser/GenerateContext/EnhancedObjectType.d.ts +12 -0
  19. package/build/browser/GenerateContext/EnhancedObjectType.d.ts.map +1 -0
  20. package/build/browser/GenerateContext/EnhancedObjectType.js +35 -0
  21. package/build/browser/GenerateContext/EnhancedObjectType.js.map +1 -0
  22. package/build/browser/GenerateContext/EnhancedOntologyDefinition.d.ts +27 -0
  23. package/build/browser/GenerateContext/EnhancedOntologyDefinition.d.ts.map +1 -0
  24. package/build/browser/GenerateContext/EnhancedOntologyDefinition.js +77 -0
  25. package/build/browser/GenerateContext/EnhancedOntologyDefinition.js.map +1 -0
  26. package/build/browser/GenerateContext/EnhancedQuery.d.ts +14 -0
  27. package/build/browser/GenerateContext/EnhancedQuery.d.ts.map +1 -0
  28. package/build/browser/GenerateContext/EnhancedQuery.js +42 -0
  29. package/build/browser/GenerateContext/EnhancedQuery.js.map +1 -0
  30. package/build/browser/GenerateContext/EnhancedSharedPropertyType.d.ts +8 -0
  31. package/build/browser/GenerateContext/EnhancedSharedPropertyType.d.ts.map +1 -0
  32. package/build/browser/GenerateContext/EnhancedSharedPropertyType.js +24 -0
  33. package/build/browser/GenerateContext/EnhancedSharedPropertyType.js.map +1 -0
  34. package/build/browser/GenerateContext/ForeignType.d.ts +10 -0
  35. package/build/browser/GenerateContext/ForeignType.d.ts.map +1 -0
  36. package/build/browser/GenerateContext/ForeignType.js +36 -0
  37. package/build/browser/GenerateContext/ForeignType.js.map +1 -0
  38. package/build/browser/GenerateContext/GenerateContext.d.ts +13 -0
  39. package/build/browser/GenerateContext/GenerateContext.d.ts.map +1 -0
  40. package/build/browser/GenerateContext/GenerateContext.js +17 -0
  41. package/build/browser/GenerateContext/GenerateContext.js.map +1 -0
  42. package/build/browser/GenerateContext/enhanceOntology.d.ts +4 -0
  43. package/build/browser/GenerateContext/enhanceOntology.d.ts.map +1 -0
  44. package/build/browser/GenerateContext/enhanceOntology.js +20 -0
  45. package/build/browser/GenerateContext/enhanceOntology.js.map +1 -0
  46. package/build/browser/MinimalFs.d.ts +10 -0
  47. package/build/browser/MinimalFs.d.ts.map +1 -0
  48. package/build/browser/MinimalFs.js +17 -0
  49. package/build/browser/MinimalFs.js.map +1 -0
  50. package/build/browser/WireOntologyDefinition.d.ts +4 -0
  51. package/build/browser/WireOntologyDefinition.d.ts.map +1 -0
  52. package/build/browser/WireOntologyDefinition.js +17 -0
  53. package/build/browser/WireOntologyDefinition.js.map +1 -0
  54. package/build/browser/generateClientSdkPackage.d.ts +47 -0
  55. package/build/browser/generateClientSdkPackage.d.ts.map +1 -0
  56. package/build/browser/generateClientSdkPackage.js +126 -0
  57. package/build/browser/generateClientSdkPackage.js.map +1 -0
  58. package/build/browser/generateClientSdkPackage.test.d.ts +2 -0
  59. package/build/browser/generateClientSdkPackage.test.d.ts.map +1 -0
  60. package/build/browser/generateClientSdkPackage.test.js +67 -0
  61. package/build/browser/generateClientSdkPackage.test.js.map +1 -0
  62. package/build/browser/index.d.ts +5 -0
  63. package/build/browser/index.d.ts.map +1 -0
  64. package/build/browser/index.js +17 -1286
  65. package/build/browser/index.js.map +1 -1
  66. package/build/browser/shared/apiNamespaces/startsWithApiNamespace.d.ts +2 -0
  67. package/build/browser/shared/apiNamespaces/startsWithApiNamespace.d.ts.map +1 -0
  68. package/build/browser/shared/apiNamespaces/startsWithApiNamespace.js +23 -0
  69. package/build/browser/shared/apiNamespaces/startsWithApiNamespace.js.map +1 -0
  70. package/build/browser/shared/apiNamespaces/startsWithApiNamespace.test.d.ts +2 -0
  71. package/build/browser/shared/apiNamespaces/startsWithApiNamespace.test.d.ts.map +1 -0
  72. package/build/browser/shared/apiNamespaces/startsWithApiNamespace.test.js +46 -0
  73. package/build/browser/shared/apiNamespaces/startsWithApiNamespace.test.js.map +1 -0
  74. package/build/browser/shared/getObjectImports.d.ts +4 -0
  75. package/build/browser/shared/getObjectImports.d.ts.map +1 -0
  76. package/build/browser/shared/getObjectImports.js +24 -0
  77. package/build/browser/shared/getObjectImports.js.map +1 -0
  78. package/build/browser/shared/getObjectTypeApiNamesFromQuery.d.ts +4 -0
  79. package/build/browser/shared/getObjectTypeApiNamesFromQuery.d.ts.map +1 -0
  80. package/build/browser/shared/getObjectTypeApiNamesFromQuery.js +27 -0
  81. package/build/browser/shared/getObjectTypeApiNamesFromQuery.js.map +1 -0
  82. package/build/browser/shared/getObjectTypesFromQueryDataType.d.ts +3 -0
  83. package/build/browser/shared/getObjectTypesFromQueryDataType.d.ts.map +1 -0
  84. package/build/browser/shared/getObjectTypesFromQueryDataType.js +57 -0
  85. package/build/browser/shared/getObjectTypesFromQueryDataType.js.map +1 -0
  86. package/build/browser/shared/propertyJsdoc.d.ts +6 -0
  87. package/build/browser/shared/propertyJsdoc.d.ts.map +1 -0
  88. package/build/browser/shared/propertyJsdoc.js +38 -0
  89. package/build/browser/shared/propertyJsdoc.js.map +1 -0
  90. package/build/browser/shared/sanitizeMetadata.d.ts +2 -0
  91. package/build/browser/shared/sanitizeMetadata.d.ts.map +1 -0
  92. package/build/browser/shared/sanitizeMetadata.js +33 -0
  93. package/build/browser/shared/sanitizeMetadata.js.map +1 -0
  94. package/build/browser/shared/sanitizeMetadata.test.d.ts +2 -0
  95. package/build/browser/shared/sanitizeMetadata.test.d.ts.map +1 -0
  96. package/build/browser/shared/sanitizeMetadata.test.js +44 -0
  97. package/build/browser/shared/sanitizeMetadata.test.js.map +1 -0
  98. package/build/browser/util/InMemoryFs.d.ts +7 -0
  99. package/build/browser/util/InMemoryFs.d.ts.map +1 -0
  100. package/build/browser/util/InMemoryFs.js +30 -0
  101. package/build/browser/util/InMemoryFs.js.map +1 -0
  102. package/build/browser/util/commaSeparatedIdentifiers.d.ts +2 -0
  103. package/build/browser/util/commaSeparatedIdentifiers.d.ts.map +1 -0
  104. package/build/browser/util/commaSeparatedIdentifiers.js +25 -0
  105. package/build/browser/util/commaSeparatedIdentifiers.js.map +1 -0
  106. package/build/browser/util/commaSeparatedTypeIdentifiers.d.ts +2 -0
  107. package/build/browser/util/commaSeparatedTypeIdentifiers.d.ts.map +1 -0
  108. package/build/browser/util/commaSeparatedTypeIdentifiers.js +19 -0
  109. package/build/browser/util/commaSeparatedTypeIdentifiers.js.map +1 -0
  110. package/build/browser/util/deleteUndefineds.d.ts +2 -0
  111. package/build/browser/util/deleteUndefineds.d.ts.map +1 -0
  112. package/build/browser/util/deleteUndefineds.js +19 -0
  113. package/build/browser/util/deleteUndefineds.js.map +1 -0
  114. package/build/browser/util/reservedKeywords.d.ts +2 -0
  115. package/build/browser/util/reservedKeywords.d.ts.map +1 -0
  116. package/build/browser/util/reservedKeywords.js +21 -0
  117. package/build/browser/util/reservedKeywords.js.map +1 -0
  118. package/build/browser/util/stringUnionFrom.d.ts +2 -0
  119. package/build/browser/util/stringUnionFrom.d.ts.map +1 -0
  120. package/build/browser/util/stringUnionFrom.js +23 -0
  121. package/build/browser/util/stringUnionFrom.js.map +1 -0
  122. package/build/browser/util/stringify.d.ts +20 -0
  123. package/build/browser/util/stringify.d.ts.map +1 -0
  124. package/build/browser/util/stringify.js +36 -0
  125. package/build/browser/util/stringify.js.map +1 -0
  126. package/build/browser/util/test/TodoWireOntology.d.ts +217 -0
  127. package/build/browser/util/test/TodoWireOntology.d.ts.map +1 -0
  128. package/build/browser/util/test/TodoWireOntology.js +232 -0
  129. package/build/browser/util/test/TodoWireOntology.js.map +1 -0
  130. package/build/browser/util/test/compileThis.d.ts +3 -0
  131. package/build/browser/util/test/compileThis.d.ts.map +1 -0
  132. package/build/browser/util/test/compileThis.js +41 -0
  133. package/build/browser/util/test/compileThis.js.map +1 -0
  134. package/build/browser/util/test/createMockMinimalFiles.d.ts +13 -0
  135. package/build/browser/util/test/createMockMinimalFiles.d.ts.map +1 -0
  136. package/build/browser/util/test/createMockMinimalFiles.js +37 -0
  137. package/build/browser/util/test/createMockMinimalFiles.js.map +1 -0
  138. package/build/browser/util/test/formatTs.d.ts +2 -0
  139. package/build/browser/util/test/formatTs.d.ts.map +1 -0
  140. package/build/browser/util/test/formatTs.js +32 -0
  141. package/build/browser/util/test/formatTs.js.map +1 -0
  142. package/build/browser/util/verifyOutDir.d.ts +9 -0
  143. package/build/browser/util/verifyOutDir.d.ts.map +1 -0
  144. package/build/browser/util/verifyOutDir.js +35 -0
  145. package/build/browser/util/verifyOutDir.js.map +1 -0
  146. package/build/browser/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.d.ts +2 -0
  147. package/build/browser/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.d.ts.map +1 -0
  148. package/build/browser/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.js +114 -0
  149. package/build/browser/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.js.map +1 -0
  150. package/build/browser/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.test.d.ts +2 -0
  151. package/build/browser/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.test.d.ts.map +1 -0
  152. package/build/browser/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.test.js +273 -0
  153. package/build/browser/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.test.js.map +1 -0
  154. package/build/browser/v2.0/generateClientSdkVersionTwoPointZero.d.ts +4 -0
  155. package/build/browser/v2.0/generateClientSdkVersionTwoPointZero.d.ts.map +1 -0
  156. package/build/browser/v2.0/generateClientSdkVersionTwoPointZero.js +119 -0
  157. package/build/browser/v2.0/generateClientSdkVersionTwoPointZero.js.map +1 -0
  158. package/build/browser/v2.0/generateClientSdkVersionTwoPointZero.test.d.ts +2 -0
  159. package/build/browser/v2.0/generateClientSdkVersionTwoPointZero.test.d.ts.map +1 -0
  160. package/build/browser/v2.0/generateClientSdkVersionTwoPointZero.test.js +1949 -0
  161. package/build/browser/v2.0/generateClientSdkVersionTwoPointZero.test.js.map +1 -0
  162. package/build/browser/v2.0/generateMetadata.d.ts +3 -0
  163. package/build/browser/v2.0/generateMetadata.d.ts.map +1 -0
  164. package/build/browser/v2.0/generateMetadata.js +35 -0
  165. package/build/browser/v2.0/generateMetadata.js.map +1 -0
  166. package/build/browser/v2.0/generatePerActionDataFiles.d.ts +3 -0
  167. package/build/browser/v2.0/generatePerActionDataFiles.d.ts.map +1 -0
  168. package/build/browser/v2.0/generatePerActionDataFiles.js +240 -0
  169. package/build/browser/v2.0/generatePerActionDataFiles.js.map +1 -0
  170. package/build/browser/v2.0/generatePerActionDataFiles.test.d.ts +2 -0
  171. package/build/browser/v2.0/generatePerActionDataFiles.test.d.ts.map +1 -0
  172. package/build/browser/v2.0/generatePerActionDataFiles.test.js +51 -0
  173. package/build/browser/v2.0/generatePerActionDataFiles.test.js.map +1 -0
  174. package/build/browser/v2.0/generatePerQueryDataFiles.d.ts +9 -0
  175. package/build/browser/v2.0/generatePerQueryDataFiles.d.ts.map +1 -0
  176. package/build/browser/v2.0/generatePerQueryDataFiles.js +194 -0
  177. package/build/browser/v2.0/generatePerQueryDataFiles.js.map +1 -0
  178. package/build/browser/v2.0/generatePerQueryDataFiles.test.d.ts +2 -0
  179. package/build/browser/v2.0/generatePerQueryDataFiles.test.d.ts.map +1 -0
  180. package/build/browser/v2.0/generatePerQueryDataFiles.test.js +199 -0
  181. package/build/browser/v2.0/generatePerQueryDataFiles.test.js.map +1 -0
  182. package/build/browser/v2.0/getDescriptionIfPresent.d.ts +2 -0
  183. package/build/browser/v2.0/getDescriptionIfPresent.d.ts.map +1 -0
  184. package/build/browser/v2.0/getDescriptionIfPresent.js +24 -0
  185. package/build/browser/v2.0/getDescriptionIfPresent.js.map +1 -0
  186. package/build/browser/v2.0/wireObjectTypeV2ToSdkObjectConstV2.d.ts +13 -0
  187. package/build/browser/v2.0/wireObjectTypeV2ToSdkObjectConstV2.d.ts.map +1 -0
  188. package/build/browser/v2.0/wireObjectTypeV2ToSdkObjectConstV2.js +205 -0
  189. package/build/browser/v2.0/wireObjectTypeV2ToSdkObjectConstV2.js.map +1 -0
  190. package/build/browser/validateWireOntologyAssumptions.d.ts +3 -0
  191. package/build/browser/validateWireOntologyAssumptions.d.ts.map +1 -0
  192. package/build/browser/validateWireOntologyAssumptions.js +33 -0
  193. package/build/browser/validateWireOntologyAssumptions.js.map +1 -0
  194. package/build/esm/GenerateContext/EnhanceCommon.js +17 -0
  195. package/build/esm/GenerateContext/EnhanceCommon.js.map +1 -0
  196. package/build/esm/GenerateContext/EnhancedAction.js +42 -0
  197. package/build/esm/GenerateContext/EnhancedAction.js.map +1 -0
  198. package/build/esm/GenerateContext/EnhancedBase.js +72 -0
  199. package/build/esm/GenerateContext/EnhancedBase.js.map +1 -0
  200. package/build/esm/GenerateContext/EnhancedInterfaceType.js +38 -0
  201. package/build/esm/GenerateContext/EnhancedInterfaceType.js.map +1 -0
  202. package/build/esm/GenerateContext/EnhancedObjectType.js +35 -0
  203. package/build/esm/GenerateContext/EnhancedObjectType.js.map +1 -0
  204. package/build/esm/GenerateContext/EnhancedOntologyDefinition.js +77 -0
  205. package/build/esm/GenerateContext/EnhancedOntologyDefinition.js.map +1 -0
  206. package/build/esm/GenerateContext/EnhancedQuery.js +42 -0
  207. package/build/esm/GenerateContext/EnhancedQuery.js.map +1 -0
  208. package/build/esm/GenerateContext/EnhancedSharedPropertyType.js +24 -0
  209. package/build/esm/GenerateContext/EnhancedSharedPropertyType.js.map +1 -0
  210. package/build/esm/GenerateContext/ForeignType.js +36 -0
  211. package/build/esm/GenerateContext/ForeignType.js.map +1 -0
  212. package/build/esm/GenerateContext/GenerateContext.js +17 -0
  213. package/build/esm/GenerateContext/GenerateContext.js.map +1 -0
  214. package/build/esm/GenerateContext/enhanceOntology.js +20 -0
  215. package/build/esm/GenerateContext/enhanceOntology.js.map +1 -0
  216. package/build/esm/MinimalFs.js +17 -0
  217. package/build/esm/MinimalFs.js.map +1 -0
  218. package/build/esm/WireOntologyDefinition.js +17 -0
  219. package/build/esm/WireOntologyDefinition.js.map +1 -0
  220. package/build/esm/generateClientSdkPackage.d.ts +1 -6
  221. package/build/esm/generateClientSdkPackage.d.ts.map +1 -1
  222. package/build/esm/generateClientSdkPackage.js +126 -0
  223. package/build/esm/generateClientSdkPackage.js.map +1 -0
  224. package/build/esm/generateClientSdkPackage.test.js +67 -0
  225. package/build/esm/generateClientSdkPackage.test.js.map +1 -0
  226. package/build/esm/index.js +17 -1286
  227. package/build/esm/index.js.map +1 -1
  228. package/build/esm/shared/apiNamespaces/startsWithApiNamespace.js +23 -0
  229. package/build/esm/shared/apiNamespaces/startsWithApiNamespace.js.map +1 -0
  230. package/build/esm/shared/apiNamespaces/startsWithApiNamespace.test.js +46 -0
  231. package/build/esm/shared/apiNamespaces/startsWithApiNamespace.test.js.map +1 -0
  232. package/build/esm/shared/getObjectImports.js +24 -0
  233. package/build/esm/shared/getObjectImports.js.map +1 -0
  234. package/build/esm/shared/getObjectTypeApiNamesFromQuery.js +27 -0
  235. package/build/esm/shared/getObjectTypeApiNamesFromQuery.js.map +1 -0
  236. package/build/esm/shared/getObjectTypesFromQueryDataType.js +57 -0
  237. package/build/esm/shared/getObjectTypesFromQueryDataType.js.map +1 -0
  238. package/build/esm/shared/propertyJsdoc.js +38 -0
  239. package/build/esm/shared/propertyJsdoc.js.map +1 -0
  240. package/build/esm/shared/sanitizeMetadata.js +33 -0
  241. package/build/esm/shared/sanitizeMetadata.js.map +1 -0
  242. package/build/esm/shared/sanitizeMetadata.test.js +44 -0
  243. package/build/esm/shared/sanitizeMetadata.test.js.map +1 -0
  244. package/build/esm/util/InMemoryFs.js +30 -0
  245. package/build/esm/util/InMemoryFs.js.map +1 -0
  246. package/build/esm/util/commaSeparatedIdentifiers.js +25 -0
  247. package/build/esm/util/commaSeparatedIdentifiers.js.map +1 -0
  248. package/build/esm/util/commaSeparatedTypeIdentifiers.js +19 -0
  249. package/build/esm/util/commaSeparatedTypeIdentifiers.js.map +1 -0
  250. package/build/esm/util/deleteUndefineds.js +19 -0
  251. package/build/esm/util/deleteUndefineds.js.map +1 -0
  252. package/build/esm/util/reservedKeywords.js +21 -0
  253. package/build/esm/util/reservedKeywords.js.map +1 -0
  254. package/build/esm/util/stringUnionFrom.js +23 -0
  255. package/build/esm/util/stringUnionFrom.js.map +1 -0
  256. package/build/esm/util/stringify.js +36 -0
  257. package/build/esm/util/stringify.js.map +1 -0
  258. package/build/esm/util/test/TodoWireOntology.js +232 -0
  259. package/build/esm/util/test/TodoWireOntology.js.map +1 -0
  260. package/build/esm/util/test/compileThis.js +41 -0
  261. package/build/esm/util/test/compileThis.js.map +1 -0
  262. package/build/esm/util/test/createMockMinimalFiles.js +37 -0
  263. package/build/esm/util/test/createMockMinimalFiles.js.map +1 -0
  264. package/build/esm/util/test/formatTs.js +32 -0
  265. package/build/esm/util/test/formatTs.js.map +1 -0
  266. package/build/esm/util/verifyOutDir.js +35 -0
  267. package/build/esm/util/verifyOutDir.js.map +1 -0
  268. package/build/esm/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.js +114 -0
  269. package/build/esm/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.js.map +1 -0
  270. package/build/esm/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.test.js +273 -0
  271. package/build/esm/v2.0/UNSTABLE_wireInterfaceTypeV2ToSdkObjectConst.test.js.map +1 -0
  272. package/build/esm/v2.0/generateClientSdkVersionTwoPointZero.js +119 -0
  273. package/build/esm/v2.0/generateClientSdkVersionTwoPointZero.js.map +1 -0
  274. package/build/esm/v2.0/generateClientSdkVersionTwoPointZero.test.js +1949 -0
  275. package/build/esm/v2.0/generateClientSdkVersionTwoPointZero.test.js.map +1 -0
  276. package/build/esm/v2.0/generateMetadata.js +35 -0
  277. package/build/esm/v2.0/generateMetadata.js.map +1 -0
  278. package/build/esm/v2.0/generatePerActionDataFiles.d.ts.map +1 -1
  279. package/build/esm/v2.0/generatePerActionDataFiles.js +240 -0
  280. package/build/esm/v2.0/generatePerActionDataFiles.js.map +1 -0
  281. package/build/esm/v2.0/generatePerActionDataFiles.test.js +51 -0
  282. package/build/esm/v2.0/generatePerActionDataFiles.test.js.map +1 -0
  283. package/build/esm/v2.0/generatePerQueryDataFiles.js +194 -0
  284. package/build/esm/v2.0/generatePerQueryDataFiles.js.map +1 -0
  285. package/build/esm/v2.0/generatePerQueryDataFiles.test.js +199 -0
  286. package/build/esm/v2.0/generatePerQueryDataFiles.test.js.map +1 -0
  287. package/build/esm/v2.0/getDescriptionIfPresent.js +24 -0
  288. package/build/esm/v2.0/getDescriptionIfPresent.js.map +1 -0
  289. package/build/esm/v2.0/wireObjectTypeV2ToSdkObjectConstV2.js +205 -0
  290. package/build/esm/v2.0/wireObjectTypeV2ToSdkObjectConstV2.js.map +1 -0
  291. package/build/esm/validateWireOntologyAssumptions.js +33 -0
  292. package/build/esm/validateWireOntologyAssumptions.js.map +1 -0
  293. package/package.json +6 -8
@@ -0,0 +1,38 @@
1
+ /*
2
+ * Copyright 2024 Palantir Technologies, Inc. All rights reserved.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ export function propertyJsdoc(property, {
17
+ isInherited,
18
+ apiName
19
+ }) {
20
+ let ret = `/**\n`;
21
+ const renderDisplayName = property.displayName && property.displayName !== apiName;
22
+ if (isInherited || renderDisplayName || property.description) {
23
+ if (isInherited) {
24
+ ret += ` * (inherited from parent)\n`;
25
+ }
26
+ if (renderDisplayName) {
27
+ ret += ` * display name: '${property.displayName}'${property.description ? "," : ""}\n`;
28
+ }
29
+ if (property.description) {
30
+ ret += ` * description: ${property.description}\n`;
31
+ }
32
+ } else {
33
+ ret += ` * (no ontology metadata)\n`;
34
+ }
35
+ ret += ` */\n`;
36
+ return ret;
37
+ }
38
+ //# sourceMappingURL=propertyJsdoc.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"propertyJsdoc.js","names":["propertyJsdoc","property","isInherited","apiName","ret","renderDisplayName","displayName","description"],"sources":["propertyJsdoc.js"],"sourcesContent":["/*\n * Copyright 2024 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nexport function propertyJsdoc(property, { isInherited, apiName }) {\n let ret = `/**\\n`;\n const renderDisplayName = property.displayName\n && property.displayName !== apiName;\n if (isInherited || renderDisplayName || property.description) {\n if (isInherited) {\n ret += ` * (inherited from parent)\\n`;\n }\n if (renderDisplayName) {\n ret += ` * display name: '${property.displayName}'${property.description ? \",\" : \"\"}\\n`;\n }\n if (property.description) {\n ret += ` * description: ${property.description}\\n`;\n }\n }\n else {\n ret += ` * (no ontology metadata)\\n`;\n }\n ret += ` */\\n`;\n return ret;\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,aAAaA,CAACC,QAAQ,EAAE;EAAEC,WAAW;EAAEC;AAAQ,CAAC,EAAE;EAC9D,IAAIC,GAAG,GAAG,OAAO;EACjB,MAAMC,iBAAiB,GAAGJ,QAAQ,CAACK,WAAW,IACvCL,QAAQ,CAACK,WAAW,KAAKH,OAAO;EACvC,IAAID,WAAW,IAAIG,iBAAiB,IAAIJ,QAAQ,CAACM,WAAW,EAAE;IAC1D,IAAIL,WAAW,EAAE;MACbE,GAAG,IAAI,8BAA8B;IACzC;IACA,IAAIC,iBAAiB,EAAE;MACnBD,GAAG,IAAI,uBAAuBH,QAAQ,CAACK,WAAW,IAAIL,QAAQ,CAACM,WAAW,GAAG,GAAG,GAAG,EAAE,IAAI;IAC7F;IACA,IAAIN,QAAQ,CAACM,WAAW,EAAE;MACtBH,GAAG,IAAI,qBAAqBH,QAAQ,CAACM,WAAW,IAAI;IACxD;EACJ,CAAC,MACI;IACDH,GAAG,IAAI,6BAA6B;EACxC;EACAA,GAAG,IAAI,OAAO;EACd,OAAOA,GAAG;AACd","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=sanitizeMetadata.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sanitizeMetadata.d.ts","sourceRoot":"","sources":["../../../src/shared/sanitizeMetadata.ts"],"names":[],"mappings":""}
@@ -0,0 +1,33 @@
1
+ /*
2
+ * Copyright 2023 Palantir Technologies, Inc. All rights reserved.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ /**
17
+ * @internal
18
+ */
19
+ export function sanitizeMetadata(ontology) {
20
+ return {
21
+ ...ontology,
22
+ actionTypes: Object.fromEntries(Object.values(ontology.actionTypes).map(actionType => {
23
+ return [camelize(actionType.apiName), {
24
+ ...actionType,
25
+ apiName: camelize(actionType.apiName)
26
+ }];
27
+ }))
28
+ };
29
+ }
30
+ function camelize(name) {
31
+ return name.replace(/-./g, segment => segment[1].toUpperCase());
32
+ }
33
+ //# sourceMappingURL=sanitizeMetadata.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sanitizeMetadata.js","names":["sanitizeMetadata","ontology","actionTypes","Object","fromEntries","values","map","actionType","camelize","apiName","name","replace","segment","toUpperCase"],"sources":["sanitizeMetadata.js"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n/**\n * @internal\n */\nexport function sanitizeMetadata(ontology) {\n return {\n ...ontology,\n actionTypes: Object.fromEntries(Object.values(ontology.actionTypes).map(actionType => {\n return [camelize(actionType.apiName), {\n ...actionType,\n apiName: camelize(actionType.apiName),\n }];\n })),\n };\n}\nfunction camelize(name) {\n return name.replace(/-./g, segment => segment[1].toUpperCase());\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,gBAAgBA,CAACC,QAAQ,EAAE;EACvC,OAAO;IACH,GAAGA,QAAQ;IACXC,WAAW,EAAEC,MAAM,CAACC,WAAW,CAACD,MAAM,CAACE,MAAM,CAACJ,QAAQ,CAACC,WAAW,CAAC,CAACI,GAAG,CAACC,UAAU,IAAI;MAClF,OAAO,CAACC,QAAQ,CAACD,UAAU,CAACE,OAAO,CAAC,EAAE;QAC9B,GAAGF,UAAU;QACbE,OAAO,EAAED,QAAQ,CAACD,UAAU,CAACE,OAAO;MACxC,CAAC,CAAC;IACV,CAAC,CAAC;EACN,CAAC;AACL;AACA,SAASD,QAAQA,CAACE,IAAI,EAAE;EACpB,OAAOA,IAAI,CAACC,OAAO,CAAC,KAAK,EAAEC,OAAO,IAAIA,OAAO,CAAC,CAAC,CAAC,CAACC,WAAW,CAAC,CAAC,CAAC;AACnE","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=sanitizeMetadata.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sanitizeMetadata.test.d.ts","sourceRoot":"","sources":["../../../src/shared/sanitizeMetadata.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,44 @@
1
+ /*
2
+ * Copyright 2023 Palantir Technologies, Inc. All rights reserved.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { describe, expect, it } from "vitest";
17
+ import { sanitizeMetadata } from "./sanitizeMetadata.js";
18
+ describe(sanitizeMetadata, () => {
19
+ it("sanitized action apiNames", () => {
20
+ const sanitizedOntology = sanitizeMetadata({
21
+ objectTypes: {},
22
+ actionTypes: {
23
+ "kebab-case": {
24
+ apiName: "kebab-case",
25
+ operations: [],
26
+ parameters: {},
27
+ status: "ACTIVE",
28
+ rid: "ri.a.b.c.d"
29
+ }
30
+ },
31
+ ontology: {
32
+ rid: "ri.a.b.c.d",
33
+ apiName: "ontology",
34
+ displayName: "",
35
+ description: ""
36
+ },
37
+ queryTypes: {},
38
+ interfaceTypes: {},
39
+ sharedPropertyTypes: {}
40
+ });
41
+ expect(sanitizedOntology.actionTypes["kebabCase"].apiName).toEqual("kebabCase");
42
+ });
43
+ });
44
+ //# sourceMappingURL=sanitizeMetadata.test.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sanitizeMetadata.test.js","names":["describe","expect","it","sanitizeMetadata","sanitizedOntology","objectTypes","actionTypes","apiName","operations","parameters","status","rid","ontology","displayName","description","queryTypes","interfaceTypes","sharedPropertyTypes","toEqual"],"sources":["sanitizeMetadata.test.js"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { describe, expect, it } from \"vitest\";\nimport { sanitizeMetadata } from \"./sanitizeMetadata.js\";\ndescribe(sanitizeMetadata, () => {\n it(\"sanitized action apiNames\", () => {\n const sanitizedOntology = sanitizeMetadata({\n objectTypes: {},\n actionTypes: {\n \"kebab-case\": {\n apiName: \"kebab-case\",\n operations: [],\n parameters: {},\n status: \"ACTIVE\",\n rid: \"ri.a.b.c.d\",\n },\n },\n ontology: {\n rid: \"ri.a.b.c.d\",\n apiName: \"ontology\",\n displayName: \"\",\n description: \"\",\n },\n queryTypes: {},\n interfaceTypes: {},\n sharedPropertyTypes: {},\n });\n expect(sanitizedOntology.actionTypes[\"kebabCase\"].apiName).toEqual(\"kebabCase\");\n });\n});\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,QAAQ,EAAEC,MAAM,EAAEC,EAAE,QAAQ,QAAQ;AAC7C,SAASC,gBAAgB,QAAQ,uBAAuB;AACxDH,QAAQ,CAACG,gBAAgB,EAAE,MAAM;EAC7BD,EAAE,CAAC,2BAA2B,EAAE,MAAM;IAClC,MAAME,iBAAiB,GAAGD,gBAAgB,CAAC;MACvCE,WAAW,EAAE,CAAC,CAAC;MACfC,WAAW,EAAE;QACT,YAAY,EAAE;UACVC,OAAO,EAAE,YAAY;UACrBC,UAAU,EAAE,EAAE;UACdC,UAAU,EAAE,CAAC,CAAC;UACdC,MAAM,EAAE,QAAQ;UAChBC,GAAG,EAAE;QACT;MACJ,CAAC;MACDC,QAAQ,EAAE;QACND,GAAG,EAAE,YAAY;QACjBJ,OAAO,EAAE,UAAU;QACnBM,WAAW,EAAE,EAAE;QACfC,WAAW,EAAE;MACjB,CAAC;MACDC,UAAU,EAAE,CAAC,CAAC;MACdC,cAAc,EAAE,CAAC,CAAC;MAClBC,mBAAmB,EAAE,CAAC;IAC1B,CAAC,CAAC;IACFhB,MAAM,CAACG,iBAAiB,CAACE,WAAW,CAAC,WAAW,CAAC,CAACC,OAAO,CAAC,CAACW,OAAO,CAAC,WAAW,CAAC;EACnF,CAAC,CAAC;AACN,CAAC,CAAC","ignoreList":[]}
@@ -0,0 +1,7 @@
1
+ import { type MinimalFs } from "../MinimalFs.js";
2
+ export interface InMemoryFs extends MinimalFs {
3
+ getFiles(): Record<string, string>;
4
+ getFile(path: string): string;
5
+ }
6
+ export declare function createInMemoryFs(): InMemoryFs;
7
+ //# sourceMappingURL=InMemoryFs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InMemoryFs.d.ts","sourceRoot":"","sources":["../../../src/util/InMemoryFs.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,MAAM,WAAW,UAAW,SAAQ,SAAS;IAC3C,QAAQ,IAAI,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACnC,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAAC;CAC/B;AAED,wBAAgB,gBAAgB,IAAI,UAAU,CAc7C"}
@@ -0,0 +1,30 @@
1
+ /*
2
+ * Copyright 2023 Palantir Technologies, Inc. All rights reserved.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ export function createInMemoryFs() {
17
+ const files = {};
18
+ return {
19
+ writeFile: async (path, contents) => {
20
+ files[path] = contents;
21
+ },
22
+ mkdir: async () => {},
23
+ getFiles: () => files,
24
+ getFile: path => files[path],
25
+ readdir: async () => {
26
+ throw new Error("not implemented");
27
+ }
28
+ };
29
+ }
30
+ //# sourceMappingURL=InMemoryFs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InMemoryFs.js","names":["createInMemoryFs","files","writeFile","path","contents","mkdir","getFiles","getFile","readdir","Error"],"sources":["InMemoryFs.js"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nexport function createInMemoryFs() {\n const files = {};\n return {\n writeFile: async (path, contents) => {\n files[path] = contents;\n },\n mkdir: async (path, options) => {\n },\n getFiles: () => files,\n getFile: (path) => files[path],\n readdir: async (path) => {\n throw new Error(\"not implemented\");\n },\n };\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,gBAAgBA,CAAA,EAAG;EAC/B,MAAMC,KAAK,GAAG,CAAC,CAAC;EAChB,OAAO;IACHC,SAAS,EAAE,MAAAA,CAAOC,IAAI,EAAEC,QAAQ,KAAK;MACjCH,KAAK,CAACE,IAAI,CAAC,GAAGC,QAAQ;IAC1B,CAAC;IACDC,KAAK,EAAE,MAAAA,CAAA,KAAyB,CAChC,CAAC;IACDC,QAAQ,EAAEA,CAAA,KAAML,KAAK;IACrBM,OAAO,EAAGJ,IAAI,IAAKF,KAAK,CAACE,IAAI,CAAC;IAC9BK,OAAO,EAAE,MAAAA,CAAA,KAAgB;MACrB,MAAM,IAAIC,KAAK,CAAC,iBAAiB,CAAC;IACtC;EACJ,CAAC;AACL","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export declare function commaSeparatedIdentifiers(identifiers: ReadonlyArray<string>, alternateNames?: ReadonlyMap<string, string>): string;
2
+ //# sourceMappingURL=commaSeparatedIdentifiers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"commaSeparatedIdentifiers.d.ts","sourceRoot":"","sources":["../../../src/util/commaSeparatedIdentifiers.ts"],"names":[],"mappings":"AAgBA,wBAAgB,yBAAyB,CACvC,WAAW,EAAE,aAAa,CAAC,MAAM,CAAC,EAClC,cAAc,CAAC,EAAE,WAAW,CAAC,MAAM,EAAE,MAAM,CAAC,UAS7C"}
@@ -0,0 +1,25 @@
1
+ /*
2
+ * Copyright 2023 Palantir Technologies, Inc. All rights reserved.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ export function commaSeparatedIdentifiers(identifiers, alternateNames) {
17
+ return identifiers.map(i => {
18
+ const alt = alternateNames?.get(i);
19
+ if (alt) {
20
+ return `${i}: ${alt}`;
21
+ }
22
+ return i;
23
+ }).join(",");
24
+ }
25
+ //# sourceMappingURL=commaSeparatedIdentifiers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"commaSeparatedIdentifiers.js","names":["commaSeparatedIdentifiers","identifiers","alternateNames","map","i","alt","get","join"],"sources":["commaSeparatedIdentifiers.js"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nexport function commaSeparatedIdentifiers(identifiers, alternateNames) {\n return identifiers.map(i => {\n const alt = alternateNames?.get(i);\n if (alt) {\n return `${i}: ${alt}`;\n }\n return i;\n }).join(\",\");\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,yBAAyBA,CAACC,WAAW,EAAEC,cAAc,EAAE;EACnE,OAAOD,WAAW,CAACE,GAAG,CAACC,CAAC,IAAI;IACxB,MAAMC,GAAG,GAAGH,cAAc,EAAEI,GAAG,CAACF,CAAC,CAAC;IAClC,IAAIC,GAAG,EAAE;MACL,OAAO,GAAGD,CAAC,KAAKC,GAAG,EAAE;IACzB;IACA,OAAOD,CAAC;EACZ,CAAC,CAAC,CAACG,IAAI,CAAC,GAAG,CAAC;AAChB","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export declare function commaSeparatedTypeIdentifiers(identifiers: ReadonlyArray<string>, altNames?: ReadonlyMap<string, string>): string;
2
+ //# sourceMappingURL=commaSeparatedTypeIdentifiers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"commaSeparatedTypeIdentifiers.d.ts","sourceRoot":"","sources":["../../../src/util/commaSeparatedTypeIdentifiers.ts"],"names":[],"mappings":"AAgBA,wBAAgB,6BAA6B,CAC3C,WAAW,EAAE,aAAa,CAAC,MAAM,CAAC,EAClC,QAAQ,CAAC,EAAE,WAAW,CAAC,MAAM,EAAE,MAAM,CAAC,UAKvC"}
@@ -0,0 +1,19 @@
1
+ /*
2
+ * Copyright 2023 Palantir Technologies, Inc. All rights reserved.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ export function commaSeparatedTypeIdentifiers(identifiers, altNames) {
17
+ return identifiers.map(i => `${i}: typeof ${altNames?.get(i) ?? i}`).join(",");
18
+ }
19
+ //# sourceMappingURL=commaSeparatedTypeIdentifiers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"commaSeparatedTypeIdentifiers.js","names":["commaSeparatedTypeIdentifiers","identifiers","altNames","map","i","get","join"],"sources":["commaSeparatedTypeIdentifiers.js"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nexport function commaSeparatedTypeIdentifiers(identifiers, altNames) {\n return identifiers.map(i => `${i}: typeof ${altNames?.get(i) ?? i}`).join(\",\");\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,6BAA6BA,CAACC,WAAW,EAAEC,QAAQ,EAAE;EACjE,OAAOD,WAAW,CAACE,GAAG,CAACC,CAAC,IAAI,GAAGA,CAAC,YAAYF,QAAQ,EAAEG,GAAG,CAACD,CAAC,CAAC,IAAIA,CAAC,EAAE,CAAC,CAACE,IAAI,CAAC,GAAG,CAAC;AAClF","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export declare function deleteUndefineds<T extends Record<string, any>>(obj: T): T;
2
+ //# sourceMappingURL=deleteUndefineds.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"deleteUndefineds.d.ts","sourceRoot":"","sources":["../../../src/util/deleteUndefineds.ts"],"names":[],"mappings":"AAgBA,wBAAgB,gBAAgB,CAAC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,GAAG,EAAE,CAAC,GAAG,CAAC,CAIzE"}
@@ -0,0 +1,19 @@
1
+ /*
2
+ * Copyright 2023 Palantir Technologies, Inc. All rights reserved.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ export function deleteUndefineds(obj) {
17
+ return Object.fromEntries(Object.entries(obj).filter(([, value]) => value !== undefined));
18
+ }
19
+ //# sourceMappingURL=deleteUndefineds.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"deleteUndefineds.js","names":["deleteUndefineds","obj","Object","fromEntries","entries","filter","value","undefined"],"sources":["deleteUndefineds.js"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nexport function deleteUndefineds(obj) {\n return Object.fromEntries(Object.entries(obj).filter(([, value]) => value !== undefined));\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,gBAAgBA,CAACC,GAAG,EAAE;EAClC,OAAOC,MAAM,CAACC,WAAW,CAACD,MAAM,CAACE,OAAO,CAACH,GAAG,CAAC,CAACI,MAAM,CAAC,CAAC,GAAGC,KAAK,CAAC,KAAKA,KAAK,KAAKC,SAAS,CAAC,CAAC;AAC7F","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export declare function isReservedKeyword(name: string): boolean;
2
+ //# sourceMappingURL=reservedKeywords.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"reservedKeywords.d.ts","sourceRoot":"","sources":["../../../src/util/reservedKeywords.ts"],"names":[],"mappings":"AAiEA,wBAAgB,iBAAiB,CAAC,IAAI,EAAE,MAAM,WAE7C"}
@@ -0,0 +1,21 @@
1
+ /*
2
+ * Copyright 2023 Palantir Technologies, Inc. All rights reserved.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ // This must match the reservedKeywords definition in packages/legacy-client
17
+ const reservedKeywords = new Set(["break", "case", "catch", "class", "const", "continue", "debugger", "default", "delete", "do", "else", "enum", "export", "extends", "false", "finally", "for", "function", "if", "import", "in", "instanceof", "new", "null", "return", "super", "switch", "this", "throw", "true", "try", "typeof", "var", "void", "while", "with", "implements", "interface", "let", "package", "private", "protected", "public", "static", "yield"]);
18
+ export function isReservedKeyword(name) {
19
+ return reservedKeywords.has(name);
20
+ }
21
+ //# sourceMappingURL=reservedKeywords.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"reservedKeywords.js","names":["reservedKeywords","Set","isReservedKeyword","name","has"],"sources":["reservedKeywords.js"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n// This must match the reservedKeywords definition in packages/legacy-client\nconst reservedKeywords = new Set([\n \"break\",\n \"case\",\n \"catch\",\n \"class\",\n \"const\",\n \"continue\",\n \"debugger\",\n \"default\",\n \"delete\",\n \"do\",\n \"else\",\n \"enum\",\n \"export\",\n \"extends\",\n \"false\",\n \"finally\",\n \"for\",\n \"function\",\n \"if\",\n \"import\",\n \"in\",\n \"instanceof\",\n \"new\",\n \"null\",\n \"return\",\n \"super\",\n \"switch\",\n \"this\",\n \"throw\",\n \"true\",\n \"try\",\n \"typeof\",\n \"var\",\n \"void\",\n \"while\",\n \"with\",\n \"implements\",\n \"interface\",\n \"let\",\n \"package\",\n \"private\",\n \"protected\",\n \"public\",\n \"static\",\n \"yield\",\n]);\nexport function isReservedKeyword(name) {\n return reservedKeywords.has(name);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMA,gBAAgB,GAAG,IAAIC,GAAG,CAAC,CAC7B,OAAO,EACP,MAAM,EACN,OAAO,EACP,OAAO,EACP,OAAO,EACP,UAAU,EACV,UAAU,EACV,SAAS,EACT,QAAQ,EACR,IAAI,EACJ,MAAM,EACN,MAAM,EACN,QAAQ,EACR,SAAS,EACT,OAAO,EACP,SAAS,EACT,KAAK,EACL,UAAU,EACV,IAAI,EACJ,QAAQ,EACR,IAAI,EACJ,YAAY,EACZ,KAAK,EACL,MAAM,EACN,QAAQ,EACR,OAAO,EACP,QAAQ,EACR,MAAM,EACN,OAAO,EACP,MAAM,EACN,KAAK,EACL,QAAQ,EACR,KAAK,EACL,MAAM,EACN,OAAO,EACP,MAAM,EACN,YAAY,EACZ,WAAW,EACX,KAAK,EACL,SAAS,EACT,SAAS,EACT,WAAW,EACX,QAAQ,EACR,QAAQ,EACR,OAAO,CACV,CAAC;AACF,OAAO,SAASC,iBAAiBA,CAACC,IAAI,EAAE;EACpC,OAAOH,gBAAgB,CAACI,GAAG,CAACD,IAAI,CAAC;AACrC","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ export declare function stringUnionFrom(values: ReadonlyArray<string>): string;
2
+ //# sourceMappingURL=stringUnionFrom.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"stringUnionFrom.d.ts","sourceRoot":"","sources":["../../../src/util/stringUnionFrom.ts"],"names":[],"mappings":"AAgBA,wBAAgB,eAAe,CAAC,MAAM,EAAE,aAAa,CAAC,MAAM,CAAC,UAM5D"}
@@ -0,0 +1,23 @@
1
+ /*
2
+ * Copyright 2024 Palantir Technologies, Inc. All rights reserved.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ export function stringUnionFrom(values) {
17
+ if (values.length === 0) {
18
+ return "never";
19
+ } else {
20
+ return values.map(v => `"${v}"`).join("|");
21
+ }
22
+ }
23
+ //# sourceMappingURL=stringUnionFrom.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"stringUnionFrom.js","names":["stringUnionFrom","values","length","map","v","join"],"sources":["stringUnionFrom.js"],"sourcesContent":["/*\n * Copyright 2024 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nexport function stringUnionFrom(values) {\n if (values.length === 0) {\n return \"never\";\n }\n else {\n return values.map(v => `\"${v}\"`).join(\"|\");\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,eAAeA,CAACC,MAAM,EAAE;EACpC,IAAIA,MAAM,CAACC,MAAM,KAAK,CAAC,EAAE;IACrB,OAAO,OAAO;EAClB,CAAC,MACI;IACD,OAAOD,MAAM,CAACE,GAAG,CAACC,CAAC,IAAI,IAAIA,CAAC,GAAG,CAAC,CAACC,IAAI,CAAC,GAAG,CAAC;EAC9C;AACJ","ignoreList":[]}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * A function for changing the stringified key/value pairs of an object.
3
+ *
4
+ * @param value The value of the key/value pair.
5
+ * @param defaultValueFormatter The function that would be called if this customizer wasn't used
6
+ * @param key The key of the key/value pair.
7
+ * @param defaultKeyFormatter The function that would be called if this customizer wasn't used
8
+ *
9
+ * @returns A string, a tuple of strings, or undefined.
10
+ * If a string is returned, it will be used as the value of the key/value pair.
11
+ * If a tuple of strings is returned, the first string will be used as the key of the key/value pair
12
+ * and the second string will be used as the value of the key/value pair.
13
+ * If undefined is returned, the pair will be removed
14
+ */
15
+ type Customizer<K extends string | symbol | number, V extends {}> = (value: V, defaultValueFormatter: (value: any) => string, key: K extends "*" ? string : K, defaultKeyFormatter: (key: string) => string) => [string, string] | string | undefined;
16
+ export declare function stringify<T extends Record<string, any>>(obj: T, customizer?: {
17
+ [K in keyof T | "*"]?: Customizer<K, T[K]>;
18
+ }, separator?: string): string;
19
+ export {};
20
+ //# sourceMappingURL=stringify.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"stringify.d.ts","sourceRoot":"","sources":["../../../src/util/stringify.ts"],"names":[],"mappings":"AAgBA;;;;;;;;;;;;;GAaG;AACH,KAAK,UAAU,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,GAAG,MAAM,EAAE,CAAC,SAAS,EAAE,IAAI,CAClE,KAAK,EAAE,CAAC,EACR,qBAAqB,EAAE,CAAC,KAAK,EAAE,GAAG,KAAK,MAAM,EAC7C,GAAG,EAAE,CAAC,SAAS,GAAG,GAAG,MAAM,GAAG,CAAC,EAC/B,mBAAmB,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,KACzC,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,MAAM,GAAG,SAAS,CAAC;AAU3C,wBAAgB,SAAS,CAAC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EACrD,GAAG,EAAE,CAAC,EACN,UAAU,GAAE;KACT,CAAC,IAAI,MAAM,CAAC,GAAG,GAAG,CAAC,CAAC,EAAE,UAAU,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;CACtC,EACN,SAAS,SAAQ,UA0BlB"}
@@ -0,0 +1,36 @@
1
+ /*
2
+ * Copyright 2023 Palantir Technologies, Inc. All rights reserved.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ const defaultCustomizer = (value, defaultValueFormatter, key, defaultKeyFormatter) => {
17
+ return [defaultKeyFormatter(key), defaultValueFormatter(value)];
18
+ };
19
+ export function stringify(obj, customizer = {}, separator = ",\n") {
20
+ const defaultKeyFormatter = key => `${JSON.stringify(key)}`;
21
+ const entries = [];
22
+ const sortedKeys = Object.keys(obj).sort((a, b) => a.localeCompare(b));
23
+ for (const key of sortedKeys) {
24
+ const value = obj[key];
25
+ const res = (customizer[key] ?? customizer["*"] ?? defaultCustomizer)(value, value => JSON.stringify(value, null, 2), key, defaultKeyFormatter);
26
+ if (res) {
27
+ if (typeof res === "string") {
28
+ entries.push(`${defaultKeyFormatter(key)}: ${res}`);
29
+ } else {
30
+ entries.push(`${res[0]}: ${res[1]}`);
31
+ }
32
+ }
33
+ }
34
+ return entries.join(separator);
35
+ }
36
+ //# sourceMappingURL=stringify.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"stringify.js","names":["defaultCustomizer","value","defaultValueFormatter","key","defaultKeyFormatter","stringify","obj","customizer","separator","JSON","entries","sortedKeys","Object","keys","sort","a","b","localeCompare","res","push","join"],"sources":["stringify.js"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nconst defaultCustomizer = (value, defaultValueFormatter, key, defaultKeyFormatter) => {\n return [defaultKeyFormatter(key), defaultValueFormatter(value)];\n};\nexport function stringify(obj, customizer = {}, separator = \",\\n\") {\n const defaultKeyFormatter = (key) => `${JSON.stringify(key)}`;\n const entries = [];\n const sortedKeys = Object.keys(obj).sort((a, b) => a.localeCompare(b));\n for (const key of sortedKeys) {\n const value = obj[key];\n const res = (customizer[key] ?? customizer[\"*\"] ?? defaultCustomizer)(value, (value) => JSON.stringify(value, null, 2), key, defaultKeyFormatter);\n if (res) {\n if (typeof res === \"string\") {\n entries.push(`${defaultKeyFormatter(key)}: ${res}`);\n }\n else {\n entries.push(`${res[0]}: ${res[1]}`);\n }\n }\n }\n return entries.join(separator);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMA,iBAAiB,GAAGA,CAACC,KAAK,EAAEC,qBAAqB,EAAEC,GAAG,EAAEC,mBAAmB,KAAK;EAClF,OAAO,CAACA,mBAAmB,CAACD,GAAG,CAAC,EAAED,qBAAqB,CAACD,KAAK,CAAC,CAAC;AACnE,CAAC;AACD,OAAO,SAASI,SAASA,CAACC,GAAG,EAAEC,UAAU,GAAG,CAAC,CAAC,EAAEC,SAAS,GAAG,KAAK,EAAE;EAC/D,MAAMJ,mBAAmB,GAAID,GAAG,IAAK,GAAGM,IAAI,CAACJ,SAAS,CAACF,GAAG,CAAC,EAAE;EAC7D,MAAMO,OAAO,GAAG,EAAE;EAClB,MAAMC,UAAU,GAAGC,MAAM,CAACC,IAAI,CAACP,GAAG,CAAC,CAACQ,IAAI,CAAC,CAACC,CAAC,EAAEC,CAAC,KAAKD,CAAC,CAACE,aAAa,CAACD,CAAC,CAAC,CAAC;EACtE,KAAK,MAAMb,GAAG,IAAIQ,UAAU,EAAE;IAC1B,MAAMV,KAAK,GAAGK,GAAG,CAACH,GAAG,CAAC;IACtB,MAAMe,GAAG,GAAG,CAACX,UAAU,CAACJ,GAAG,CAAC,IAAII,UAAU,CAAC,GAAG,CAAC,IAAIP,iBAAiB,EAAEC,KAAK,EAAGA,KAAK,IAAKQ,IAAI,CAACJ,SAAS,CAACJ,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC,EAAEE,GAAG,EAAEC,mBAAmB,CAAC;IACjJ,IAAIc,GAAG,EAAE;MACL,IAAI,OAAOA,GAAG,KAAK,QAAQ,EAAE;QACzBR,OAAO,CAACS,IAAI,CAAC,GAAGf,mBAAmB,CAACD,GAAG,CAAC,KAAKe,GAAG,EAAE,CAAC;MACvD,CAAC,MACI;QACDR,OAAO,CAACS,IAAI,CAAC,GAAGD,GAAG,CAAC,CAAC,CAAC,KAAKA,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC;MACxC;IACJ;EACJ;EACA,OAAOR,OAAO,CAACU,IAAI,CAACZ,SAAS,CAAC;AAClC","ignoreList":[]}