From 9833841101c75c3d511a64daf32e8c273d7d928f Mon Sep 17 00:00:00 2001 From: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> Date: Sat, 24 Sep 2022 19:03:31 -0700 Subject: wip --- src/bun.js/api/bun.classes.ts | 51 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 src/bun.js/api/bun.classes.ts (limited to 'src/bun.js/api/bun.classes.ts') diff --git a/src/bun.js/api/bun.classes.ts b/src/bun.js/api/bun.classes.ts new file mode 100644 index 000000000..3a74549d2 --- /dev/null +++ b/src/bun.js/api/bun.classes.ts @@ -0,0 +1,51 @@ +import { define } from "../scripts/class-definitions"; + +export default [ + define({ + name: "Subprocess", + construct: true, + finalize: true, + klass: {}, + JSType: "0b11101110", + proto: { + pid: { + getter: "getPid", + }, + stdin: { + getter: "getStdin", + cache: true, + }, + stdout: { + getter: "getStdout", + cache: true, + }, + stderr: { + getter: "getStderr", + cache: true, + }, + + ref: { + fn: "doRef", + length: 0, + }, + unref: { + fn: "doUnref", + length: 0, + }, + + kill: { + fn: "kill", + length: 1, + }, + + killed: { + getter: "getKilled", + }, + + exitStatus: { + getter: "getExitStatus", + cache: true, + }, + }, + }), +]; -- cgit v1.2.3