Is there a way to know if a user pressed the key ENTER using readline()
method? - Java
I want to recognize if a user sent a text, using readline method from
BufferedReader. While the user didn't send anything, the Thread keeps
sleeping. Is there a way to do this? I'm trying for a long time, but no
success yet.. I guess I have to recognize if a ENTER key was pressed.. but
I donwt know how to do this.. The interface of my program is the console..
No comments:
Post a Comment