开发者

output as part of input stream

开发者 https://www.devze.com 2022-12-20 16:57 出处:网络
Is there a way to output some text and allow a user to edit and submit as System.in? Obviously System.out.print is not editable...

Is there a way to output some text and allow a user to edit and submit as System.in? Obviously System.out.print is not editable...

Eg.

system outputs:

Hallo

user edits to开发者_运维问答:

Hello

system echos:

Hello


Not directly via System, I don't think. You'll need to interface with the user in some way, either via a GUI or a terminal handling library like curses (if such a thing exists for Java).

0

精彩评论

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

关注公众号