@cobol-ts/cursor-loader-cobol-node 0.0.0-stage → 0.0.57

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/README.md CHANGED
@@ -1,3 +1,3 @@
1
- # Temporary Holding Version
2
-
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
1
+ # @cobol-ts/cursor-loader-cobol-node
2
+
3
+ COBOL native acquisition. The portable package owns codecs, parsing and record processing. Native tests exercise real files.
@@ -0,0 +1 @@
1
+ export * from './src/cobol.file.node';
package/dist/index.js ADDED
@@ -0,0 +1,18 @@
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]; } };
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 __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./src/cobol.file.node"), exports);
18
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,wDAAqC"}
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,44 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const promises_1 = require("node:fs/promises");
4
+ const node_os_1 = require("node:os");
5
+ const node_path_1 = require("node:path");
6
+ const cursor_file_1 = require("@cobol-ts/cursor-file");
7
+ const cursor_projection_1 = require("@cobol-ts/cursor-projection");
8
+ const errors_1 = require("@cobol-ts/errors");
9
+ const cursor_loader_cobol_1 = require("@cobol-ts/cursor-loader-cobol");
10
+ const copybook_1 = require("@cobol-ts/copybook");
11
+ const layout_1 = require("@cobol-ts/layout");
12
+ const layout = (0, errors_1.valueOrThrow)((0, layout_1.compileCobolLayout)((0, errors_1.valueOrThrow)((0, copybook_1.parseCopybook)('01 CUSTOMER.\n 05 CUSTOMER-ID PIC 9(4).\n 05 CUSTOMER-NAME PIC X(10).\n 05 STATUS PIC X.')), 'customer-simple.cpy'));
13
+ const bytes = Uint8Array.from('F0 F0 F0 F1 C1 D3 C9 C3 C5 40 40 40 40 40 C1 F0 F0 F4 F2 C2 D6 C2 40 40 40 40 40 40 40 C9'.split(' ').map(x => parseInt(x, 16)));
14
+ test('opens a genuine fixed-block binary file and reads all rows from the filesystem', async () => {
15
+ const directory = await (0, promises_1.mkdtemp)((0, node_path_1.join)((0, node_os_1.tmpdir)(), 'cobol-decoder-'));
16
+ const filename = (0, node_path_1.join)(directory, 'customers.fb');
17
+ const fixture = bytes;
18
+ await (0, promises_1.writeFile)(filename, fixture);
19
+ const handle = await (0, promises_1.open)(filename, 'r');
20
+ try {
21
+ const projection = (0, cursor_projection_1.defineProjection)({
22
+ id: { type: 'integer', path: ['CUSTOMER', 'CUSTOMER-ID'] },
23
+ name: { type: 'string', path: ['CUSTOMER', 'CUSTOMER-NAME'] }
24
+ });
25
+ const details = (0, errors_1.valueOrThrow)((0, cursor_loader_cobol_1.createCobolDecodedFixedDetails)(layout));
26
+ const cursor = (0, cursor_file_1.createFileCursor)({ filename, fileType: 'cobol', projection }, { handle }, { parsers: { cobol: { parser: cursor_loader_cobol_1.cobolParser, parserConfig: () => details,
27
+ createRecordState: cursor_loader_cobol_1.createCobolRecordState, cleanRecordState: cursor_loader_cobol_1.cleanCobolRecordState } },
28
+ bufferSize: 4, fillFileBuffer: async (source, destination) => (await source.handle.read(destination, 0, destination.length, null)).bytesRead
29
+ });
30
+ const values = [];
31
+ for await (const record of cursor) {
32
+ if (Array.isArray(record))
33
+ throw new Error(`COBOL row failure: ${record.join(', ')}`);
34
+ values.push({ id: record.result.id(), name: record.result.name() });
35
+ record.close();
36
+ }
37
+ expect(values).toEqual([{ id: 1, name: 'ALICE ' }, { id: 42, name: 'BOB ' }]);
38
+ }
39
+ finally {
40
+ await handle.close();
41
+ await (0, promises_1.rm)(directory, { recursive: true, force: true });
42
+ }
43
+ });
44
+ //# sourceMappingURL=cobol.decoded.file.spec.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cobol.decoded.file.spec.js","sourceRoot":"","sources":["../../src/cobol.decoded.file.spec.ts"],"names":[],"mappings":";;AAAA,+CAA8D;AAC9D,qCAA+B;AAC/B,yCAA+B;AAC/B,uDAAuD;AACvD,mEAA6D;AAC7D,6CAA8C;AAC9C,uEAAsI;AACtI,iDAAiD;AACjD,6CAAoD;AACpD,MAAM,MAAM,GAAC,IAAA,qBAAY,EAAC,IAAA,2BAAkB,EAAC,IAAA,qBAAY,EAAC,IAAA,wBAAa,EAAC,0FAA0F,CAAC,CAAC,EAAE,qBAAqB,CAAC,CAAC,CAAC;AAC9L,MAAM,KAAK,GAAC,UAAU,CAAC,IAAI,CAAC,2FAA2F,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,CAAA,EAAE,CAAA,QAAQ,CAAC,CAAC,EAAC,EAAE,CAAC,CAAC,CAAC,CAAC;AAE3J,IAAI,CAAC,gFAAgF,EAAC,KAAK,IAAE,EAAE;IAC3F,MAAM,SAAS,GAAC,MAAM,IAAA,kBAAO,EAAC,IAAA,gBAAI,EAAC,IAAA,gBAAM,GAAE,EAAC,gBAAgB,CAAC,CAAC,CAAC;IAC/D,MAAM,QAAQ,GAAC,IAAA,gBAAI,EAAC,SAAS,EAAC,cAAc,CAAC,CAAC;IAC9C,MAAM,OAAO,GAAC,KAAK,CAAC;IACp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M,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;YACrF,MAAM,CAAC,IAAI,CAAC,EAAC,EAAE,EAAC,MAAM,CAAC,MAAM,CAAC,EAAE,EAAE,EAAC,IAAI,EAAC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,EAAC,CAAC,CAAC;YAC/D,MAAM,CAAC,KAAK,EAAE,CAAC;QACnB,CAAC;QACD,MAAM,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,CAAC,EAAC,EAAE,EAAC,CAAC,EAAC,IAAI,EAAC,YAAY,EAAC,EAAC,EAAC,EAAE,EAAC,EAAE,EAAC,IAAI,EAAC,YAAY,EAAC,CAAC,CAAC,CAAC;IACjF,CAAC;YAAS,CAAC;QACP,MAAM,MAAM,CAAC,KAAK,EAAE,CAAC;QACrB,MAAM,IAAA,aAAE,EAAC,SAAS,EAAC,EAAC,SAAS,EAAC,IAAI,EAAC,KAAK,EAAC,IAAI,EAAC,CAAC,CAAC;IACpD,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -0,0 +1,21 @@
1
+ import { type FileCursorResult } from '@cobol-ts/cursor-file';
2
+ import { type CobolRepresentation, type CobolDecodedDetails, type CobolFileOptions } from '@cobol-ts/cursor-loader-cobol';
3
+ /** Prepare copybook geometry and decoders without opening or reading a data file. */
4
+ export declare function prepareCobolFileDetails(options: Pick<CobolFileOptions<unknown>, 'copybook' | 'framing' | 'layoutOptions' | 'decodeOptions' | 'metrics' | 'experimentalSharedOdoArrays'>): Promise<CobolDecodedDetails>;
5
+ /**
6
+ * Open an FB or RDW-framed COBOL file as borrowed, lazy projections.
7
+ *
8
+ * Source setup and decoder compilation happen once, before any row is read.
9
+ * Records use the existing FileCursorResult.close() ownership contract.
10
+ * Opening the handle is deferred until iteration starts; it is closed on
11
+ * completion, error, or iterator.return() (e.g. breaking from for-await).
12
+ */
13
+ export declare function readCobolFile<TProjection>(options: CobolFileOptions<TProjection>): AsyncGenerator<FileCursorResult<TProjection>, void, void>;
14
+ /**
15
+ * High-throughput alternative to readCobolFile(). Each borrowed projection is
16
+ * usable only until the synchronous callback returns. Return false to stop.
17
+ * All COBOL setup and field decoding is identical to readCobolFile().
18
+ */
19
+ export declare function scanCobolFile<TProjection>(options: CobolFileOptions<TProjection>, onRecord: (row: TProjection, parsed: CobolRepresentation) => void | boolean): Promise<void>;
20
+ /** Leased callback scanner. Ownership transfers to each callback's result. */
21
+ export declare function scanCobolFileLeased<TProjection>(options: CobolFileOptions<TProjection>, onRecord: (lease: FileCursorResult<TProjection>, parsed: CobolRepresentation) => void | boolean): Promise<void>;
@@ -0,0 +1,89 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.prepareCobolFileDetails = prepareCobolFileDetails;
4
+ exports.readCobolFile = readCobolFile;
5
+ exports.scanCobolFile = scanCobolFile;
6
+ exports.scanCobolFileLeased = scanCobolFileLeased;
7
+ const files_node_1 = require("@cobol-ts/files-node");
8
+ const node_path_1 = require("node:path");
9
+ const copybook_1 = require("@cobol-ts/copybook");
10
+ const layout_1 = require("@cobol-ts/layout");
11
+ const errors_1 = require("@cobol-ts/errors");
12
+ const cursor_file_1 = require("@cobol-ts/cursor-file");
13
+ const cursor_file_node_1 = require("@cobol-ts/cursor-file-node");
14
+ const cursor_loader_cobol_1 = require("@cobol-ts/cursor-loader-cobol");
15
+ const cursor_loader_cobol_2 = require("@cobol-ts/cursor-loader-cobol");
16
+ const { readFile, open } = files_node_1.nodeLocalFiles.promises;
17
+ /** Prepare copybook geometry and decoders without opening or reading a data file. */
18
+ async function prepareCobolFileDetails(options) {
19
+ const text = await readFile(options.copybook, 'utf8');
20
+ const ast = (0, errors_1.valueOrThrow)((0, copybook_1.parseCopybook)(text));
21
+ const layout = (0, errors_1.valueOrThrow)((0, layout_1.compileCobolLayout)(ast, (0, node_path_1.basename)(options.copybook), options.layoutOptions));
22
+ return {
23
+ ...(0, errors_1.valueOrThrow)((0, cursor_loader_cobol_1.createCobolDecodedFramedDetails)(layout, options.framing, options.decodeOptions)),
24
+ metrics: options.metrics,
25
+ experimentalSharedOdoArrays: options.experimentalSharedOdoArrays
26
+ };
27
+ }
28
+ /**
29
+ * Open an FB or RDW-framed COBOL file as borrowed, lazy projections.
30
+ *
31
+ * Source setup and decoder compilation happen once, before any row is read.
32
+ * Records use the existing FileCursorResult.close() ownership contract.
33
+ * Opening the handle is deferred until iteration starts; it is closed on
34
+ * completion, error, or iterator.return() (e.g. breaking from for-await).
35
+ */
36
+ async function* readCobolFile(options) {
37
+ const details = await prepareCobolFileDetails(options);
38
+ const file = await open(options.filename, 'r');
39
+ try {
40
+ yield* (0, cursor_file_1.createThrowingFileCursor)({ filename: options.filename, fileType: 'cobol', projection: options.projection }, file, {
41
+ parsers: (0, cursor_loader_cobol_2.createCobolParserRegistry)(details),
42
+ bufferSize: options.bufferSize ?? 64 * 1024,
43
+ fillFileBuffer: cursor_file_node_1.fillNodeFileBuffer,
44
+ metrics: options.metrics,
45
+ });
46
+ }
47
+ finally {
48
+ await file.close();
49
+ }
50
+ }
51
+ /**
52
+ * High-throughput alternative to readCobolFile(). Each borrowed projection is
53
+ * usable only until the synchronous callback returns. Return false to stop.
54
+ * All COBOL setup and field decoding is identical to readCobolFile().
55
+ */
56
+ async function scanCobolFile(options, onRecord) {
57
+ const details = await prepareCobolFileDetails(options);
58
+ options.onPrepared?.(details);
59
+ const file = await open(options.filename, 'r');
60
+ try {
61
+ await (0, cursor_file_1.scanThrowingFileCursor)({ filename: options.filename, fileType: 'cobol', projection: options.projection }, file, { parsers: (0, cursor_loader_cobol_2.createCobolParserRegistry)(details),
62
+ bufferSize: options.bufferSize ?? 64 * 1024,
63
+ fillFileBuffer: cursor_file_node_1.fillNodeFileBuffer,
64
+ recordPool: options.recordPool,
65
+ byteBufferPool: options.byteBufferPool,
66
+ metrics: options.metrics }, (row, parsed) => onRecord(row, parsed));
67
+ }
68
+ finally {
69
+ await file.close();
70
+ }
71
+ }
72
+ /** Leased callback scanner. Ownership transfers to each callback's result. */
73
+ async function scanCobolFileLeased(options, onRecord) {
74
+ const details = await prepareCobolFileDetails(options);
75
+ options.onPrepared?.(details);
76
+ const file = await open(options.filename, 'r');
77
+ try {
78
+ await (0, cursor_file_1.scanLeasedFileCursor)({ filename: options.filename, fileType: 'cobol', projection: options.projection }, file, { parsers: (0, cursor_loader_cobol_2.createCobolParserRegistry)(details),
79
+ bufferSize: options.bufferSize ?? 64 * 1024,
80
+ fillFileBuffer: cursor_file_node_1.fillNodeFileBuffer,
81
+ recordPool: options.recordPool,
82
+ byteBufferPool: options.byteBufferPool,
83
+ metrics: options.metrics }, (lease, parsed) => onRecord(lease, parsed));
84
+ }
85
+ finally {
86
+ await file.close();
87
+ }
88
+ }
89
+ //# sourceMappingURL=cobol.file.node.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cobol.file.node.js","sourceRoot":"","sources":["../../src/cobol.file.node.ts"],"names":[],"mappings":";;AAkBA,0DAUC;AAUD,sCAoBC;AAOD,sCAsBC;AAGD,kDAsBC;AAhHD,qDAAmD;AACnD,yCAAmC;AACnC,iDAAiD;AACjD,6CAAoD;AACpD,6CAA8C;AAC9C,uDAK+B;AAC/B,iEAA8D;AAC9D,uEAAwJ;AACxJ,uEAAwE;AAExE,MAAM,EAAC,QAAQ,EAAE,IAAI,EAAC,GAAG,2BAAc,CAAC,QAAQ,CAAA;AAEhD,qFAAqF;AAC9E,KAAK,UAAU,uBAAuB,CAAC,OAC6D;IACvG,MAAM,IAAI,GAAG,MAAM,QAAQ,CAAC,OAAO,CAAC,QAAQ,EAAE,MAAM,CAAC,CAAC;IACtD,MAAM,GAAG,GAAG,IAAA,qBAAY,EAAC,IAAA,wBAAa,EAAC,IAAI,CAAC,CAAC,CAAC;IAC9C,MAAM,MAAM,GAAG,IAAA,qBAAY,EAAC,IAAA,2BAAkB,EAAC,GAAG,EAAE,IAAA,oBAAQ,EAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,OAAO,CAA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,OAAO,CAAC,cAAc;YACrC,OAAO,EAAC,OAAO,CAAC,OAAO,EAAC,EAC5B,CAAC,KAAK,EAAC,MAAM,EAAE,EAAE,CAAC,QAAQ,CAAC,KAAK,EAAC,MAA6B,CAAC,CAClE,CAAC;IACN,CAAC;YAAS,CAAC;QACP,MAAM,IAAI,CAAC,KAAK,EAAE,CAAC;IACvB,CAAC;AACL,CAAC"}
package/index.ts ADDED
@@ -0,0 +1 @@
1
+ export * from './src/cobol.file.node'
package/package.json CHANGED
@@ -1,6 +1,75 @@
1
1
  {
2
2
  "name": "@cobol-ts/cursor-loader-cobol-node",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
3
+ "description": "Native COBOL file acquisition",
4
+ "version": "0.0.57",
5
+ "main": "dist/index",
6
+ "types": "dist/index",
7
+ "browserslist": {
8
+ "development": [
9
+ "last 1 chrome version",
10
+ "last 1 firefox version",
11
+ "last 1 safari version"
12
+ ],
13
+ "production": [
14
+ ">0.2%",
15
+ "not dead",
16
+ "not op_mini all"
17
+ ]
18
+ },
19
+ "dependencies": {
20
+ "@cobol-ts/cursor-loader-cobol": "0.0.57",
21
+ "@cobol-ts/layout": "0.0.57",
22
+ "@cobol-ts/errors": "0.0.57",
23
+ "@cobol-ts/copybook": "0.0.57",
24
+ "@cobol-ts/cursor-projection": "0.0.57",
25
+ "@cobol-ts/cursor-file": "0.0.57",
26
+ "@cobol-ts/files-node": "0.0.57",
27
+ "@cobol-ts/cursor-file-node": "0.0.57"
28
+ },
29
+ "devDependencies": {
30
+ "typescript": "^5.2.2",
31
+ "@testing-library/jest-dom": "^6.1.4",
32
+ "@types/jest": "^29.0.0",
33
+ "@types/node": "^20.0.0",
34
+ "jest": "^29.0.0",
35
+ "ts-jest": "^29.0.0"
36
+ },
37
+ "eslintConfig": {
38
+ "extends": [
39
+ "react-app",
40
+ "react-app/jest"
41
+ ],
42
+ "overrides": [
43
+ {
44
+ "files": [
45
+ "**/*.stories.*"
46
+ ],
47
+ "rules": {
48
+ "import/no-anonymous-default-export": "off"
49
+ }
50
+ }
51
+ ]
52
+ },
53
+ "files": [
54
+ "dist/index.js",
55
+ "dist/index.d.ts",
56
+ "dist/src/",
57
+ "build/",
58
+ "dist/node.js",
59
+ "dist/node.d.ts",
60
+ "node.js",
61
+ "node.d.ts",
62
+ "dist/**/*"
63
+ ],
64
+ "keywords": [
65
+ "indexing"
66
+ ],
67
+ "license": "MIT",
68
+ "module": "./index.ts",
69
+ "repository": "git@github.com:intellimaintain/intellimaintain.git",
70
+ "scripts": {
71
+ "test": "jest --config jest.config.json --env node",
72
+ "test:watch": "npm run test -- --watch",
73
+ "start": "react-scripts start"
74
+ }
6
75
  }