What exceptions can Jtoken.ToObject<T>() throw?

Viewed 438

Is there a list of exceptions that JToken.ToObject<T>() can throw? Their documentation doesn't mention anything.

var deserialized = myJtoken.ToObject<myType>(); // what can this throw?
1 Answers

As far as I have examined, according to source code, there are two obvious exceptions:

ArgumentException
ArgumentNotNull

But this may not be a complete list of exceptions, there might be other exceptions within internal methods.

Related