The Throw exception overwrites the stack trace and this makes it hard to find the original code line number that has thrown the exception. Throw clause basically retains the stack information and adds to the stack information in the exception that it is thrown.
We use cookies to ensure you have the best browsing experience on our website. By using our site, you
acknowledge that you have read and understood our
Cookie Policy &
Privacy Policy.
The Throw exception overwrites the stack trace and this makes it hard to find the original code line number that has thrown the exception.
Throw clause basically retains the stack information and adds to the stack information in the exception that it is thrown.
For more details you click here.