PrintStream.CheckError Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Flushes the stream and checks its error state.
[Android.Runtime.Register("checkError", "()Z", "GetCheckErrorHandler")]
public virtual bool CheckError();
[<Android.Runtime.Register("checkError", "()Z", "GetCheckErrorHandler")>]
abstract member CheckError : unit -> bool
override this.CheckError : unit -> bool
Returns
true if and only if this stream has encountered an
IOException other than
InterruptedIOException, or the
setError method has been invoked
- Attributes
Remarks
Flushes the stream and checks its error state. The internal error state is set to true when the underlying output stream throws an IOException other than InterruptedIOException, and when the setError method is invoked. If an operation on the underlying output stream throws an InterruptedIOException, then the PrintStream converts the exception back into an interrupt by doing:
{@code
Thread.currentThread().interrupt();
}
or the equivalent.
Java documentation for java.io.PrintStream.checkError().
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.