public class

ScannerInputReader

extends FilterReader
implements Constants
java.lang.Object
   ↳ java.io.Reader
     ↳ java.io.FilterReader
       ↳ sun.tools.java.ScannerInputReader

Class Overview

An input stream for java programs. The stream treats either "\n", "\r" or "\r\n" as the end of a line, it always returns \n. It also parses UNICODE characters expressed as ￿. However, if it sees "\\", the second slash cannot begin a unicode sequence. It keeps track of the current position in the input stream. WARNING: The contents of this source file are not part of any supported API. Code that depends on them does so at its own risk: they are subject to change or removal without notice.

Summary

[Expand]
Inherited Constants
From interface sun.tools.java.Constants
From interface sun.tools.java.RuntimeConstants
[Expand]
Inherited Fields
From class java.io.FilterReader
From class java.io.Reader
From interface sun.tools.java.Constants
From interface sun.tools.java.RuntimeConstants
Public Constructors
ScannerInputReader(Environment env, InputStream in)
Public Methods
int read()
Reads a single character.
int read(char[] buffer, int off, int len)
Reads characters into a portion of an array.
[Expand]
Inherited Methods
From class java.io.FilterReader
From class java.io.Reader
From class java.lang.Object
From interface java.io.Closeable
From interface java.lang.Readable

Public Constructors

public ScannerInputReader (Environment env, InputStream in)

Public Methods

public int read ()

Reads a single character.

Returns
  • The character read, as an integer in the range 0 to 65535 (0x00-0xffff), or -1 if the end of the stream has been reached
Throws
IOException

public int read (char[] buffer, int off, int len)

Reads characters into a portion of an array.

Parameters
buffer Destination buffer
off Offset at which to start storing characters
len Maximum number of characters to read
Returns
  • The number of characters read, or -1 if the end of the stream has been reached