Vielleicht gibt es ja aber auch irgendeinen Trick - an und für sich kann ich mir das aber eher weniger vorstellen.Java-Insel hat gesagt.:Neu in Java 6 ist die Klasse java.io.Console, von der System.console() ein aktuelles Exemplar liefert – oder null bei einem System ohne Konsolenmöglichkeit.
Whether a virtual machine has a console is dependent upon the underlying platform and also upon the manner in which the virtual machine is invoked. If the virtual machine is started from an interactive command line without redirecting the standard input and output streams then its console will exist and will typically be connected to the keyboard and display from which the virtual machine was launched. If the virtual machine is started automatically, for example by a background job scheduler, then it will typically not have a console.
Scanner input = new Scanner(System.in);
String x = input.readLine();
int y = input.readInt();
double z = input.readDouble();
...