IT. Expert System.

Android Reference

Console


java.io

Class Console

  • All Implemented Interfaces:
    Flushable


    public final class Console
    extends Object
    implements Flushable
    Provides access to the console, if available. The system-wide instance can be accessed via System.console().
    Since:
    1.6
    • Method Detail

      • getConsole

        public static Console getConsole()
        Secret accessor for System.console.
      • flush

        public void flush()
        Description copied from interface: Flushable
        Flushes the object by writing out any buffered data to the underlying output.
        Specified by:
        flush in interface Flushable
      • format

        public Console format(String format,
                     Object... args)
        Writes a formatted string to the console using the specified format string and arguments.
        Parameters:
        format - the format string (see Formatter.format(java.lang.String, java.lang.Object...))
        args - the list of arguments passed to the formatter. If there are more arguments than required by format, additional arguments are ignored.
        Returns:
        the console instance.
      • printf

        public Console printf(String format,
                     Object... args)
        Equivalent to format(format, args).
      • reader

        public Reader reader()
        Returns the Reader associated with this console.
      • readLine

        public String readLine()
        Reads a line from the console.
        Returns:
        the line, or null at EOF.
      • readLine

        public String readLine(String format,
                      Object... args)
        Reads a line from this console, using the specified prompt. The prompt is given as a format string and optional arguments. Note that this can be a source of errors: if it is possible that your prompt contains % characters, you must use the format string "%s" and pass the actual prompt as a parameter.
        Parameters:
        format - the format string (see Formatter.format(java.lang.String, java.lang.Object...))
        args - the list of arguments passed to the formatter. If there are more arguments than required by format, additional arguments are ignored.
        Returns:
        the line, or null at EOF.
      • readPassword

        public char[] readPassword()
        Reads a password from the console. The password will not be echoed to the display.
        Returns:
        a character array containing the password, or null at EOF.
      • readPassword

        public char[] readPassword(String format,
                          Object... args)
        Reads a password from the console. The password will not be echoed to the display. A formatted prompt is also displayed.
        Parameters:
        format - the format string (see Formatter.format(java.lang.String, java.lang.Object...))
        args - the list of arguments passed to the formatter. If there are more arguments than required by format, additional arguments are ignored.
        Returns:
        a character array containing the password, or null at EOF.
      • writer

        public PrintWriter writer()
        Returns the Writer associated with this console.


Content

Android Reference

Java basics

Java Enterprise Edition (EE)

Java Standard Edition (SE)

SQL

HTML

PHP

CSS

Java Script

MYSQL

JQUERY

VBS

REGEX

C

C++

C#

Design patterns

RFC (standard status)

RFC (proposed standard status)

RFC (draft standard status)

RFC (informational status)

RFC (experimental status)

RFC (best current practice status)

RFC (historic status)

RFC (unknown status)

IT dictionary

License.
All information of this service is derived from the free sources and is provided solely in the form of quotations. This service provides information and interfaces solely for the familiarization (not ownership) and under the "as is" condition.
Copyright 2016 © ELTASK.COM. All rights reserved.
Site is optimized for mobile devices.
Downloads: 825 / . Delta: 0.02903 с