public class GetOperationFailedException extends AnchorFriendlyCheckedException
Constructor and Description |
---|
GetOperationFailedException(Exception cause)
Creates with only a cause, omitting a key and a message.
|
GetOperationFailedException(int key,
String message)
Creates with a message, but no cause - with an integer key.
|
GetOperationFailedException(int key,
Throwable cause)
Creates with a cause, but no message - with an integer key.
|
GetOperationFailedException(String key,
String message)
Creates with a message, but no cause - with a
String key. |
GetOperationFailedException(String key,
Throwable cause)
Creates with a cause, but no message - with a
String key. |
Modifier and Type | Method and Description |
---|---|
OperationFailedException |
asOperationFailedException()
Converts to a
OperationFailedException using an identical message. |
String |
getKey()
The key that was used in the operation that created this exception.
|
String |
getMessage()
A message describing the failure.
|
friendlyMessage, friendlyMessageHierarchy, friendlyMessageHierarchy, stackTrace
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
public GetOperationFailedException(Exception cause)
The key is instead stored as an empty string.
cause
- the cause.public GetOperationFailedException(int key, String message)
key
- the key that was used in the operation that created this exception.message
- a message describing the failure.public GetOperationFailedException(String key, String message)
String
key.key
- the key that was used in the operation that created this exception.message
- a message describing the failure.public GetOperationFailedException(int key, Throwable cause)
key
- the key that was used in the operation that created this exception.cause
- the cause of the failure.public OperationFailedException asOperationFailedException()
OperationFailedException
using an identical message.
Any cause and key information is discarded.
public String getKey()
public String getMessage()
getMessage
in class Throwable
Copyright © 2010–2023 Owen Feehan, ETH Zurich, University of Zurich, Hoffmann-La Roche. All rights reserved.