Console Key Listener

Hi, i want to have Keypresses recognized in a console app. f1,f2 etc. May anybody point me to the right direction or show me some codes as examples on google are all based on UI/Swing.-Aldrich
[213 byte] By [Aldricha] at [2007-11-27 6:00:04]
# 1
Scanner s = new Scanner(System.in);s.nextInt(), nextLine(), etc
calvino_inda at 2007-7-12 16:37:41 > top of Java-index,Java Essentials,Java Programming...
# 2
what i meant was buttons, F1, F2, F3 etc. i cant find any yet
Aldricha at 2007-7-12 16:37:41 > top of Java-index,Java Essentials,Java Programming...
# 3
you mean: - you re in a console, prog is launched- you hit F1- treatment goes on?i'm not sure you can do that
calvino_inda at 2007-7-12 16:37:41 > top of Java-index,Java Essentials,Java Programming...
# 4
oh, **** =( thanks bro
Aldricha at 2007-7-12 16:37:41 > top of Java-index,Java Essentials,Java Programming...
# 5
Check out the libraries on SourceForge for dealing with the console in Java. These things have always been deemed OS dependent (while detecting keypresses in a Swing gui is no problem. I guess there's some logic in there somewhere.)
pbrockway2a at 2007-7-12 16:37:41 > top of Java-index,Java Essentials,Java Programming...
# 6
thank you, searching now =)
Aldricha at 2007-7-12 16:37:41 > top of Java-index,Java Essentials,Java Programming...