I\'ve just started messing around with JLine to parse character input in console mode. It seems to work well, but I\'m wondering:
Is there a nonblocking way in JLine
You seem to be on the right track.
I think the "right" way to do this is a worker thread that pours all the blocking I/O into a non-blocking queue. Hava a look at ConcurrentLinkedQueue from java.util.concurrent.
You can't use a console to get non-blocking input without native libraries.
You'll have to write a Swing app and write a KeyListener
Read this tutorial: http://java.sun.com/docs/books/tutorial/uiswing/events/keylistener.html