Terminals
A terminal is a serial non-store device. The TTerminal class descends from the TDevice class.
type TDevice = class
public
procedure Cancel_Input ;
procedure Cancel_Output ;
function Pending_Input : boolean ;
function Pending_Output : boolean ;
procedure Poll ;
end ;
type TTerminal = class( TDevice )
public
procedure Output( S : PChar ) ;
function Input( var C : integer ) : boolean ;
procedure Clear_Typeahead ;
function Peek : char ;
function Video : boolean ;
function Get_OnNewChar : TCharNotify ;
procedure Set_OnNewChar( Value : TCharNotify ) ;
end ;
The following table describes the TDevice methods:
Method |
Description |
Cancel_Input |
Cancels pending input or input operation. |
Cancel_Output |
Cancels pending output or output operation. |
Pending_Input |
Returns True if there is any pending input or input operation. |
Pending_Output |
Returns True if there is any pending output or output operation. |
Poll |
Polls the device for operation completion. |
The following table describes the TTerminal methods:
Method |
Description |
Output |
Transmits the passed data. The data ends with a null. |
Input |
Retrieves the next waiting character from the device buffer. |
Clear_Typeahead |
Clears any characters waiting in the device buffer. |
Peek |
Retrieves the next waiting character from the device buffer but doesn't remove it. |
Video |
Returns true if the terminal is capable of video operations. Otherwise it returns false. |
Get_OnNewChar |
Returns the pointer to the new character delegation. |
Set_OnNewChar |
Sets the new character delegation. |