15 lines
305 B
JavaScript
15 lines
305 B
JavaScript
//@ts-check
|
|
/**
|
|
* @type {{ open: (path: string, flags: number, mode?: number) => number, close: (fd: number) => void }}
|
|
*/
|
|
//@ts-expect-error
|
|
const cfiles = require('./file.node')
|
|
|
|
const modes = {
|
|
O_ACCMODE: 3,
|
|
O_RDONLY: 0,
|
|
O_WRONLY: 1,
|
|
O_RDWR: 2
|
|
}
|
|
|
|
module.exports = { ...cfiles, modes } |