summaryrefslogtreecommitdiffstats
path: root/luni-kernel/src
diff options
context:
space:
mode:
Diffstat (limited to 'luni-kernel/src')
-rw-r--r--luni-kernel/src/main/java/java/lang/System.java12
1 files changed, 12 insertions, 0 deletions
diff --git a/luni-kernel/src/main/java/java/lang/System.java b/luni-kernel/src/main/java/java/lang/System.java
index aa78b1b..6a69c2e 100644
--- a/luni-kernel/src/main/java/java/lang/System.java
+++ b/luni-kernel/src/main/java/java/lang/System.java
@@ -32,6 +32,7 @@
package java.lang;
+import java.io.Console;
import java.io.FileDescriptor;
import java.io.FileInputStream;
import java.io.FileOutputStream;
@@ -496,6 +497,17 @@ public final class System {
}
/**
+ * Returns the {@link java.io.Console} associated with this VM, or null.
+ * Not all VMs will have an associated console. A console is typically only
+ * available for programs run from the command line.
+ * @since 1.6
+ * @hide
+ */
+ public static Console console() {
+ return Console.getConsole();
+ }
+
+ /**
* Returns the active security manager.
*
* @return the system security manager object.