| Modifier and Type | Method and Description |
|---|---|
static BigDecimal |
readBigDecimal()
Reads the next line from the standard input and parses it into a
BigDecimal value. |
static BigInteger |
readBigInteger()
Reads the next line from the standard input and parses it into a
BigInteger value. |
static BigInteger |
readBigInteger(int radix)
Reads the next line from the standard input and parses it into a
BigInteger value with the specified radix. |
static boolean |
readBoolean()
Reads the next line from the standard input and parses it into a
boolean value. |
static double |
readDouble()
Reads the next line from the standard input and parses it into a
double value. |
static int |
readInt()
Reads the next line from the standard input and parses it into an
int value. |
static int |
readInt(int radix)
Reads the next line from the standard input and parses it into an
int value with the specified radix. |
static long |
readLong()
Reads the next line from the standard input and parses it into a
long value. |
static long |
readLong(int radix)
Reads the next line from the standard input and parses it into a
long value with the specified radix. |
static String |
readString()
Reads the next line from the standard input using the system's
default charset.
|
static String |
readString(Charset charset)
Reads the next line from the standard input using the given charset.
|
public static String readString() throws IOException
IOException - if the standard input cannot be read.public static String readString(Charset charset) throws IOException
charset - the charset to use.NullPointerException - if charset is null.IOException - if the standard input cannot be read.public static boolean readBoolean()
throws IOException
boolean value. The strings "true", "on", "yes" (ignoring
spaces and case) return true, all other strings will return
false.boolean value.IOException - if the standard input cannot be read.public static int readInt()
throws IOException
int value.int value.IOException - if the standard input cannot be read.NumberFormatException - if the line cannot be parsed.public static int readInt(int radix)
throws IOException
int value with the specified radix.radix - the radix to be used in interpreting the read line.int value.IOException - if the standard input cannot be read.NumberFormatException - if the line cannot be parsed.public static long readLong()
throws IOException
long value.long value.IOException - if the standard input cannot be read.NumberFormatException - if the line cannot be parsed.public static long readLong(int radix)
throws IOException
long value with the specified radix.radix - the radix to be used in interpreting the read line.long value.IOException - if the standard input cannot be read.NumberFormatException - if the line cannot be parsed.public static BigInteger readBigInteger() throws IOException
BigInteger value.BigInteger value.IOException - if the standard input cannot be read.NumberFormatException - if the line cannot be parsed.public static BigInteger readBigInteger(int radix) throws IOException
BigInteger value with the specified radix.radix - the radix to be used in interpreting the read line.BigInteger value.IOException - if the standard input cannot be read.NumberFormatException - if the line cannot be parsed.public static double readDouble()
throws IOException
double value.double value.IOException - if the standard input cannot be read.NumberFormatException - if the line cannot be parsed.public static BigDecimal readBigDecimal() throws IOException
BigDecimal value.BigDecimal value.IOException - if the standard input cannot be read.NumberFormatException - if the line cannot be parsed.Copyright © 2012–2015. All rights reserved.