conpty/conpty.go
raw| 1 | package conpty |
| 2 | |
| 3 | import ( |
| 4 | "os" |
| 5 | "syscall" |
| 6 | ) |
| 7 | |
| 8 | type pty interface { |
| 9 | Close() error |
| 10 | Fd() uintptr |
| 11 | InPipe() *os.File |
| 12 | InPipeFd() uintptr |
| 13 | OutPipe() *os.File |
| 14 | OutPipeFd() uintptr |
| 15 | Read(p []byte) (n int, err error) |
| 16 | Resize(w int, h int) error |
| 17 | Size() (w int, h int, err error) |
| 18 | Spawn(name string, args []string, attr *syscall.ProcAttr) (pid int, handle uintptr, err error) |
| 19 | Write(p []byte) (n int, err error) |
| 20 | } |
| 21 | |
| 22 | var _ pty = &ConPty{} |