syscall

Types from the Go package syscall (a library PocketBase builds on), as JavaScript sees them: they turn up as values of PocketBase's types and of hook events.

syscall.Credential

Credential holds user and group identities to be assumed by a child process started by StartProcess.

Member Type
uid number // User ID.
gid number // Group ID.
groups Array<number> // Supplementary group IDs.
noSetGroups boolean // If true, don't set supplementary groups

syscall.SysProcAttr

Member Type
chroot string // Chroot.
credential? Credential // Credential.
ptrace boolean // Enable tracing.
setsid boolean // Create session.
setpgid boolean Setpgid sets the process group ID of the child to Pgid, or, if Pgid == 0, to the new child's process ID.
setctty boolean Setctty sets the controlling terminal of the child to file descriptor Ctty. Ctty must be a descriptor number in the child process: an index into ProcAttr.Files. This is only meaningful if Setsid is true.
noctty boolean // Detach fd 0 from controlling terminal
ctty number // Controlling TTY fd
foreground boolean Foreground places the child process group in the foreground. This implies Setpgid. The Ctty field must be set to the descriptor of the controlling TTY. Unlike Setctty, in this case Ctty must be a descriptor number in the parent process.
pgid number // Child's process group ID if Setpgid.

syscall.RawConn

A RawConn is a raw network connection.

Member Type
control() (f: (fd: number) => void): void Control invokes f on the underlying connection's file descriptor or handle. The file descriptor fd is guaranteed to remain valid while f executes but not after f returns.
read() (f: (fd: number) => boolean): void Read invokes f on the underlying connection's file descriptor or handle; f is expected to try to read from the file descriptor. If f returns true, Read returns. Otherwise Read blocks waiting for the connection to be ready for reading and tries again repeatedly. The file descriptor is guaranteed to remain valid while f executes but not after f returns.
write() (f: (fd: number) => boolean): void Write is like Read but for writing.

syscall.Errno

An Errno is an unsigned number describing an error condition. It implements the error interface. The zero Errno is by convention a non-error, so code to convert from Errno to error should use:

	err = nil
	if errno != 0 {
		err = errno
	}

Errno values can be tested against error values using errors.is. For example:

	_, _, err := syscall.Syscall(...)
	if errors.Is(err, fs.ErrNotExist) ...

Has everything Number has.

Member Type
error() (): string
is() (target: Error): boolean
temporary() (): boolean
timeout() (): boolean