Cast and throw exception if failed
<p>I need to cast an object as another and throw an exception if it fails, to check they type of the object.</p>

<p>What kind of an exception should I be looking to catch? That is, if casting fails, what exception does it throw?</p>
