public class JSONRPC2ParseException extends java.lang.Exception
Modifier and Type | Field and Description |
---|---|
static int |
JSON
Indicates a parse exception caused by invalid JSON.
|
static int |
PROTOCOL
Indicates a parse exception caused by a JSON message not conforming
to the JSON-RPC 2.0 protocol.
|
Constructor and Description |
---|
JSONRPC2ParseException(java.lang.String message)
Creates a new parse exception with the specified message.
|
JSONRPC2ParseException(java.lang.String message,
int causeType,
java.lang.String unparsableString)
Creates a new parse exception with the specified message, cause type
and the original string that didn't parse.
|
JSONRPC2ParseException(java.lang.String message,
java.lang.String unparsableString)
Creates a new parse exception with the specified message and the
original string that didn't parse.
|
Modifier and Type | Method and Description |
---|---|
int |
getCauseType()
Gets the parse exception cause type.
|
java.lang.String |
getUnparsableString()
Gets original string that caused the parse exception (if specified).
|
public static final int PROTOCOL
public static final int JSON
public JSONRPC2ParseException(java.lang.String message)
PROTOCOL
.message
- The exception message.public JSONRPC2ParseException(java.lang.String message, java.lang.String unparsableString)
PROTOCOL
.message
- The exception message.unparsableString
- The unparsable string.public JSONRPC2ParseException(java.lang.String message, int causeType, java.lang.String unparsableString)
public int getCauseType()
public java.lang.String getUnparsableString()
null
if none.Copyright © 2017 The Transaction Company. All Rights Reserved.