Finally you can easily accept password from console in Java, without echoing them. واخيرا هل يمكن ان يقبل بسهولة من console كلمة السر في يافا ، دون ان يردد لها.

This long unmet need has been addressed in هذه المده الطويلة من الاحتياجات غير الملباه تم تناولها في JDK 1.6 1،6 وهم ج. codeline.

A new class - طبقة جديدة -- java.io.Console java.io.console has been defined to handle console I/O. وقد عرفت لمعالجة console الاول / سين

To accept password from console in من لقبول كلمة السر في console JDK 6.0 (aka JDK 1.6) وهم ج 6.0 (1.6 اكا وهم ج.) use either: اما استخدام :
public char[] readPassword() شار العامة [] readpassword ()
or او
public char[] readPassword(String fmt, Object… args) شار العامة [] readpassword (سلسلة الاداه ، وجوه args…)

 Sample code:   Console cons;   char[] passwd;   if ((cons = System.console()) != null &&        (passwd = cons.readPassword(”[%s]“, “Password:”)) != null) {        // Use the passwd for authentication etc.        ….; // Your code        // After you are done zero the character array in memory for reducing security risk java.util.Arrays.fill(passwd, ‘ ‘); } نموذج رمز : console الدستوري ؛ شار [] passwd ؛ اذا كانت الاجابه ب ((الدستوري system.console = ())! = اغيه & & (passwd = cons.readpassword ( "[٪]" ، و "كلمة السر :"))! = باطل) (/ / استخدام passwd لتوثيق… الخ. ؛ / / الكود / / بعد انتهائك الصفر طابع المصفوفه في الذاكرة للحد من المخاطر الامنية java.util.arrays.fill (passwd ، '') ؛) 

So could I entice you yet to بذلك يمكن أن تغري لكم انني بعد download JDK 1.6 تحميل وهم ج 1،6 ? ؟