Scanner
Class Scanner
- java.lang.Object
-
- java.util.Scanner
- All Implemented Interfaces:
- Closeable, AutoCloseable, Iterator<String>
public final class Scanner extends Object implements Iterator<String>, Closeable
A simple text scanner which can parse primitive types and strings using regular expressions.
A Scanner
breaks its input into tokens using a delimiter pattern, which by default matches whitespace. The resulting tokens may then be converted into values of different types using the various