This is SerialPort.h in view mode; [Download] [Up]
/* SerialPort.h 24 March 1993 See .m file for details. */ #import <objc/Object.h> #import <sys/file.h> #import <sys/ioctl.h> #import <sys/types.h> @interface SerialPort: Object { int fd; int speed, parity, echo, raw; char *eol; // the end-of-line character \n or \r (\r default) int delay; // max. # seconds to wait for input, e.g., in gets:... id delegate; // recipient can be called with input from the port. SEL action; } ////////////////////////////////////////////// Allocation Methods + new: (char *) devicepath baud:(int)b parity:(int)p echo:(int)e raw:(int)r; + new:(char *)devicepath baud:(int)b; - free; ////////////////////////////////////////////// Parameter Methods - setBaud:(int)b parity:(int)p echo:(int)e raw:(int)r; - (char *)eol; - setEol:(char *)s; - (int)delay; - setDelay:(int)n; - (int)fd; ////////////////////////////////////////////// Input Methods - (int)hasInput; - (int)waitInput:(int)seconds; - flush; ////////////////////////////////////////////// Reading & Writing Methods - (int)putc:(char)c; - (int)write:(char *)s length:(int)n; - (int)puts:(char *)s; - (char)getc; - (int)read:(char *)s length:(int)n; - (char *)gets:(char *)s length:(int)n; - (char *)gets:(char *)s; - (char *)puts:(char *)s gets:(char *)response; ////////////////////////////////////////////// Delegate Methods - (void)setAction:(SEL)theAction; - delegate; - setDelegate:d; @end ////////////////////////////////////////////// Input Functions int fdHasInput(int fd); int fdWaitInput(int fd, int timeout);
These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.