title: Custom Exception Class - Shall I extend Runtime Exception OR Exception?
body: <p><strong>Can any one guide me Shall I extend Exception or RuntimeException?</strong></p>
  
  <p>Usually, it is used for validations, Unexpected Exceptions, Custom Exception, Raise if Business Logic Fails etc.</p>
  
  <p>Below is my custom exception class.</p>
  
  <pre><code>/**
   * The class &lt;code&gt;BaseException&lt;/code&gt; is a custom exception class.
   * @author Pratiyush Kumar Singh
   */
  public class BaseException  extends Exception {
  
      static final long serialVersionUID = -3387516993124229948L;
  
      /**
       * Constructs a new exception.  
       */
      public BaseException() {
          super();
      }
  
      /**
       * Constructs a new exception with the specified detail message.  
       * @param   message -  It contains the error message.
       */
      public BaseException(String message) {
          super(message);
      }
  
      /**
       * Constructs a new exception with the specified detail message.  
       * @param   message -  It contains the error message.
       * @param   cause   -  Instance of Throwable.
       */
      public BaseException(String message, Throwable cause) {
          super(message, cause);
      }
  
  }
  </code></pre>