@loaders.gl/parquet 4.0.0-alpha.5 → 4.0.0-alpha.7

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 (596) hide show
  1. package/dist/bundle.js +2 -2
  2. package/dist/constants.js +18 -6
  3. package/dist/dist.min.js +27 -25
  4. package/dist/dist.min.js.map +3 -3
  5. package/dist/es5/bundle.js +6 -0
  6. package/dist/es5/bundle.js.map +1 -0
  7. package/dist/es5/constants.js +17 -0
  8. package/dist/es5/constants.js.map +1 -0
  9. package/dist/es5/index.js +128 -0
  10. package/dist/es5/index.js.map +1 -0
  11. package/dist/es5/lib/arrow/convert-columns-to-row-group.js +2 -0
  12. package/dist/es5/lib/arrow/convert-columns-to-row-group.js.map +1 -0
  13. package/dist/es5/lib/arrow/convert-row-group-to-columns.js +19 -0
  14. package/dist/es5/lib/arrow/convert-row-group-to-columns.js.map +1 -0
  15. package/dist/es5/lib/arrow/convert-schema-from-parquet.js +114 -0
  16. package/dist/es5/lib/arrow/convert-schema-from-parquet.js.map +1 -0
  17. package/dist/es5/lib/arrow/convert-schema-to-parquet.js +47 -0
  18. package/dist/es5/lib/arrow/convert-schema-to-parquet.js.map +1 -0
  19. package/dist/es5/lib/geo/decode-geo-metadata.js +81 -0
  20. package/dist/es5/lib/geo/decode-geo-metadata.js.map +1 -0
  21. package/dist/es5/lib/geo/geoparquet-schema.js +83 -0
  22. package/dist/es5/lib/geo/geoparquet-schema.js.map +1 -0
  23. package/dist/es5/lib/parsers/parse-parquet-to-columns.js +177 -0
  24. package/dist/es5/lib/parsers/parse-parquet-to-columns.js.map +1 -0
  25. package/dist/es5/lib/parsers/parse-parquet-to-rows.js +172 -0
  26. package/dist/es5/lib/parsers/parse-parquet-to-rows.js.map +1 -0
  27. package/dist/es5/lib/wasm/encode-parquet-wasm.js +43 -0
  28. package/dist/es5/lib/wasm/encode-parquet-wasm.js.map +1 -0
  29. package/dist/es5/lib/wasm/load-wasm/index.js +13 -0
  30. package/dist/es5/lib/wasm/load-wasm/index.js.map +1 -0
  31. package/dist/es5/lib/wasm/load-wasm/load-wasm-browser.js +42 -0
  32. package/dist/es5/lib/wasm/load-wasm/load-wasm-browser.js.map +1 -0
  33. package/dist/es5/lib/wasm/load-wasm/load-wasm-node.js +31 -0
  34. package/dist/es5/lib/wasm/load-wasm/load-wasm-node.js.map +1 -0
  35. package/dist/es5/lib/wasm/parse-parquet-wasm.js +60 -0
  36. package/dist/es5/lib/wasm/parse-parquet-wasm.js.map +1 -0
  37. package/dist/es5/lib/wip/convert-schema-deep.java.disabled +910 -0
  38. package/dist/es5/lib/wip/convert-schema-deep.rs.disabled +976 -0
  39. package/dist/es5/parquet-loader.js +44 -0
  40. package/dist/es5/parquet-loader.js.map +1 -0
  41. package/dist/es5/parquet-wasm-loader.js +30 -0
  42. package/dist/es5/parquet-wasm-loader.js.map +1 -0
  43. package/dist/es5/parquet-wasm-writer.js +26 -0
  44. package/dist/es5/parquet-wasm-writer.js.map +1 -0
  45. package/dist/es5/parquet-writer.js +24 -0
  46. package/dist/es5/parquet-writer.js.map +1 -0
  47. package/dist/es5/parquetjs/codecs/declare.js +2 -0
  48. package/dist/es5/parquetjs/codecs/declare.js.map +1 -0
  49. package/dist/es5/parquetjs/codecs/dictionary.js +23 -0
  50. package/dist/es5/parquetjs/codecs/dictionary.js.map +1 -0
  51. package/dist/es5/parquetjs/codecs/index.js +47 -0
  52. package/dist/es5/parquetjs/codecs/index.js.map +1 -0
  53. package/dist/es5/parquetjs/codecs/plain.js +208 -0
  54. package/dist/es5/parquetjs/codecs/plain.js.map +1 -0
  55. package/dist/es5/parquetjs/codecs/rle.js +132 -0
  56. package/dist/es5/parquetjs/codecs/rle.js.map +1 -0
  57. package/dist/es5/parquetjs/compression.js +137 -0
  58. package/dist/es5/parquetjs/compression.js.map +1 -0
  59. package/dist/es5/parquetjs/encoder/parquet-encoder.js +625 -0
  60. package/dist/es5/parquetjs/encoder/parquet-encoder.js.map +1 -0
  61. package/dist/es5/parquetjs/parquet-thrift/BoundaryOrder.js +14 -0
  62. package/dist/es5/parquetjs/parquet-thrift/BoundaryOrder.js.map +1 -0
  63. package/dist/es5/parquetjs/parquet-thrift/BsonType.js +52 -0
  64. package/dist/es5/parquetjs/parquet-thrift/BsonType.js.map +1 -0
  65. package/dist/es5/parquetjs/parquet-thrift/ColumnChunk.js +193 -0
  66. package/dist/es5/parquetjs/parquet-thrift/ColumnChunk.js.map +1 -0
  67. package/dist/es5/parquetjs/parquet-thrift/ColumnIndex.js +198 -0
  68. package/dist/es5/parquetjs/parquet-thrift/ColumnIndex.js.map +1 -0
  69. package/dist/es5/parquetjs/parquet-thrift/ColumnMetaData.js +367 -0
  70. package/dist/es5/parquetjs/parquet-thrift/ColumnMetaData.js.map +1 -0
  71. package/dist/es5/parquetjs/parquet-thrift/ColumnOrder.js +99 -0
  72. package/dist/es5/parquetjs/parquet-thrift/ColumnOrder.js.map +1 -0
  73. package/dist/es5/parquetjs/parquet-thrift/CompressionCodec.js +19 -0
  74. package/dist/es5/parquetjs/parquet-thrift/CompressionCodec.js.map +1 -0
  75. package/dist/es5/parquetjs/parquet-thrift/ConvertedType.js +33 -0
  76. package/dist/es5/parquetjs/parquet-thrift/ConvertedType.js.map +1 -0
  77. package/dist/es5/parquetjs/parquet-thrift/DataPageHeader.js +152 -0
  78. package/dist/es5/parquetjs/parquet-thrift/DataPageHeader.js.map +1 -0
  79. package/dist/es5/parquetjs/parquet-thrift/DataPageHeaderV2.js +207 -0
  80. package/dist/es5/parquetjs/parquet-thrift/DataPageHeaderV2.js.map +1 -0
  81. package/dist/es5/parquetjs/parquet-thrift/DateType.js +52 -0
  82. package/dist/es5/parquetjs/parquet-thrift/DateType.js.map +1 -0
  83. package/dist/es5/parquetjs/parquet-thrift/DecimalType.js +96 -0
  84. package/dist/es5/parquetjs/parquet-thrift/DecimalType.js.map +1 -0
  85. package/dist/es5/parquetjs/parquet-thrift/DictionaryPageHeader.js +113 -0
  86. package/dist/es5/parquetjs/parquet-thrift/DictionaryPageHeader.js.map +1 -0
  87. package/dist/es5/parquetjs/parquet-thrift/Encoding.js +19 -0
  88. package/dist/es5/parquetjs/parquet-thrift/Encoding.js.map +1 -0
  89. package/dist/es5/parquetjs/parquet-thrift/EnumType.js +52 -0
  90. package/dist/es5/parquetjs/parquet-thrift/EnumType.js.map +1 -0
  91. package/dist/es5/parquetjs/parquet-thrift/FieldRepetitionType.js +14 -0
  92. package/dist/es5/parquetjs/parquet-thrift/FieldRepetitionType.js.map +1 -0
  93. package/dist/es5/parquetjs/parquet-thrift/FileMetaData.js +239 -0
  94. package/dist/es5/parquetjs/parquet-thrift/FileMetaData.js.map +1 -0
  95. package/dist/es5/parquetjs/parquet-thrift/IndexPageHeader.js +52 -0
  96. package/dist/es5/parquetjs/parquet-thrift/IndexPageHeader.js.map +1 -0
  97. package/dist/es5/parquetjs/parquet-thrift/IntType.js +96 -0
  98. package/dist/es5/parquetjs/parquet-thrift/IntType.js.map +1 -0
  99. package/dist/es5/parquetjs/parquet-thrift/JsonType.js +52 -0
  100. package/dist/es5/parquetjs/parquet-thrift/JsonType.js.map +1 -0
  101. package/dist/es5/parquetjs/parquet-thrift/KeyValue.js +94 -0
  102. package/dist/es5/parquetjs/parquet-thrift/KeyValue.js.map +1 -0
  103. package/dist/es5/parquetjs/parquet-thrift/ListType.js +52 -0
  104. package/dist/es5/parquetjs/parquet-thrift/ListType.js.map +1 -0
  105. package/dist/es5/parquetjs/parquet-thrift/LogicalType.js +423 -0
  106. package/dist/es5/parquetjs/parquet-thrift/LogicalType.js.map +1 -0
  107. package/dist/es5/parquetjs/parquet-thrift/MapType.js +52 -0
  108. package/dist/es5/parquetjs/parquet-thrift/MapType.js.map +1 -0
  109. package/dist/es5/parquetjs/parquet-thrift/MicroSeconds.js +52 -0
  110. package/dist/es5/parquetjs/parquet-thrift/MicroSeconds.js.map +1 -0
  111. package/dist/es5/parquetjs/parquet-thrift/MilliSeconds.js +52 -0
  112. package/dist/es5/parquetjs/parquet-thrift/MilliSeconds.js.map +1 -0
  113. package/dist/es5/parquetjs/parquet-thrift/NullType.js +52 -0
  114. package/dist/es5/parquetjs/parquet-thrift/NullType.js.map +1 -0
  115. package/dist/es5/parquetjs/parquet-thrift/OffsetIndex.js +89 -0
  116. package/dist/es5/parquetjs/parquet-thrift/OffsetIndex.js.map +1 -0
  117. package/dist/es5/parquetjs/parquet-thrift/PageEncodingStats.js +115 -0
  118. package/dist/es5/parquetjs/parquet-thrift/PageEncodingStats.js.map +1 -0
  119. package/dist/es5/parquetjs/parquet-thrift/PageHeader.js +204 -0
  120. package/dist/es5/parquetjs/parquet-thrift/PageHeader.js.map +1 -0
  121. package/dist/es5/parquetjs/parquet-thrift/PageLocation.js +124 -0
  122. package/dist/es5/parquetjs/parquet-thrift/PageLocation.js.map +1 -0
  123. package/dist/es5/parquetjs/parquet-thrift/PageType.js +15 -0
  124. package/dist/es5/parquetjs/parquet-thrift/PageType.js.map +1 -0
  125. package/dist/es5/parquetjs/parquet-thrift/RowGroup.js +165 -0
  126. package/dist/es5/parquetjs/parquet-thrift/RowGroup.js.map +1 -0
  127. package/dist/es5/parquetjs/parquet-thrift/SchemaElement.js +231 -0
  128. package/dist/es5/parquetjs/parquet-thrift/SchemaElement.js.map +1 -0
  129. package/dist/es5/parquetjs/parquet-thrift/SortingColumn.js +115 -0
  130. package/dist/es5/parquetjs/parquet-thrift/SortingColumn.js.map +1 -0
  131. package/dist/es5/parquetjs/parquet-thrift/Statistics.js +165 -0
  132. package/dist/es5/parquetjs/parquet-thrift/Statistics.js.map +1 -0
  133. package/dist/es5/parquetjs/parquet-thrift/StringType.js +52 -0
  134. package/dist/es5/parquetjs/parquet-thrift/StringType.js.map +1 -0
  135. package/dist/es5/parquetjs/parquet-thrift/TimeType.js +97 -0
  136. package/dist/es5/parquetjs/parquet-thrift/TimeType.js.map +1 -0
  137. package/dist/es5/parquetjs/parquet-thrift/TimeUnit.js +126 -0
  138. package/dist/es5/parquetjs/parquet-thrift/TimeUnit.js.map +1 -0
  139. package/dist/es5/parquetjs/parquet-thrift/TimestampType.js +97 -0
  140. package/dist/es5/parquetjs/parquet-thrift/TimestampType.js.map +1 -0
  141. package/dist/es5/parquetjs/parquet-thrift/Type.js +19 -0
  142. package/dist/es5/parquetjs/parquet-thrift/Type.js.map +1 -0
  143. package/dist/es5/parquetjs/parquet-thrift/TypeDefinedOrder.js +52 -0
  144. package/dist/es5/parquetjs/parquet-thrift/TypeDefinedOrder.js.map +1 -0
  145. package/dist/es5/parquetjs/parquet-thrift/UUIDType.js +52 -0
  146. package/dist/es5/parquetjs/parquet-thrift/UUIDType.js.map +1 -0
  147. package/dist/es5/parquetjs/parquet-thrift/index.js +479 -0
  148. package/dist/es5/parquetjs/parquet-thrift/index.js.map +1 -0
  149. package/dist/es5/parquetjs/parser/decoders.js +393 -0
  150. package/dist/es5/parquetjs/parser/decoders.js.map +1 -0
  151. package/dist/es5/parquetjs/parser/parquet-reader.js +610 -0
  152. package/dist/es5/parquetjs/parser/parquet-reader.js.map +1 -0
  153. package/dist/es5/parquetjs/schema/declare.js +21 -0
  154. package/dist/es5/parquetjs/schema/declare.js.map +1 -0
  155. package/dist/es5/parquetjs/schema/schema.js +165 -0
  156. package/dist/es5/parquetjs/schema/schema.js.map +1 -0
  157. package/dist/es5/parquetjs/schema/shred.js +282 -0
  158. package/dist/es5/parquetjs/schema/shred.js.map +1 -0
  159. package/dist/es5/parquetjs/schema/types.js +406 -0
  160. package/dist/es5/parquetjs/schema/types.js.map +1 -0
  161. package/dist/es5/parquetjs/utils/file-utils.js +47 -0
  162. package/dist/es5/parquetjs/utils/file-utils.js.map +1 -0
  163. package/dist/es5/parquetjs/utils/read-utils.js +120 -0
  164. package/dist/es5/parquetjs/utils/read-utils.js.map +1 -0
  165. package/dist/es5/workers/parquet-worker.js +6 -0
  166. package/dist/es5/workers/parquet-worker.js.map +1 -0
  167. package/dist/esm/bundle.js +4 -0
  168. package/dist/esm/bundle.js.map +1 -0
  169. package/dist/esm/constants.js +6 -0
  170. package/dist/esm/constants.js.map +1 -0
  171. package/dist/esm/index.js +31 -0
  172. package/dist/esm/index.js.map +1 -0
  173. package/dist/esm/lib/arrow/convert-columns-to-row-group.js +2 -0
  174. package/dist/esm/lib/arrow/convert-columns-to-row-group.js.map +1 -0
  175. package/dist/esm/lib/arrow/convert-row-group-to-columns.js +8 -0
  176. package/dist/esm/lib/arrow/convert-row-group-to-columns.js.map +1 -0
  177. package/dist/esm/lib/arrow/convert-schema-from-parquet.js +95 -0
  178. package/dist/esm/lib/arrow/convert-schema-from-parquet.js.map +1 -0
  179. package/dist/esm/lib/arrow/convert-schema-to-parquet.js +39 -0
  180. package/dist/esm/lib/arrow/convert-schema-to-parquet.js.map +1 -0
  181. package/dist/esm/lib/geo/decode-geo-metadata.js +62 -0
  182. package/dist/esm/lib/geo/decode-geo-metadata.js.map +1 -0
  183. package/dist/esm/lib/geo/geoparquet-schema.js +76 -0
  184. package/dist/esm/lib/geo/geoparquet-schema.js.map +1 -0
  185. package/dist/esm/lib/parsers/parse-parquet-to-columns.js +39 -0
  186. package/dist/esm/lib/parsers/parse-parquet-to-columns.js.map +1 -0
  187. package/dist/esm/lib/parsers/parse-parquet-to-rows.js +29 -0
  188. package/dist/esm/lib/parsers/parse-parquet-to-rows.js.map +1 -0
  189. package/dist/esm/lib/wasm/encode-parquet-wasm.js +15 -0
  190. package/dist/esm/lib/wasm/encode-parquet-wasm.js.map +1 -0
  191. package/dist/esm/lib/wasm/load-wasm/index.js +2 -0
  192. package/dist/esm/lib/wasm/load-wasm/index.js.map +1 -0
  193. package/dist/esm/lib/wasm/load-wasm/load-wasm-browser.js +11 -0
  194. package/dist/esm/lib/wasm/load-wasm/load-wasm-browser.js.map +1 -0
  195. package/dist/esm/lib/wasm/load-wasm/load-wasm-node.js +5 -0
  196. package/dist/esm/lib/wasm/load-wasm/load-wasm-node.js.map +1 -0
  197. package/dist/esm/lib/wasm/parse-parquet-wasm.js +21 -0
  198. package/dist/esm/lib/wasm/parse-parquet-wasm.js.map +1 -0
  199. package/dist/esm/lib/wip/convert-schema-deep.java.disabled +910 -0
  200. package/dist/esm/lib/wip/convert-schema-deep.rs.disabled +976 -0
  201. package/dist/esm/parquet-loader.js +36 -0
  202. package/dist/esm/parquet-loader.js.map +1 -0
  203. package/dist/esm/parquet-wasm-loader.js +22 -0
  204. package/dist/esm/parquet-wasm-loader.js.map +1 -0
  205. package/dist/esm/parquet-wasm-writer.js +19 -0
  206. package/dist/esm/parquet-wasm-writer.js.map +1 -0
  207. package/dist/esm/parquet-writer.js +17 -0
  208. package/dist/esm/parquet-writer.js.map +1 -0
  209. package/dist/esm/parquetjs/LICENSE +20 -0
  210. package/dist/esm/parquetjs/codecs/declare.js +2 -0
  211. package/dist/esm/parquetjs/codecs/declare.js.map +1 -0
  212. package/dist/esm/parquetjs/codecs/dictionary.js +13 -0
  213. package/dist/esm/parquetjs/codecs/dictionary.js.map +1 -0
  214. package/dist/esm/parquetjs/codecs/index.js +23 -0
  215. package/dist/esm/parquetjs/codecs/index.js.map +1 -0
  216. package/dist/esm/parquetjs/codecs/plain.js +200 -0
  217. package/dist/esm/parquetjs/codecs/plain.js.map +1 -0
  218. package/dist/esm/parquetjs/codecs/rle.js +119 -0
  219. package/dist/esm/parquetjs/codecs/rle.js.map +1 -0
  220. package/dist/esm/parquetjs/compression.js +61 -0
  221. package/dist/esm/parquetjs/compression.js.map +1 -0
  222. package/dist/{parquetjs/encoder/writer.js → esm/parquetjs/encoder/parquet-encoder.js} +8 -106
  223. package/dist/esm/parquetjs/encoder/parquet-encoder.js.map +1 -0
  224. package/dist/esm/parquetjs/modules.d.ts +21 -0
  225. package/dist/esm/parquetjs/parquet-thrift/BoundaryOrder.js +7 -0
  226. package/dist/esm/parquetjs/parquet-thrift/BoundaryOrder.js.map +1 -0
  227. package/dist/esm/parquetjs/parquet-thrift/BsonType.js +31 -0
  228. package/dist/esm/parquetjs/parquet-thrift/BsonType.js.map +1 -0
  229. package/dist/esm/parquetjs/parquet-thrift/ColumnChunk.js +173 -0
  230. package/dist/esm/parquetjs/parquet-thrift/ColumnChunk.js.map +1 -0
  231. package/dist/esm/parquetjs/parquet-thrift/ColumnIndex.js +176 -0
  232. package/dist/esm/parquetjs/parquet-thrift/ColumnIndex.js.map +1 -0
  233. package/dist/esm/parquetjs/parquet-thrift/ColumnMetaData.js +347 -0
  234. package/dist/esm/parquetjs/parquet-thrift/ColumnMetaData.js.map +1 -0
  235. package/dist/esm/parquetjs/parquet-thrift/ColumnOrder.js +77 -0
  236. package/dist/esm/parquetjs/parquet-thrift/ColumnOrder.js.map +1 -0
  237. package/dist/esm/parquetjs/parquet-thrift/CompressionCodec.js +12 -0
  238. package/dist/esm/parquetjs/parquet-thrift/CompressionCodec.js.map +1 -0
  239. package/dist/esm/parquetjs/parquet-thrift/ConvertedType.js +26 -0
  240. package/dist/esm/parquetjs/parquet-thrift/ConvertedType.js.map +1 -0
  241. package/dist/esm/parquetjs/parquet-thrift/DataPageHeader.js +132 -0
  242. package/dist/esm/parquetjs/parquet-thrift/DataPageHeader.js.map +1 -0
  243. package/dist/esm/parquetjs/parquet-thrift/DataPageHeaderV2.js +187 -0
  244. package/dist/esm/parquetjs/parquet-thrift/DataPageHeaderV2.js.map +1 -0
  245. package/dist/esm/parquetjs/parquet-thrift/DateType.js +31 -0
  246. package/dist/esm/parquetjs/parquet-thrift/DateType.js.map +1 -0
  247. package/dist/esm/parquetjs/parquet-thrift/DecimalType.js +76 -0
  248. package/dist/esm/parquetjs/parquet-thrift/DecimalType.js.map +1 -0
  249. package/dist/esm/parquetjs/parquet-thrift/DictionaryPageHeader.js +93 -0
  250. package/dist/esm/parquetjs/parquet-thrift/DictionaryPageHeader.js.map +1 -0
  251. package/dist/esm/parquetjs/parquet-thrift/Encoding.js +12 -0
  252. package/dist/esm/parquetjs/parquet-thrift/Encoding.js.map +1 -0
  253. package/dist/esm/parquetjs/parquet-thrift/EnumType.js +31 -0
  254. package/dist/esm/parquetjs/parquet-thrift/EnumType.js.map +1 -0
  255. package/dist/esm/parquetjs/parquet-thrift/FieldRepetitionType.js +7 -0
  256. package/dist/esm/parquetjs/parquet-thrift/FieldRepetitionType.js.map +1 -0
  257. package/dist/esm/parquetjs/parquet-thrift/FileMetaData.js +219 -0
  258. package/dist/esm/parquetjs/parquet-thrift/FileMetaData.js.map +1 -0
  259. package/dist/esm/parquetjs/parquet-thrift/IndexPageHeader.js +31 -0
  260. package/dist/esm/parquetjs/parquet-thrift/IndexPageHeader.js.map +1 -0
  261. package/dist/esm/parquetjs/parquet-thrift/IntType.js +76 -0
  262. package/dist/esm/parquetjs/parquet-thrift/IntType.js.map +1 -0
  263. package/dist/esm/parquetjs/parquet-thrift/JsonType.js +31 -0
  264. package/dist/esm/parquetjs/parquet-thrift/JsonType.js.map +1 -0
  265. package/dist/esm/parquetjs/parquet-thrift/KeyValue.js +74 -0
  266. package/dist/esm/parquetjs/parquet-thrift/KeyValue.js.map +1 -0
  267. package/dist/esm/parquetjs/parquet-thrift/ListType.js +31 -0
  268. package/dist/esm/parquetjs/parquet-thrift/ListType.js.map +1 -0
  269. package/dist/esm/parquetjs/parquet-thrift/LogicalType.js +377 -0
  270. package/dist/esm/parquetjs/parquet-thrift/LogicalType.js.map +1 -0
  271. package/dist/esm/parquetjs/parquet-thrift/MapType.js +31 -0
  272. package/dist/esm/parquetjs/parquet-thrift/MapType.js.map +1 -0
  273. package/dist/esm/parquetjs/parquet-thrift/MicroSeconds.js +31 -0
  274. package/dist/esm/parquetjs/parquet-thrift/MicroSeconds.js.map +1 -0
  275. package/dist/esm/parquetjs/parquet-thrift/MilliSeconds.js +31 -0
  276. package/dist/esm/parquetjs/parquet-thrift/MilliSeconds.js.map +1 -0
  277. package/dist/esm/parquetjs/parquet-thrift/NullType.js +31 -0
  278. package/dist/esm/parquetjs/parquet-thrift/NullType.js.map +1 -0
  279. package/dist/esm/parquetjs/parquet-thrift/OffsetIndex.js +69 -0
  280. package/dist/esm/parquetjs/parquet-thrift/OffsetIndex.js.map +1 -0
  281. package/dist/esm/parquetjs/parquet-thrift/PageEncodingStats.js +95 -0
  282. package/dist/esm/parquetjs/parquet-thrift/PageEncodingStats.js.map +1 -0
  283. package/dist/esm/parquetjs/parquet-thrift/PageHeader.js +184 -0
  284. package/dist/esm/parquetjs/parquet-thrift/PageHeader.js.map +1 -0
  285. package/dist/esm/parquetjs/parquet-thrift/PageLocation.js +104 -0
  286. package/dist/esm/parquetjs/parquet-thrift/PageLocation.js.map +1 -0
  287. package/dist/esm/parquetjs/parquet-thrift/PageType.js +8 -0
  288. package/dist/esm/parquetjs/parquet-thrift/PageType.js.map +1 -0
  289. package/dist/esm/parquetjs/parquet-thrift/RowGroup.js +145 -0
  290. package/dist/esm/parquetjs/parquet-thrift/RowGroup.js.map +1 -0
  291. package/dist/esm/parquetjs/parquet-thrift/SchemaElement.js +211 -0
  292. package/dist/esm/parquetjs/parquet-thrift/SchemaElement.js.map +1 -0
  293. package/dist/esm/parquetjs/parquet-thrift/SortingColumn.js +95 -0
  294. package/dist/esm/parquetjs/parquet-thrift/SortingColumn.js.map +1 -0
  295. package/dist/esm/parquetjs/parquet-thrift/Statistics.js +145 -0
  296. package/dist/esm/parquetjs/parquet-thrift/Statistics.js.map +1 -0
  297. package/dist/esm/parquetjs/parquet-thrift/StringType.js +31 -0
  298. package/dist/esm/parquetjs/parquet-thrift/StringType.js.map +1 -0
  299. package/dist/esm/parquetjs/parquet-thrift/TimeType.js +77 -0
  300. package/dist/esm/parquetjs/parquet-thrift/TimeType.js.map +1 -0
  301. package/dist/esm/parquetjs/parquet-thrift/TimeUnit.js +102 -0
  302. package/dist/esm/parquetjs/parquet-thrift/TimeUnit.js.map +1 -0
  303. package/dist/esm/parquetjs/parquet-thrift/TimestampType.js +77 -0
  304. package/dist/esm/parquetjs/parquet-thrift/TimestampType.js.map +1 -0
  305. package/dist/esm/parquetjs/parquet-thrift/Type.js +12 -0
  306. package/dist/esm/parquetjs/parquet-thrift/Type.js.map +1 -0
  307. package/dist/esm/parquetjs/parquet-thrift/TypeDefinedOrder.js +31 -0
  308. package/dist/esm/parquetjs/parquet-thrift/TypeDefinedOrder.js.map +1 -0
  309. package/dist/esm/parquetjs/parquet-thrift/UUIDType.js +31 -0
  310. package/dist/esm/parquetjs/parquet-thrift/UUIDType.js.map +1 -0
  311. package/dist/esm/parquetjs/parquet-thrift/index.js +44 -0
  312. package/dist/esm/parquetjs/parquet-thrift/index.js.map +1 -0
  313. package/dist/esm/parquetjs/parser/decoders.js +253 -0
  314. package/dist/esm/parquetjs/parser/decoders.js.map +1 -0
  315. package/dist/{parquetjs/parser/parquet-envelope-reader.js → esm/parquetjs/parser/parquet-reader.js} +95 -74
  316. package/dist/esm/parquetjs/parser/parquet-reader.js.map +1 -0
  317. package/dist/esm/parquetjs/schema/declare.js +12 -0
  318. package/dist/esm/parquetjs/schema/declare.js.map +1 -0
  319. package/dist/esm/parquetjs/schema/schema.js +140 -0
  320. package/dist/esm/parquetjs/schema/schema.js.map +1 -0
  321. package/dist/esm/parquetjs/schema/shred.js +228 -0
  322. package/dist/esm/parquetjs/schema/shred.js.map +1 -0
  323. package/dist/esm/parquetjs/schema/types.js +397 -0
  324. package/dist/esm/parquetjs/schema/types.js.map +1 -0
  325. package/dist/esm/parquetjs/utils/file-utils.js +34 -0
  326. package/dist/esm/parquetjs/utils/file-utils.js.map +1 -0
  327. package/dist/esm/parquetjs/utils/read-utils.js +90 -0
  328. package/dist/esm/parquetjs/utils/read-utils.js.map +1 -0
  329. package/dist/esm/workers/parquet-worker.js +4 -0
  330. package/dist/esm/workers/parquet-worker.js.map +1 -0
  331. package/dist/index.d.ts +16 -20
  332. package/dist/index.d.ts.map +1 -1
  333. package/dist/index.js +58 -15
  334. package/dist/lib/arrow/convert-columns-to-row-group.d.ts +1 -0
  335. package/dist/lib/arrow/convert-columns-to-row-group.d.ts.map +1 -0
  336. package/dist/lib/arrow/convert-columns-to-row-group.js +1 -0
  337. package/dist/lib/arrow/convert-row-group-to-columns.d.ts +4 -0
  338. package/dist/lib/arrow/convert-row-group-to-columns.d.ts.map +1 -0
  339. package/dist/lib/arrow/convert-row-group-to-columns.js +12 -0
  340. package/dist/lib/arrow/convert-schema-from-parquet.d.ts +9 -0
  341. package/dist/lib/arrow/convert-schema-from-parquet.d.ts.map +1 -0
  342. package/dist/lib/arrow/convert-schema-from-parquet.js +86 -0
  343. package/dist/lib/arrow/convert-schema-to-parquet.d.ts +7 -0
  344. package/dist/lib/arrow/convert-schema-to-parquet.d.ts.map +1 -0
  345. package/dist/lib/arrow/convert-schema-to-parquet.js +71 -0
  346. package/dist/lib/geo/decode-geo-metadata.d.ts +31 -0
  347. package/dist/lib/geo/decode-geo-metadata.d.ts.map +1 -0
  348. package/dist/lib/geo/decode-geo-metadata.js +77 -0
  349. package/dist/lib/geo/geoparquet-schema.d.ts +80 -0
  350. package/dist/lib/geo/geoparquet-schema.d.ts.map +1 -0
  351. package/dist/lib/geo/geoparquet-schema.js +69 -0
  352. package/dist/lib/parsers/parse-parquet-to-columns.d.ts +5 -0
  353. package/dist/lib/parsers/parse-parquet-to-columns.d.ts.map +1 -0
  354. package/dist/lib/parsers/parse-parquet-to-columns.js +46 -0
  355. package/dist/lib/parsers/parse-parquet-to-rows.d.ts +5 -0
  356. package/dist/lib/parsers/parse-parquet-to-rows.d.ts.map +1 -0
  357. package/dist/lib/parsers/parse-parquet-to-rows.js +37 -0
  358. package/dist/lib/wasm/encode-parquet-wasm.d.ts +21 -0
  359. package/dist/lib/wasm/encode-parquet-wasm.d.ts.map +1 -0
  360. package/dist/lib/wasm/encode-parquet-wasm.js +30 -0
  361. package/dist/lib/wasm/load-wasm/index.d.ts +2 -0
  362. package/dist/lib/wasm/load-wasm/index.d.ts.map +1 -0
  363. package/dist/lib/wasm/load-wasm/index.js +5 -0
  364. package/dist/lib/wasm/load-wasm/load-wasm-browser.d.ts +3 -0
  365. package/dist/lib/wasm/load-wasm/load-wasm-browser.d.ts.map +1 -0
  366. package/dist/lib/wasm/load-wasm/load-wasm-browser.js +38 -0
  367. package/dist/lib/wasm/load-wasm/load-wasm-node.d.ts +3 -0
  368. package/dist/lib/wasm/load-wasm/load-wasm-node.d.ts.map +1 -0
  369. package/dist/lib/wasm/load-wasm/load-wasm-node.js +31 -0
  370. package/dist/lib/wasm/parse-parquet-wasm.d.ts +10 -0
  371. package/dist/lib/wasm/parse-parquet-wasm.d.ts.map +1 -0
  372. package/dist/lib/wasm/parse-parquet-wasm.js +27 -0
  373. package/dist/parquet-loader.d.ts +6 -15
  374. package/dist/parquet-loader.d.ts.map +1 -1
  375. package/dist/parquet-loader.js +38 -19
  376. package/dist/parquet-wasm-loader.d.ts +23 -0
  377. package/dist/parquet-wasm-loader.d.ts.map +1 -0
  378. package/dist/parquet-wasm-loader.js +27 -0
  379. package/dist/parquet-wasm-writer.d.ts +3 -0
  380. package/dist/parquet-wasm-writer.d.ts.map +1 -0
  381. package/dist/parquet-wasm-writer.js +23 -0
  382. package/dist/parquet-worker.js +27 -25
  383. package/dist/parquet-worker.js.map +3 -3
  384. package/dist/parquet-writer.d.ts +3 -2
  385. package/dist/parquet-writer.d.ts.map +1 -1
  386. package/dist/parquet-writer.js +18 -14
  387. package/dist/parquetjs/codecs/declare.js +2 -2
  388. package/dist/parquetjs/codecs/dictionary.js +12 -10
  389. package/dist/parquetjs/codecs/index.js +54 -22
  390. package/dist/parquetjs/codecs/plain.js +173 -232
  391. package/dist/parquetjs/codecs/rle.js +134 -140
  392. package/dist/parquetjs/compression.d.ts +3 -0
  393. package/dist/parquetjs/compression.d.ts.map +1 -1
  394. package/dist/parquetjs/compression.js +169 -48
  395. package/dist/parquetjs/encoder/{writer.d.ts → parquet-encoder.d.ts} +15 -23
  396. package/dist/parquetjs/encoder/parquet-encoder.d.ts.map +1 -0
  397. package/dist/parquetjs/encoder/parquet-encoder.js +484 -0
  398. package/dist/parquetjs/parquet-thrift/BoundaryOrder.js +14 -7
  399. package/dist/parquetjs/parquet-thrift/BsonType.js +60 -37
  400. package/dist/parquetjs/parquet-thrift/ColumnChunk.js +209 -215
  401. package/dist/parquetjs/parquet-thrift/ColumnIndex.js +210 -211
  402. package/dist/parquetjs/parquet-thrift/ColumnMetaData.js +394 -421
  403. package/dist/parquetjs/parquet-thrift/ColumnOrder.js +102 -89
  404. package/dist/parquetjs/parquet-thrift/CompressionCodec.js +19 -12
  405. package/dist/parquetjs/parquet-thrift/ConvertedType.js +33 -26
  406. package/dist/parquetjs/parquet-thrift/DataPageHeader.js +165 -161
  407. package/dist/parquetjs/parquet-thrift/DataPageHeaderV2.js +228 -234
  408. package/dist/parquetjs/parquet-thrift/DateType.js +60 -37
  409. package/dist/parquetjs/parquet-thrift/DecimalType.js +104 -90
  410. package/dist/parquetjs/parquet-thrift/DictionaryPageHeader.js +121 -112
  411. package/dist/parquetjs/parquet-thrift/Encoding.js +19 -12
  412. package/dist/parquetjs/parquet-thrift/EnumType.js +60 -37
  413. package/dist/parquetjs/parquet-thrift/FieldRepetitionType.js +14 -7
  414. package/dist/parquetjs/parquet-thrift/FileMetaData.js +253 -263
  415. package/dist/parquetjs/parquet-thrift/IndexPageHeader.js +60 -37
  416. package/dist/parquetjs/parquet-thrift/IntType.js +104 -90
  417. package/dist/parquetjs/parquet-thrift/JsonType.js +60 -37
  418. package/dist/parquetjs/parquet-thrift/KeyValue.js +101 -88
  419. package/dist/parquetjs/parquet-thrift/ListType.js +60 -37
  420. package/dist/parquetjs/parquet-thrift/LogicalType.js +366 -449
  421. package/dist/parquetjs/parquet-thrift/MapType.js +60 -37
  422. package/dist/parquetjs/parquet-thrift/MicroSeconds.js +60 -37
  423. package/dist/parquetjs/parquet-thrift/MilliSeconds.js +60 -37
  424. package/dist/parquetjs/parquet-thrift/NullType.js +60 -37
  425. package/dist/parquetjs/parquet-thrift/OffsetIndex.js +96 -80
  426. package/dist/parquetjs/parquet-thrift/PageEncodingStats.js +126 -114
  427. package/dist/parquetjs/parquet-thrift/PageHeader.js +218 -231
  428. package/dist/parquetjs/parquet-thrift/PageLocation.js +140 -123
  429. package/dist/parquetjs/parquet-thrift/PageType.js +15 -8
  430. package/dist/parquetjs/parquet-thrift/RowGroup.js +179 -171
  431. package/dist/parquetjs/parquet-thrift/SchemaElement.js +241 -268
  432. package/dist/parquetjs/parquet-thrift/SortingColumn.js +126 -114
  433. package/dist/parquetjs/parquet-thrift/Statistics.js +175 -178
  434. package/dist/parquetjs/parquet-thrift/StringType.js +60 -37
  435. package/dist/parquetjs/parquet-thrift/TimeType.js +105 -91
  436. package/dist/parquetjs/parquet-thrift/TimeUnit.js +124 -119
  437. package/dist/parquetjs/parquet-thrift/TimestampType.js +105 -91
  438. package/dist/parquetjs/parquet-thrift/Type.js +19 -12
  439. package/dist/parquetjs/parquet-thrift/TypeDefinedOrder.js +60 -37
  440. package/dist/parquetjs/parquet-thrift/UUIDType.js +60 -37
  441. package/dist/parquetjs/parquet-thrift/index.js +65 -44
  442. package/dist/parquetjs/parser/decoders.d.ts +2 -2
  443. package/dist/parquetjs/parser/decoders.d.ts.map +1 -1
  444. package/dist/parquetjs/parser/decoders.js +301 -283
  445. package/dist/parquetjs/parser/parquet-reader.d.ts +47 -57
  446. package/dist/parquetjs/parser/parquet-reader.d.ts.map +1 -1
  447. package/dist/parquetjs/parser/parquet-reader.js +193 -113
  448. package/dist/parquetjs/schema/declare.d.ts +26 -18
  449. package/dist/parquetjs/schema/declare.d.ts.map +1 -1
  450. package/dist/parquetjs/schema/declare.js +11 -12
  451. package/dist/parquetjs/schema/schema.d.ts +4 -4
  452. package/dist/parquetjs/schema/schema.d.ts.map +1 -1
  453. package/dist/parquetjs/schema/schema.js +148 -162
  454. package/dist/parquetjs/schema/shred.d.ts +33 -12
  455. package/dist/parquetjs/schema/shred.d.ts.map +1 -1
  456. package/dist/parquetjs/schema/shred.js +340 -147
  457. package/dist/parquetjs/schema/types.d.ts +2 -2
  458. package/dist/parquetjs/schema/types.d.ts.map +1 -1
  459. package/dist/parquetjs/schema/types.js +355 -415
  460. package/dist/parquetjs/utils/file-utils.d.ts +5 -4
  461. package/dist/parquetjs/utils/file-utils.d.ts.map +1 -1
  462. package/dist/parquetjs/utils/file-utils.js +37 -28
  463. package/dist/parquetjs/utils/read-utils.js +99 -95
  464. package/dist/workers/parquet-worker.js +5 -4
  465. package/package.json +17 -12
  466. package/src/index.ts +58 -7
  467. package/src/lib/arrow/convert-columns-to-row-group.ts +0 -0
  468. package/src/lib/arrow/convert-row-group-to-columns.ts +15 -0
  469. package/src/lib/arrow/convert-schema-from-parquet.ts +104 -0
  470. package/src/lib/arrow/convert-schema-to-parquet.ts +90 -0
  471. package/src/lib/geo/decode-geo-metadata.ts +108 -0
  472. package/src/lib/geo/geoparquet-schema.ts +69 -0
  473. package/src/lib/parsers/parse-parquet-to-columns.ts +60 -0
  474. package/src/lib/parsers/parse-parquet-to-rows.ts +45 -0
  475. package/src/lib/wasm/encode-parquet-wasm.ts +40 -0
  476. package/src/lib/wasm/load-wasm/index.ts +1 -0
  477. package/src/lib/wasm/load-wasm/load-wasm-browser.ts +15 -0
  478. package/src/lib/wasm/load-wasm/load-wasm-node.ts +5 -0
  479. package/src/lib/wasm/parse-parquet-wasm.ts +42 -0
  480. package/src/lib/wip/convert-schema-deep.java.disabled +910 -0
  481. package/src/lib/wip/convert-schema-deep.rs.disabled +976 -0
  482. package/src/parquet-loader.ts +30 -3
  483. package/src/parquet-wasm-loader.ts +36 -0
  484. package/src/parquet-wasm-writer.ts +24 -0
  485. package/src/parquet-writer.ts +4 -1
  486. package/src/parquetjs/compression.ts +24 -7
  487. package/src/parquetjs/encoder/{writer.ts → parquet-encoder.ts} +33 -38
  488. package/src/parquetjs/parser/decoders.ts +3 -3
  489. package/src/parquetjs/parser/parquet-reader.ts +239 -122
  490. package/src/parquetjs/schema/declare.ts +22 -13
  491. package/src/parquetjs/schema/schema.ts +8 -8
  492. package/src/parquetjs/schema/shred.ts +239 -71
  493. package/src/parquetjs/schema/types.ts +25 -30
  494. package/src/parquetjs/utils/file-utils.ts +3 -4
  495. package/dist/bundle.js.map +0 -1
  496. package/dist/constants.js.map +0 -1
  497. package/dist/index.js.map +0 -1
  498. package/dist/lib/convert-schema.d.ts +0 -8
  499. package/dist/lib/convert-schema.d.ts.map +0 -1
  500. package/dist/lib/convert-schema.js +0 -71
  501. package/dist/lib/convert-schema.js.map +0 -1
  502. package/dist/lib/parse-parquet.d.ts +0 -4
  503. package/dist/lib/parse-parquet.d.ts.map +0 -1
  504. package/dist/lib/parse-parquet.js +0 -28
  505. package/dist/lib/parse-parquet.js.map +0 -1
  506. package/dist/lib/read-array-buffer.d.ts +0 -19
  507. package/dist/lib/read-array-buffer.d.ts.map +0 -1
  508. package/dist/lib/read-array-buffer.js +0 -9
  509. package/dist/lib/read-array-buffer.js.map +0 -1
  510. package/dist/parquet-loader.js.map +0 -1
  511. package/dist/parquet-writer.js.map +0 -1
  512. package/dist/parquetjs/codecs/declare.js.map +0 -1
  513. package/dist/parquetjs/codecs/dictionary.js.map +0 -1
  514. package/dist/parquetjs/codecs/index.js.map +0 -1
  515. package/dist/parquetjs/codecs/plain.js.map +0 -1
  516. package/dist/parquetjs/codecs/rle.js.map +0 -1
  517. package/dist/parquetjs/compression.js.map +0 -1
  518. package/dist/parquetjs/encoder/writer.d.ts.map +0 -1
  519. package/dist/parquetjs/encoder/writer.js.map +0 -1
  520. package/dist/parquetjs/file.d.ts +0 -10
  521. package/dist/parquetjs/file.d.ts.map +0 -1
  522. package/dist/parquetjs/file.js +0 -80
  523. package/dist/parquetjs/file.js.map +0 -1
  524. package/dist/parquetjs/parquet-thrift/BoundaryOrder.js.map +0 -1
  525. package/dist/parquetjs/parquet-thrift/BsonType.js.map +0 -1
  526. package/dist/parquetjs/parquet-thrift/ColumnChunk.js.map +0 -1
  527. package/dist/parquetjs/parquet-thrift/ColumnIndex.js.map +0 -1
  528. package/dist/parquetjs/parquet-thrift/ColumnMetaData.js.map +0 -1
  529. package/dist/parquetjs/parquet-thrift/ColumnOrder.js.map +0 -1
  530. package/dist/parquetjs/parquet-thrift/CompressionCodec.js.map +0 -1
  531. package/dist/parquetjs/parquet-thrift/ConvertedType.js.map +0 -1
  532. package/dist/parquetjs/parquet-thrift/DataPageHeader.js.map +0 -1
  533. package/dist/parquetjs/parquet-thrift/DataPageHeaderV2.js.map +0 -1
  534. package/dist/parquetjs/parquet-thrift/DateType.js.map +0 -1
  535. package/dist/parquetjs/parquet-thrift/DecimalType.js.map +0 -1
  536. package/dist/parquetjs/parquet-thrift/DictionaryPageHeader.js.map +0 -1
  537. package/dist/parquetjs/parquet-thrift/Encoding.js.map +0 -1
  538. package/dist/parquetjs/parquet-thrift/EnumType.js.map +0 -1
  539. package/dist/parquetjs/parquet-thrift/FieldRepetitionType.js.map +0 -1
  540. package/dist/parquetjs/parquet-thrift/FileMetaData.js.map +0 -1
  541. package/dist/parquetjs/parquet-thrift/IndexPageHeader.js.map +0 -1
  542. package/dist/parquetjs/parquet-thrift/IntType.js.map +0 -1
  543. package/dist/parquetjs/parquet-thrift/JsonType.js.map +0 -1
  544. package/dist/parquetjs/parquet-thrift/KeyValue.js.map +0 -1
  545. package/dist/parquetjs/parquet-thrift/ListType.js.map +0 -1
  546. package/dist/parquetjs/parquet-thrift/LogicalType.js.map +0 -1
  547. package/dist/parquetjs/parquet-thrift/MapType.js.map +0 -1
  548. package/dist/parquetjs/parquet-thrift/MicroSeconds.js.map +0 -1
  549. package/dist/parquetjs/parquet-thrift/MilliSeconds.js.map +0 -1
  550. package/dist/parquetjs/parquet-thrift/NullType.js.map +0 -1
  551. package/dist/parquetjs/parquet-thrift/OffsetIndex.js.map +0 -1
  552. package/dist/parquetjs/parquet-thrift/PageEncodingStats.js.map +0 -1
  553. package/dist/parquetjs/parquet-thrift/PageHeader.js.map +0 -1
  554. package/dist/parquetjs/parquet-thrift/PageLocation.js.map +0 -1
  555. package/dist/parquetjs/parquet-thrift/PageType.js.map +0 -1
  556. package/dist/parquetjs/parquet-thrift/RowGroup.js.map +0 -1
  557. package/dist/parquetjs/parquet-thrift/SchemaElement.js.map +0 -1
  558. package/dist/parquetjs/parquet-thrift/SortingColumn.js.map +0 -1
  559. package/dist/parquetjs/parquet-thrift/Statistics.js.map +0 -1
  560. package/dist/parquetjs/parquet-thrift/StringType.js.map +0 -1
  561. package/dist/parquetjs/parquet-thrift/TimeType.js.map +0 -1
  562. package/dist/parquetjs/parquet-thrift/TimeUnit.js.map +0 -1
  563. package/dist/parquetjs/parquet-thrift/TimestampType.js.map +0 -1
  564. package/dist/parquetjs/parquet-thrift/Type.js.map +0 -1
  565. package/dist/parquetjs/parquet-thrift/TypeDefinedOrder.js.map +0 -1
  566. package/dist/parquetjs/parquet-thrift/UUIDType.js.map +0 -1
  567. package/dist/parquetjs/parquet-thrift/index.js.map +0 -1
  568. package/dist/parquetjs/parser/decoders.js.map +0 -1
  569. package/dist/parquetjs/parser/parquet-cursor.d.ts +0 -36
  570. package/dist/parquetjs/parser/parquet-cursor.d.ts.map +0 -1
  571. package/dist/parquetjs/parser/parquet-cursor.js +0 -90
  572. package/dist/parquetjs/parser/parquet-cursor.js.map +0 -1
  573. package/dist/parquetjs/parser/parquet-envelope-reader.d.ts +0 -40
  574. package/dist/parquetjs/parser/parquet-envelope-reader.d.ts.map +0 -1
  575. package/dist/parquetjs/parser/parquet-envelope-reader.js.map +0 -1
  576. package/dist/parquetjs/parser/parquet-reader.js.map +0 -1
  577. package/dist/parquetjs/schema/declare.js.map +0 -1
  578. package/dist/parquetjs/schema/schema.js.map +0 -1
  579. package/dist/parquetjs/schema/shred.js.map +0 -1
  580. package/dist/parquetjs/schema/types.js.map +0 -1
  581. package/dist/parquetjs/utils/buffer-utils.d.ts +0 -10
  582. package/dist/parquetjs/utils/buffer-utils.d.ts.map +0 -1
  583. package/dist/parquetjs/utils/buffer-utils.js +0 -12
  584. package/dist/parquetjs/utils/buffer-utils.js.map +0 -1
  585. package/dist/parquetjs/utils/file-utils.js.map +0 -1
  586. package/dist/parquetjs/utils/read-utils.js.map +0 -1
  587. package/dist/workers/parquet-worker.js.map +0 -1
  588. package/src/lib/convert-schema.ts +0 -95
  589. package/src/lib/parse-parquet.ts +0 -27
  590. package/src/lib/read-array-buffer.ts +0 -31
  591. package/src/parquetjs/file.ts +0 -90
  592. package/src/parquetjs/parser/parquet-cursor.ts +0 -94
  593. package/src/parquetjs/parser/parquet-envelope-reader.ts +0 -199
  594. package/src/parquetjs/utils/buffer-utils.ts +0 -18
  595. /package/dist/{parquetjs → es5/parquetjs}/LICENSE +0 -0
  596. /package/dist/{parquetjs → es5/parquetjs}/modules.d.ts +0 -0
