@botejs/core 0.7.0 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -7,4 +7,4 @@ export { type Source, type Reader, type ReadResult, type ForwardSource, type Fac
7
7
  export { fromFile, fromBuffer, fromHttpRange, type HttpRangeOptions } from './source/seekable.ts';
8
8
  export { fromReadable, fromHttpRequest, type ReadableOptions, type ReadableProducer, type HttpRequestOptions, } from './source/forward.ts';
9
9
  export { type IterStream } from './stream.ts';
10
- export { open, type OpenOptions, type ForwardOpenOptions } from './open.ts';
10
+ export { open, type SeekableOpenOptions } from './open.ts';
package/dist/open.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import { type RootCursor } from './cursor.ts';
2
2
  import type { SeekableSource, ForwardSource } from './source/base.ts';
3
3
  export declare const DEFAULT_SOURCE_CHUNK_BYTES: number;
4
- export interface OpenOptions {
4
+ export interface SeekableOpenOptions {
5
5
  /**
6
6
  * How much of the index that speeds up repeat lookups to keep in memory,
7
7
  * measured in entries. Higher means faster repeat queries but more memory;
@@ -24,14 +24,6 @@ export interface OpenOptions {
24
24
  */
25
25
  arrayIndexInterval?: number;
26
26
  }
27
- /**
28
- * Options for a forward source: every cache knob is forbidden (the structural-index
29
- * cache is forced off). `Omit` would collapse to `{}` and silently permit them, so
30
- * the knobs are mapped to `never` to reject them at compile time.
31
- */
32
- export type ForwardOpenOptions = {
33
- [K in keyof OpenOptions]?: never;
34
- };
35
27
  /**
36
28
  * Open a cursor over a source.
37
29
  *
@@ -43,5 +35,5 @@ export type ForwardOpenOptions = {
43
35
  * The returned `RootCursor` owns the reader: `close()` (or `await using`) drives
44
36
  * the reader's own `close()` exactly once.
45
37
  */
46
- export declare function open(source: SeekableSource, options?: OpenOptions): Promise<RootCursor>;
47
- export declare function open(source: ForwardSource, options?: ForwardOpenOptions): Promise<RootCursor>;
38
+ export declare function open(source: SeekableSource, options?: SeekableOpenOptions): Promise<RootCursor>;
39
+ export declare function open(source: ForwardSource): Promise<RootCursor>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@botejs/core",
3
- "version": "0.7.0",
3
+ "version": "0.8.0",
4
4
  "type": "module",
5
5
  "license": "MIT",
6
6
  "repository": {