BRIZ supports work on phantom channels. For this purpose the mode of expectation of connection with a server is added. The server library contains programs for maintenance of establish of connection. The program of processing of events and all other programs of server library can work in usual and phantom modes. For the organization of the channel it is necessary:
At work on phantom channels the restrictions determined by absence of the terminal operate.
Description of GPTerm.PHANTOMPRG
format: EXECUTE "Z GPTerm.PHANTOMPRG PfItemName"
where PfItemName - item name in the pointer file.
Item structure:
a1 IP address or name
a2 listen PORT
a3 Programm to execute
psstr="127.0.0.1":@am:"1967":@am:"GPEDIT"
OPEN "PF" TO pf
WRITE psstr ON pf,"PS"
CLOSE(pf)
CALL GPTerm.LISTEN(1967,1000,"")
EXECUTE "Z GPTerm.PHANTOMPRG PS"
EXECUTE "EXIT"
| GPTerm.PHANTOMCLRIN | nSeconds | Clears input |
| GPTerm.PHANTOMCOM | Common area | |
| GPTerm.PHANTOMCRT | OutString, OutLen | Outputs the string |
| GPTerm.PHANTOMIN | iChar, nSeconds | Inputs char for nSeconds seconds |
| GPTerm.PHANTOMINPUT | oBuff, nSecWait, iGetLen, oRetLen | Inputs line like INPUT |
| GPTerm.PHANTOMOUT | OutCode | Outputs char like OUT |
| GPTerm.LISTEN | ListenPort, ListenTime, flags |
Switchs the current session into a listening mode. ListenTime in sec. flags : TELNET |
*** Tested under LINUX