java Java终端模拟器

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/12405489/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-10-31 08:46:13  来源:igfitidea点击:

Java terminal emulator

javaterminal-emulatorvt100

提问by Rima

Does anyone knows of a library or a class that emulates the vt100 terminal (doesn't matter if graphical or not). What I want basically is a class that implements the logic of a vt100 terminal (like when receiving a "delete" code will call a delete function, or if GUI based that will delete one char).

有谁知道模拟 vt100 终端的库或类(图形与否无关紧要)。我想要的基本上是一个实现 vt100 终端逻辑的类(比如接收“删除”代码时将调用删除函数,或者如果基于 GUI 将删除一个字符)。

采纳答案by Alexis Dufrenoy

Telnetd seems to be a complete and pretty well documented solution:

Telnetd 似乎是一个完整且有据可查的解决方案:

http://telnetd.sourceforge.net/

http://telnetd.sourceforge.net/

You can also try:

你也可以试试:

http://www.jcraft.com/jcterm/

http://www.jcraft.com/jcterm/

It behaves like a VT100 and uses a SSH2 connection. But the website indicates the VT100 emulation is incomplete.

它的行为类似于 VT100,并使用 SSH2 连接。但网站显示 VT100 仿真不完整。

回答by Dmitry Trofimov

Have a look at the JediTerm project: https://github.com/traff/jediterm

看看 JediTerm 项目:https: //github.com/traff/jediterm

It has both graphical implementation as well as API to override. Graphical version works for remote connections(using JSch) and local pty(using JPty).

它既有图形化的实现,也有覆盖的 API。图形版本适用于远程连接(使用 JSch)和本地 pty(使用 JPty)。