Java开发网 Java开发网
注册 | 登录 | 帮助 | 搜索 | 排行榜 | 发帖统计  

您没有登录

» Java开发网 » Java Security  

按打印兼容模式打印这个话题 打印话题    把这个话题寄给朋友 寄给朋友    该主题的所有更新都将Email到你的邮箱 订阅主题
flat modethreaded modego to previous topicgo to next topicgo to back
作者 怎样让控制台输入的文字不回显?
lvjing79





发贴: 18
积分: 0
于 2004-04-08 09:30 user profilesend a private message to usersearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
我记得在c里面就挺简单,有一个函数就能完成。但用java的System.in却怎么也查不到资料,我想在输入密码时不回显,哪位大虾告诉我该如何做呢?


作者 Re:怎样让控制台输入的文字不回显? [Re:lvjing79]
floater

Java Jedi

总版主


发贴: 3233
积分: 421
于 2004-04-08 10:55 user profilesend a private message to usersearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
http://java.sun.com/features/2002/09/pword_mask.html


"Any fool can write code that a computer can understand. Good programmers write code that humans can understand."
- Martin Fowler, Refactoring - Improving the Design of Existing Code
作者 Re:怎样让控制台输入的文字不回显? [Re:lvjing79]
lvjing79





发贴: 18
积分: 0
于 2004-04-08 13:09 user profilesend a private message to usersearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
多谢,我觉得java好像对这个问题一直不重视,还是sun公司根本就不认为这是个问题,鼓励大家都学多线程呢?


作者 Re:怎样让控制台输入的文字不回显? [Re:lvjing79]
menzy



版主


发贴: 754
积分: 113
于 2004-04-08 18:21 user profilesend a private message to usersearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
是有些烦琐,java对 System Console的控制能力确实有限。


作者 Re:怎样让控制台输入的文字不回显? [Re:lvjing79]
floater

Java Jedi

总版主


发贴: 3233
积分: 421
于 2004-04-08 22:55 user profilesend a private message to usersearch all posts byselect and copy to clipboard. 
ie only, sorry for netscape users:-)add this post to my favorite list
well, c doesn't have a good default network lib like in java.

This is not the worst, either.



"Any fool can write code that a computer can understand. Good programmers write code that humans can understand."
- Martin Fowler, Refactoring - Improving the Design of Existing Code

flat modethreaded modego to previous topicgo to next topicgo to back
  已读帖子
  新的帖子
  被删除的帖子
Jump to the top of page

   Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent
Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1
客服电话 18559299278    客服信箱 714923@qq.com    客服QQ 714923