public class ReadException
extends GroovyException
Exception that wraps I/O exceptions (IOException) in a Groovy-specific context. Provides convenient access to the underlying I/O cause while maintaining the GroovyException hierarchy.
| Constructor and description |
|---|
ReadException(IOException cause)Constructs a ReadException from an I/O exception. |
ReadException(String message, IOException cause)Constructs a ReadException from a message and an I/O exception. |
| Type Params | Return Type | Name and description |
|---|---|---|
|
public IOException |
getIOCause()Returns the underlying I/O cause of this exception. |
|
public String |
getMessage()Returns the exception message. |
|
public String |
toString()Returns a string representation of this exception. |
| Methods inherited from class | Name |
|---|---|
class GroovyException |
isFatal, setFatal |
Constructs a ReadException from an I/O exception. No specific message is provided.
cause - the IOException that triggered this exceptionConstructs a ReadException from a message and an I/O exception.
message - the error messagecause - the underlying IOException that triggered this exceptionReturns the underlying I/O cause of this exception.
Returns the exception message. Equivalent to toString() for this exception type.
Returns a string representation of this exception. If no custom message was provided, returns the cause's message.
Copyright © 2003-2026 The Apache Software Foundation. All rights reserved.