aboutsummaryrefslogtreecommitdiff
path: root/src/bun.js/api/bun.classes.ts
diff options
context:
space:
mode:
authorGravatar Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> 2022-09-24 19:03:31 -0700
committerGravatar Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> 2022-09-25 13:14:23 -0700
commit9833841101c75c3d511a64daf32e8c273d7d928f (patch)
tree543d3de0426447161a991b0475aa749c1305f08d /src/bun.js/api/bun.classes.ts
parent1cd67b62e9d012c02d1534accf295014469be7e6 (diff)
downloadbun-9833841101c75c3d511a64daf32e8c273d7d928f.tar.gz
bun-9833841101c75c3d511a64daf32e8c273d7d928f.tar.zst
bun-9833841101c75c3d511a64daf32e8c273d7d928f.zip
wip
Diffstat (limited to 'src/bun.js/api/bun.classes.ts')
-rw-r--r--src/bun.js/api/bun.classes.ts51
1 files changed, 51 insertions, 0 deletions
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,
+ },
+ },
+ }),
+];