开发者

Capture virtual printer output on linux

开发者 https://www.devze.com 2023-01-17 23:16 出处:网络
I\'m writing a Java screen-scraping application for a 3270 mainframe and rather than scroll through page after page of 80x24 chars I\'d like to output all pa开发者_如何学编程ges to a printer and then

I'm writing a Java screen-scraping application for a 3270 mainframe and rather than scroll through page after page of 80x24 chars I'd like to output all pa开发者_如何学编程ges to a printer and then capture and parse the printer output.

The 3270 client has a print option, so I just need to virtualise a printer device and then somehow capture the output. Has anyone achieved this in Linux before?


You probably want to create a lpd-queue for this purpose and then hook into that.


If this is 3270 via VT100 you can issue VT100 print capture commands at the terminal. Otherwise, as already answered you can enable LPD and put a filter on it to tee it to a file.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号