Java Basics Java Common exceptions

Source: Internet
Author: User

Common exceptions for Java

1. Java.lang.NullPointerException (null pointer exception) called an uninitialized object or a nonexistent object

2. Java.lang.ClassNotFoundException the specified class does not exist

3. Java.lang.NumberFormatException string conversion to numeric exception

4. Java.lang.IndexOutOfBoundsException array subscript out of bounds exception

5. Parameter errors for the Java.lang.IllegalArgumentException method

6. Java.lang.IllegalAccessException does not have access rights

7. Java.lang.ArithmeticException Mathematical Operation anomalies

8. java.lang.ClassCastException Data Type Conversion exception

9. java.lang.FileNotFoundException File not found exception

Java.lang.ArrayStoreException Array Storage Exceptions

Java.lang.NoSuchMethodException Methods No exceptions exist

Java.lang.NoSuchFiledException method (Reflection) no exception exists

The. java.lang.EOFException file has ended abnormally

Java.lang.InstantiationException Instantiation of exceptions

Java.lang.InterruptedException aborted exception

Java.lang.CloneNotSupportedException does not support cloning exceptions

Java.lang.OutOfMemoryException Insufficient Memory error

Java.lang.NoClassDefFoundException no class definition errors found

Secturityexception breach of security principle exception

SQLException Operating Database Exceptions

IOException Input-Output exception

SocketException Communication anomalies


This article is from the "Lin Yuanxian blog" blog, make sure to keep this source http://lyhmm.blog.51cto.com/1797932/1970046

Java Basics Java Common exceptions

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.