Package org.json.simple.parser
Class ParseException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- org.json.simple.parser.ParseException
-
- All Implemented Interfaces:
java.io.Serializable
@Deprecated public class ParseException extends java.lang.Exception
Deprecated.since 2.0.0, copied to a new package.ParseException explains why and where the error occurs in source JSON text.- Author:
- FangYidong<fangyidong@yahoo.com.cn>
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static int
ERROR_UNEXPECTED_CHAR
Deprecated.description omitted.static int
ERROR_UNEXPECTED_EXCEPTION
Deprecated.description omitted.static int
ERROR_UNEXPECTED_TOKEN
Deprecated.description omitted.
-
Constructor Summary
Constructors Constructor Description ParseException(int errorType)
Deprecated.ParseException(int position, int errorType, java.lang.Object unexpectedObject)
Deprecated.ParseException(int errorType, java.lang.Object unexpectedObject)
Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description int
getErrorType()
Deprecated.Action on data for a result.java.lang.String
getMessage()
Deprecated.int
getPosition()
Deprecated.java.lang.Object
getUnexpectedObject()
Deprecated.void
setErrorType(int errorType)
Deprecated.Action on data for a result.void
setPosition(int position)
Deprecated.Action on data for a result.void
setUnexpectedObject(java.lang.Object unexpectedObject)
Deprecated.Action on data for a result.
-
-
-
Field Detail
-
ERROR_UNEXPECTED_CHAR
public static final int ERROR_UNEXPECTED_CHAR
Deprecated.description omitted.- See Also:
- Constant Field Values
-
ERROR_UNEXPECTED_TOKEN
public static final int ERROR_UNEXPECTED_TOKEN
Deprecated.description omitted.- See Also:
- Constant Field Values
-
ERROR_UNEXPECTED_EXCEPTION
public static final int ERROR_UNEXPECTED_EXCEPTION
Deprecated.description omitted.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ParseException
public ParseException(int errorType)
Deprecated.- Parameters:
errorType
- description omitted.
-
ParseException
public ParseException(int errorType, java.lang.Object unexpectedObject)
Deprecated.- Parameters:
errorType
- description omitted.unexpectedObject
- description omitted.
-
ParseException
public ParseException(int position, int errorType, java.lang.Object unexpectedObject)
Deprecated.- Parameters:
position
- description omitted.errorType
- description omitted.unexpectedObject
- description omitted.
-
-
Method Detail
-
getErrorType
public int getErrorType()
Deprecated.Action on data for a result.- Returns:
- description omitted.
-
setErrorType
public void setErrorType(int errorType)
Deprecated.Action on data for a result.- Parameters:
errorType
- description omitted.
-
getPosition
public int getPosition()
Deprecated.- Returns:
- The character position (starting with 0) of the input where the error occurs.
- See Also:
JSONParser.getPosition()
-
setPosition
public void setPosition(int position)
Deprecated.Action on data for a result.- Parameters:
position
- description omitted.
-
getUnexpectedObject
public java.lang.Object getUnexpectedObject()
Deprecated.- Returns:
- One of the following base on the value of errorType: ERROR_UNEXPECTED_CHAR java.lang.Character ERROR_UNEXPECTED_TOKEN org.json.simple.parser.Yytoken ERROR_UNEXPECTED_EXCEPTION java.lang.Exception
- See Also:
Yytoken
-
setUnexpectedObject
public void setUnexpectedObject(java.lang.Object unexpectedObject)
Deprecated.Action on data for a result.- Parameters:
unexpectedObject
- description omitted.
-
getMessage
public java.lang.String getMessage()
Deprecated.- Overrides:
getMessage
in classjava.lang.Throwable
-
-