@@ -1,429 +1,402 @@
1
- import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
- import Int64 from 'node-int64';
3
- import * as thrift from 'thrift';
4
- import * as KeyValue from './KeyValue';
5
- import * as PageEncodingStats from './PageEncodingStats';
6
- import * as Statistics from './Statistics';
7
- export class ColumnMetaData {
8
- constructor(args) {
9
- _defineProperty(this, "type", void 0);
10
-
11
- _defineProperty(this, "encodings", void 0);
12
-
13
- _defineProperty(this, "path_in_schema", void 0);
14
-
15
- _defineProperty(this, "codec", void 0);
16
-
17
- _defineProperty(this, "num_values", void 0);
18
-
19
- _defineProperty(this, "total_uncompressed_size", void 0);
20
-
21
- _defineProperty(this, "total_compressed_size", void 0);
22
-
23
- _defineProperty(this, "key_value_metadata", void 0);
24
-
25
- _defineProperty(this, "data_page_offset", void 0);
26
-
27
- _defineProperty(this, "index_page_offset", void 0);
28
-
29
- _defineProperty(this, "dictionary_page_offset", void 0);
30
-
31
- _defineProperty(this, "statistics", void 0);
32
-
33
- _defineProperty(this, "encoding_stats", void 0);
34
-
35
- if (args != null && args.type != null) {
36
- this.type = args.type;
37
- } else {
38
- throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[type] is unset!');
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
39
7
  }
40
-
41
- if (args != null && args.encodings != null) {
42
- this.encodings = args.encodings;
43
- } else {
44
- throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[encodings] is unset!');
45
- }
46
-
47
- if (args != null && args.path_in_schema != null) {
48
- this.path_in_schema = args.path_in_schema;
49
- } else {
50
- throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[path_in_schema] is unset!');
51
- }
52
-
53
- if (args != null && args.codec != null) {
54
- this.codec = args.codec;
55
- } else {
56
- throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[codec] is unset!');
57
- }
58
-
59
- if (args != null && args.num_values != null) {
60
- if (typeof args.num_values === 'number') {
61
- this.num_values = new Int64(args.num_values);
62
- } else {
63
- this.num_values = args.num_values;
64
- }
65
- } else {
66
- throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[num_values] is unset!');
67
- }
68
-
69
- if (args != null && args.total_uncompressed_size != null) {
70
- if (typeof args.total_uncompressed_size === 'number') {
71
- this.total_uncompressed_size = new Int64(args.total_uncompressed_size);
72
- } else {
73
- this.total_uncompressed_size = args.total_uncompressed_size;
74
- }
75
- } else {
76
- throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[total_uncompressed_size] is unset!');
77
- }
78
-
79
- if (args != null && args.total_compressed_size != null) {
80
- if (typeof args.total_compressed_size === 'number') {
81
- this.total_compressed_size = new Int64(args.total_compressed_size);
82
- } else {
83
- this.total_compressed_size = args.total_compressed_size;
84
- }
85
- } else {
86
- throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[total_compressed_size] is unset!');
87
- }
88
-
89
- if (args != null && args.key_value_metadata != null) {
90
- this.key_value_metadata = args.key_value_metadata;
91
- }
92
-
93
- if (args != null && args.data_page_offset != null) {
94
- if (typeof args.data_page_offset === 'number') {
95
- this.data_page_offset = new Int64(args.data_page_offset);
96
- } else {
97
- this.data_page_offset = args.data_page_offset;
98
- }
99
- } else {
100
- throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[data_page_offset] is unset!');
101
- }
102
-
103
- if (args != null && args.index_page_offset != null) {
104
- if (typeof args.index_page_offset === 'number') {
105
- this.index_page_offset = new Int64(args.index_page_offset);
106
- } else {
107
- this.index_page_offset = args.index_page_offset;
108
- }
109
- }
110
-
111
- if (args != null && args.dictionary_page_offset != null) {
112
- if (typeof args.dictionary_page_offset === 'number') {
113
- this.dictionary_page_offset = new Int64(args.dictionary_page_offset);
114
- } else {
115
- this.dictionary_page_offset = args.dictionary_page_offset;
116
- }
117
- }
118
-
119
- if (args != null && args.statistics != null) {
120
- this.statistics = args.statistics;
121
- }
122
-
123
- if (args != null && args.encoding_stats != null) {
124
- this.encoding_stats = args.encoding_stats;
125
- }
126
- }
127
-
128
- write(output) {
129
- output.writeStructBegin('ColumnMetaData');
130
-
131
- if (this.type != null) {
132
- output.writeFieldBegin('type', thrift.Thrift.Type.I32, 1);
133
- output.writeI32(this.type);
134
- output.writeFieldEnd();
135
- }
136
-
137
- if (this.encodings != null) {
138
- output.writeFieldBegin('encodings', thrift.Thrift.Type.LIST, 2);
139
- output.writeListBegin(thrift.Thrift.Type.I32, this.encodings.length);
140
- this.encodings.forEach(value_1 => {
141
- output.writeI32(value_1);
142
- });
143
- output.writeListEnd();
144
- output.writeFieldEnd();
145
- }
146
-
147
- if (this.path_in_schema != null) {
148
- output.writeFieldBegin('path_in_schema', thrift.Thrift.Type.LIST, 3);
149
- output.writeListBegin(thrift.Thrift.Type.STRING, this.path_in_schema.length);
150
- this.path_in_schema.forEach(value_2 => {
151
- output.writeString(value_2);
152
- });
153
- output.writeListEnd();
154
- output.writeFieldEnd();
155
- }
156
-
157
- if (this.codec != null) {
158
- output.writeFieldBegin('codec', thrift.Thrift.Type.I32, 4);
159
- output.writeI32(this.codec);
160
- output.writeFieldEnd();
161
- }
162
-
163
- if (this.num_values != null) {
164
- output.writeFieldBegin('num_values', thrift.Thrift.Type.I64, 5);
165
- output.writeI64(this.num_values);
166
- output.writeFieldEnd();
167
- }
168
-
169
- if (this.total_uncompressed_size != null) {
170
- output.writeFieldBegin('total_uncompressed_size', thrift.Thrift.Type.I64, 6);
171
- output.writeI64(this.total_uncompressed_size);
172
- output.writeFieldEnd();
173
- }
174
-
175
- if (this.total_compressed_size != null) {
176
- output.writeFieldBegin('total_compressed_size', thrift.Thrift.Type.I64, 7);
177
- output.writeI64(this.total_compressed_size);
178
- output.writeFieldEnd();
179
- }
180
-
181
- if (this.key_value_metadata != null) {
182
- output.writeFieldBegin('key_value_metadata', thrift.Thrift.Type.LIST, 8);
183
- output.writeListBegin(thrift.Thrift.Type.STRUCT, this.key_value_metadata.length);
184
- this.key_value_metadata.forEach(value_3 => {
185
- value_3.write(output);
186
- });
187
- output.writeListEnd();
188
- output.writeFieldEnd();
189
- }
190
-
191
- if (this.data_page_offset != null) {
192
- output.writeFieldBegin('data_page_offset', thrift.Thrift.Type.I64, 9);
193
- output.writeI64(this.data_page_offset);
194
- output.writeFieldEnd();
195
- }
196
-
197
- if (this.index_page_offset != null) {
198
- output.writeFieldBegin('index_page_offset', thrift.Thrift.Type.I64, 10);
199
- output.writeI64(this.index_page_offset);
200
- output.writeFieldEnd();
201
- }
202
-
203
- if (this.dictionary_page_offset != null) {
204
- output.writeFieldBegin('dictionary_page_offset', thrift.Thrift.Type.I64, 11);
205
- output.writeI64(this.dictionary_page_offset);
206
- output.writeFieldEnd();
207
- }
208
-
209
- if (this.statistics != null) {
210
- output.writeFieldBegin('statistics', thrift.Thrift.Type.STRUCT, 12);
211
- this.statistics.write(output);
212
- output.writeFieldEnd();
213
- }
214
-
215
- if (this.encoding_stats != null) {
216
- output.writeFieldBegin('encoding_stats', thrift.Thrift.Type.LIST, 13);
217
- output.writeListBegin(thrift.Thrift.Type.STRUCT, this.encoding_stats.length);
218
- this.encoding_stats.forEach(value_4 => {
219
- value_4.write(output);
220
- });
221
- output.writeListEnd();
222
- output.writeFieldEnd();
223
- }
224
-
225
- output.writeFieldStop();
226
- output.writeStructEnd();
227
- return;
228
- }
229
-
230
- static read(input) {
231
- input.readStructBegin();
232
- let _args = {};
233
-
234
- while (true) {
235
- const ret = input.readFieldBegin();
236
- const fieldType = ret.ftype;
237
- const fieldId = ret.fid;
238
-
239
- if (fieldType === thrift.Thrift.Type.STOP) {
240
- break;
241
- }
242
-
243
- switch (fieldId) {
244
- case 1:
245
- if (fieldType === thrift.Thrift.Type.I32) {
246
- const value_5 = input.readI32();
247
- _args.type = value_5;
248
- } else {
249
- input.skip(fieldType);
250
- }
251
-
252
- break;
253
-
254
- case 2:
255
- if (fieldType === thrift.Thrift.Type.LIST) {
256
- const value_6 = new Array();
257
- const metadata_1 = input.readListBegin();
258
- const size_1 = metadata_1.size;
259
-
260
- for (let i_1 = 0; i_1 < size_1; i_1++) {
261
- const value_7 = input.readI32();
262
- value_6.push(value_7);
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || function (mod) {
19
+ if (mod && mod.__esModule) return mod;
20
+ var result = {};
21
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
+ __setModuleDefault(result, mod);
23
+ return result;
24
+ };
25
+ var __importDefault = (this && this.__importDefault) || function (mod) {
26
+ return (mod && mod.__esModule) ? mod : { "default": mod };
27
+ };
28
+ Object.defineProperty(exports, "__esModule", { value: true });
29
+ exports.ColumnMetaData = void 0;
30
+ /* tslint:disable */
31
+ /* eslint-disable */
32
+ /*
33
+ * Autogenerated by @creditkarma/thrift-typescript v3.7.2
34
+ * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
35
+ */
36
+ const node_int64_1 = __importDefault(require("node-int64"));
37
+ const thrift = __importStar(require("thrift"));
38
+ const KeyValue = __importStar(require("./KeyValue"));
39
+ const PageEncodingStats = __importStar(require("./PageEncodingStats"));
40
+ const Statistics = __importStar(require("./Statistics"));
41
+ class ColumnMetaData {
42
+ constructor(args) {
43
+ if (args != null && args.type != null) {
44
+ this.type = args.type;
45
+ }
46
+ else {
47
+ throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[type] is unset!');
48
+ }
49
+ if (args != null && args.encodings != null) {
50
+ this.encodings = args.encodings;
51
+ }
52
+ else {
53
+ throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[encodings] is unset!');
54
+ }
55
+ if (args != null && args.path_in_schema != null) {
56
+ this.path_in_schema = args.path_in_schema;
57
+ }
58
+ else {
59
+ throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[path_in_schema] is unset!');
60
+ }
61
+ if (args != null && args.codec != null) {
62
+ this.codec = args.codec;
63
+ }
64
+ else {
65
+ throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[codec] is unset!');
66
+ }
67
+ if (args != null && args.num_values != null) {
68
+ if (typeof args.num_values === 'number') {
69
+ this.num_values = new node_int64_1.default(args.num_values);
70
+ }
71
+ else {
72
+ this.num_values = args.num_values;
73
+ }
74
+ }
75
+ else {
76
+ throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[num_values] is unset!');
77
+ }
78
+ if (args != null && args.total_uncompressed_size != null) {
79
+ if (typeof args.total_uncompressed_size === 'number') {
80
+ this.total_uncompressed_size = new node_int64_1.default(args.total_uncompressed_size);
263
81
  }
264
-
265
- input.readListEnd();
266
- _args.encodings = value_6;
267
- } else {
268
- input.skip(fieldType);
269
- }
270
-
271
- break;
272
-
273
- case 3:
274
- if (fieldType === thrift.Thrift.Type.LIST) {
275
- const value_8 = new Array();
276
- const metadata_2 = input.readListBegin();
277
- const size_2 = metadata_2.size;
278
-
279
- for (let i_2 = 0; i_2 < size_2; i_2++) {
280
- const value_9 = input.readString();
281
- value_8.push(value_9);
82
+ else {
83
+ this.total_uncompressed_size = args.total_uncompressed_size;
282
84
  }
283
-
284
- input.readListEnd();
285
- _args.path_in_schema = value_8;
286
- } else {
287
- input.skip(fieldType);
288
- }
289
-
290
- break;
291
-
292
- case 4:
293
- if (fieldType === thrift.Thrift.Type.I32) {
294
- const value_10 = input.readI32();
295
- _args.codec = value_10;
296
- } else {
297
- input.skip(fieldType);
298
- }
299
-
300
- break;
301
-
302
- case 5:
303
- if (fieldType === thrift.Thrift.Type.I64) {
304
- const value_11 = input.readI64();
305
- _args.num_values = value_11;
306
- } else {
307
- input.skip(fieldType);
308
- }
309
-
310
- break;
311
-
312
- case 6:
313
- if (fieldType === thrift.Thrift.Type.I64) {
314
- const value_12 = input.readI64();
315
- _args.total_uncompressed_size = value_12;
316
- } else {
317
- input.skip(fieldType);
318
- }
319
-
320
- break;
321
-
322
- case 7:
323
- if (fieldType === thrift.Thrift.Type.I64) {
324
- const value_13 = input.readI64();
325
- _args.total_compressed_size = value_13;
326
- } else {
327
- input.skip(fieldType);
328
- }
329
-
330
- break;
331
-
332
- case 8:
333
- if (fieldType === thrift.Thrift.Type.LIST) {
334
- const value_14 = new Array();
335
- const metadata_3 = input.readListBegin();
336
- const size_3 = metadata_3.size;
337
-
338
- for (let i_3 = 0; i_3 < size_3; i_3++) {
339
- const value_15 = KeyValue.KeyValue.read(input);
340
- value_14.push(value_15);
85
+ }
86
+ else {
87
+ throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[total_uncompressed_size] is unset!');
88
+ }
89
+ if (args != null && args.total_compressed_size != null) {
90
+ if (typeof args.total_compressed_size === 'number') {
91
+ this.total_compressed_size = new node_int64_1.default(args.total_compressed_size);
341
92
  }
342
-
343
- input.readListEnd();
344
- _args.key_value_metadata = value_14;
345
- } else {
346
- input.skip(fieldType);
347
- }
348
-
349
- break;
350
-
351
- case 9:
352
- if (fieldType === thrift.Thrift.Type.I64) {
353
- const value_16 = input.readI64();
354
- _args.data_page_offset = value_16;
355
- } else {
356
- input.skip(fieldType);
357
- }
358
-
359
- break;
360
-
361
- case 10:
362
- if (fieldType === thrift.Thrift.Type.I64) {
363
- const value_17 = input.readI64();
364
- _args.index_page_offset = value_17;
365
- } else {
366
- input.skip(fieldType);
367
- }
368
-
369
- break;
370
-
371
- case 11:
372
- if (fieldType === thrift.Thrift.Type.I64) {
373
- const value_18 = input.readI64();
374
- _args.dictionary_page_offset = value_18;
375
- } else {
376
- input.skip(fieldType);
377
- }
378
-
379
- break;
380
-
381
- case 12:
382
- if (fieldType === thrift.Thrift.Type.STRUCT) {
383
- const value_19 = Statistics.Statistics.read(input);
384
- _args.statistics = value_19;
385
- } else {
386
- input.skip(fieldType);
387
- }
388
-
389
- break;
390
-
391
- case 13:
392
- if (fieldType === thrift.Thrift.Type.LIST) {
393
- const value_20 = new Array();
394
- const metadata_4 = input.readListBegin();
395
- const size_4 = metadata_4.size;
396
-
397
- for (let i_4 = 0; i_4 < size_4; i_4++) {
398
- const value_21 = PageEncodingStats.PageEncodingStats.read(input);
399
- value_20.push(value_21);
93
+ else {
94
+ this.total_compressed_size = args.total_compressed_size;
400
95
  }
401
-
402
- input.readListEnd();
403
- _args.encoding_stats = value_20;
404
- } else {
405
- input.skip(fieldType);
406
- }
407
-
408
- break;
409
-
410
- default:
411
- {
412
- input.skip(fieldType);
413
- }
414
- }
415
-
416
- input.readFieldEnd();
96
+ }
97
+ else {
98
+ throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[total_compressed_size] is unset!');
99
+ }
100
+ if (args != null && args.key_value_metadata != null) {
101
+ this.key_value_metadata = args.key_value_metadata;
102
+ }
103
+ if (args != null && args.data_page_offset != null) {
104
+ if (typeof args.data_page_offset === 'number') {
105
+ this.data_page_offset = new node_int64_1.default(args.data_page_offset);
106
+ }
107
+ else {
108
+ this.data_page_offset = args.data_page_offset;
109
+ }
110
+ }
111
+ else {
112
+ throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Required field[data_page_offset] is unset!');
113
+ }
114
+ if (args != null && args.index_page_offset != null) {
115
+ if (typeof args.index_page_offset === 'number') {
116
+ this.index_page_offset = new node_int64_1.default(args.index_page_offset);
117
+ }
118
+ else {
119
+ this.index_page_offset = args.index_page_offset;
120
+ }
121
+ }
122
+ if (args != null && args.dictionary_page_offset != null) {
123
+ if (typeof args.dictionary_page_offset === 'number') {
124
+ this.dictionary_page_offset = new node_int64_1.default(args.dictionary_page_offset);
125
+ }
126
+ else {
127
+ this.dictionary_page_offset = args.dictionary_page_offset;
128
+ }
129
+ }
130
+ if (args != null && args.statistics != null) {
131
+ this.statistics = args.statistics;
132
+ }
133
+ if (args != null && args.encoding_stats != null) {
134
+ this.encoding_stats = args.encoding_stats;
135
+ }
136
+ }
137
+ write(output) {
138
+ output.writeStructBegin('ColumnMetaData');
139
+ if (this.type != null) {
140
+ output.writeFieldBegin('type', thrift.Thrift.Type.I32, 1);
141
+ output.writeI32(this.type);
142
+ output.writeFieldEnd();
143
+ }
144
+ if (this.encodings != null) {
145
+ output.writeFieldBegin('encodings', thrift.Thrift.Type.LIST, 2);
146
+ output.writeListBegin(thrift.Thrift.Type.I32, this.encodings.length);
147
+ this.encodings.forEach((value_1) => {
148
+ output.writeI32(value_1);
149
+ });
150
+ output.writeListEnd();
151
+ output.writeFieldEnd();
152
+ }
153
+ if (this.path_in_schema != null) {
154
+ output.writeFieldBegin('path_in_schema', thrift.Thrift.Type.LIST, 3);
155
+ output.writeListBegin(thrift.Thrift.Type.STRING, this.path_in_schema.length);
156
+ this.path_in_schema.forEach((value_2) => {
157
+ output.writeString(value_2);
158
+ });
159
+ output.writeListEnd();
160
+ output.writeFieldEnd();
161
+ }
162
+ if (this.codec != null) {
163
+ output.writeFieldBegin('codec', thrift.Thrift.Type.I32, 4);
164
+ output.writeI32(this.codec);
165
+ output.writeFieldEnd();
166
+ }
167
+ if (this.num_values != null) {
168
+ output.writeFieldBegin('num_values', thrift.Thrift.Type.I64, 5);
169
+ output.writeI64(this.num_values);
170
+ output.writeFieldEnd();
171
+ }
172
+ if (this.total_uncompressed_size != null) {
173
+ output.writeFieldBegin('total_uncompressed_size', thrift.Thrift.Type.I64, 6);
174
+ output.writeI64(this.total_uncompressed_size);
175
+ output.writeFieldEnd();
176
+ }
177
+ if (this.total_compressed_size != null) {
178
+ output.writeFieldBegin('total_compressed_size', thrift.Thrift.Type.I64, 7);
179
+ output.writeI64(this.total_compressed_size);
180
+ output.writeFieldEnd();
181
+ }
182
+ if (this.key_value_metadata != null) {
183
+ output.writeFieldBegin('key_value_metadata', thrift.Thrift.Type.LIST, 8);
184
+ output.writeListBegin(thrift.Thrift.Type.STRUCT, this.key_value_metadata.length);
185
+ this.key_value_metadata.forEach((value_3) => {
186
+ value_3.write(output);
187
+ });
188
+ output.writeListEnd();
189
+ output.writeFieldEnd();
190
+ }
191
+ if (this.data_page_offset != null) {
192
+ output.writeFieldBegin('data_page_offset', thrift.Thrift.Type.I64, 9);
193
+ output.writeI64(this.data_page_offset);
194
+ output.writeFieldEnd();
195
+ }
196
+ if (this.index_page_offset != null) {
197
+ output.writeFieldBegin('index_page_offset', thrift.Thrift.Type.I64, 10);
198
+ output.writeI64(this.index_page_offset);
199
+ output.writeFieldEnd();
200
+ }
201
+ if (this.dictionary_page_offset != null) {
202
+ output.writeFieldBegin('dictionary_page_offset', thrift.Thrift.Type.I64, 11);
203
+ output.writeI64(this.dictionary_page_offset);
204
+ output.writeFieldEnd();
205
+ }
206
+ if (this.statistics != null) {
207
+ output.writeFieldBegin('statistics', thrift.Thrift.Type.STRUCT, 12);
208
+ this.statistics.write(output);
209
+ output.writeFieldEnd();
210
+ }
211
+ if (this.encoding_stats != null) {
212
+ output.writeFieldBegin('encoding_stats', thrift.Thrift.Type.LIST, 13);
213
+ output.writeListBegin(thrift.Thrift.Type.STRUCT, this.encoding_stats.length);
214
+ this.encoding_stats.forEach((value_4) => {
215
+ value_4.write(output);
216
+ });
217
+ output.writeListEnd();
218
+ output.writeFieldEnd();
219
+ }
220
+ output.writeFieldStop();
221
+ output.writeStructEnd();
222
+ return;
417
223
  }
418
-
419
- input.readStructEnd();
420
-
421
- if (_args.type !== undefined && _args.encodings !== undefined && _args.path_in_schema !== undefined && _args.codec !== undefined && _args.num_values !== undefined && _args.total_uncompressed_size !== undefined && _args.total_compressed_size !== undefined && _args.data_page_offset !== undefined) {
422
- return new ColumnMetaData(_args);
423
- } else {
424
- throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Unable to read ColumnMetaData from input');
224
+ static read(input) {
225
+ input.readStructBegin();
226
+ let _args = {};
227
+ while (true) {
228
+ const ret = input.readFieldBegin();
229
+ const fieldType = ret.ftype;
230
+ const fieldId = ret.fid;
231
+ if (fieldType === thrift.Thrift.Type.STOP) {
232
+ break;
233
+ }
234
+ switch (fieldId) {
235
+ case 1:
236
+ if (fieldType === thrift.Thrift.Type.I32) {
237
+ const value_5 = input.readI32();
238
+ _args.type = value_5;
239
+ }
240
+ else {
241
+ input.skip(fieldType);
242
+ }
243
+ break;
244
+ case 2:
245
+ if (fieldType === thrift.Thrift.Type.LIST) {
246
+ const value_6 = new Array();
247
+ const metadata_1 = input.readListBegin();
248
+ const size_1 = metadata_1.size;
249
+ for (let i_1 = 0; i_1 < size_1; i_1++) {
250
+ const value_7 = input.readI32();
251
+ value_6.push(value_7);
252
+ }
253
+ input.readListEnd();
254
+ _args.encodings = value_6;
255
+ }
256
+ else {
257
+ input.skip(fieldType);
258
+ }
259
+ break;
260
+ case 3:
261
+ if (fieldType === thrift.Thrift.Type.LIST) {
262
+ const value_8 = new Array();
263
+ const metadata_2 = input.readListBegin();
264
+ const size_2 = metadata_2.size;
265
+ for (let i_2 = 0; i_2 < size_2; i_2++) {
266
+ const value_9 = input.readString();
267
+ value_8.push(value_9);
268
+ }
269
+ input.readListEnd();
270
+ _args.path_in_schema = value_8;
271
+ }
272
+ else {
273
+ input.skip(fieldType);
274
+ }
275
+ break;
276
+ case 4:
277
+ if (fieldType === thrift.Thrift.Type.I32) {
278
+ const value_10 = input.readI32();
279
+ _args.codec = value_10;
280
+ }
281
+ else {
282
+ input.skip(fieldType);
283
+ }
284
+ break;
285
+ case 5:
286
+ if (fieldType === thrift.Thrift.Type.I64) {
287
+ const value_11 = input.readI64();
288
+ _args.num_values = value_11;
289
+ }
290
+ else {
291
+ input.skip(fieldType);
292
+ }
293
+ break;
294
+ case 6:
295
+ if (fieldType === thrift.Thrift.Type.I64) {
296
+ const value_12 = input.readI64();
297
+ _args.total_uncompressed_size = value_12;
298
+ }
299
+ else {
300
+ input.skip(fieldType);
301
+ }
302
+ break;
303
+ case 7:
304
+ if (fieldType === thrift.Thrift.Type.I64) {
305
+ const value_13 = input.readI64();
306
+ _args.total_compressed_size = value_13;
307
+ }
308
+ else {
309
+ input.skip(fieldType);
310
+ }
311
+ break;
312
+ case 8:
313
+ if (fieldType === thrift.Thrift.Type.LIST) {
314
+ const value_14 = new Array();
315
+ const metadata_3 = input.readListBegin();
316
+ const size_3 = metadata_3.size;
317
+ for (let i_3 = 0; i_3 < size_3; i_3++) {
318
+ const value_15 = KeyValue.KeyValue.read(input);
319
+ value_14.push(value_15);
320
+ }
321
+ input.readListEnd();
322
+ _args.key_value_metadata = value_14;
323
+ }
324
+ else {
325
+ input.skip(fieldType);
326
+ }
327
+ break;
328
+ case 9:
329
+ if (fieldType === thrift.Thrift.Type.I64) {
330
+ const value_16 = input.readI64();
331
+ _args.data_page_offset = value_16;
332
+ }
333
+ else {
334
+ input.skip(fieldType);
335
+ }
336
+ break;
337
+ case 10:
338
+ if (fieldType === thrift.Thrift.Type.I64) {
339
+ const value_17 = input.readI64();
340
+ _args.index_page_offset = value_17;
341
+ }
342
+ else {
343
+ input.skip(fieldType);
344
+ }
345
+ break;
346
+ case 11:
347
+ if (fieldType === thrift.Thrift.Type.I64) {
348
+ const value_18 = input.readI64();
349
+ _args.dictionary_page_offset = value_18;
350
+ }
351
+ else {
352
+ input.skip(fieldType);
353
+ }
354
+ break;
355
+ case 12:
356
+ if (fieldType === thrift.Thrift.Type.STRUCT) {
357
+ const value_19 = Statistics.Statistics.read(input);
358
+ _args.statistics = value_19;
359
+ }
360
+ else {
361
+ input.skip(fieldType);
362
+ }
363
+ break;
364
+ case 13:
365
+ if (fieldType === thrift.Thrift.Type.LIST) {
366
+ const value_20 = new Array();
367
+ const metadata_4 = input.readListBegin();
368
+ const size_4 = metadata_4.size;
369
+ for (let i_4 = 0; i_4 < size_4; i_4++) {
370
+ const value_21 = PageEncodingStats.PageEncodingStats.read(input);
371
+ value_20.push(value_21);
372
+ }
373
+ input.readListEnd();
374
+ _args.encoding_stats = value_20;
375
+ }
376
+ else {
377
+ input.skip(fieldType);
378
+ }
379
+ break;
380
+ default: {
381
+ input.skip(fieldType);
382
+ }
383
+ }
384
+ input.readFieldEnd();
385
+ }
386
+ input.readStructEnd();
387
+ if (_args.type !== undefined &&
388
+ _args.encodings !== undefined &&
389
+ _args.path_in_schema !== undefined &&
390
+ _args.codec !== undefined &&
391
+ _args.num_values !== undefined &&
392
+ _args.total_uncompressed_size !== undefined &&
393
+ _args.total_compressed_size !== undefined &&
394
+ _args.data_page_offset !== undefined) {
395
+ return new ColumnMetaData(_args);
396
+ }
397
+ else {
398
+ throw new thrift.Thrift.TProtocolException(thrift.Thrift.TProtocolExceptionType.UNKNOWN, 'Unable to read ColumnMetaData from input');
399
+ }
425
400
  }
426
- }
427
-
428
401
  }
429
- //# sourceMappingURL=ColumnMetaData.js.map
402
+ exports.ColumnMetaData = ColumnMetaData;