< prev index next >

src/java.base/share/classes/java/lang/IllegalMonitorStateException.java

Print this page




  23  * questions.
  24  */
  25 
  26 package java.lang;
  27 
  28 /**
  29  * Thrown to indicate that a thread has attempted to wait on an
  30  * object's monitor or to notify other threads waiting on an object's
  31  * monitor without owning the specified monitor.
  32  *
  33  * @author  unascribed
  34  * @see     java.lang.Object#notify()
  35  * @see     java.lang.Object#notifyAll()
  36  * @see     java.lang.Object#wait()
  37  * @see     java.lang.Object#wait(long)
  38  * @see     java.lang.Object#wait(long, int)
  39  * @since   1.0
  40  */
  41 public
  42 class IllegalMonitorStateException extends RuntimeException {

  43     private static final long serialVersionUID = 3713306369498869069L;
  44 
  45     /**
  46      * Constructs an <code>IllegalMonitorStateException</code> with no
  47      * detail message.
  48      */
  49     public IllegalMonitorStateException() {
  50         super();
  51     }
  52 
  53     /**
  54      * Constructs an <code>IllegalMonitorStateException</code> with the
  55      * specified detail message.
  56      *
  57      * @param   s   the detail message.
  58      */
  59     public IllegalMonitorStateException(String s) {
  60         super(s);
  61     }
  62 }


  23  * questions.
  24  */
  25 
  26 package java.lang;
  27 
  28 /**
  29  * Thrown to indicate that a thread has attempted to wait on an
  30  * object's monitor or to notify other threads waiting on an object's
  31  * monitor without owning the specified monitor.
  32  *
  33  * @author  unascribed
  34  * @see     java.lang.Object#notify()
  35  * @see     java.lang.Object#notifyAll()
  36  * @see     java.lang.Object#wait()
  37  * @see     java.lang.Object#wait(long)
  38  * @see     java.lang.Object#wait(long, int)
  39  * @since   1.0
  40  */
  41 public
  42 class IllegalMonitorStateException extends RuntimeException {
  43     @java.io.Serial
  44     private static final long serialVersionUID = 3713306369498869069L;
  45 
  46     /**
  47      * Constructs an <code>IllegalMonitorStateException</code> with no
  48      * detail message.
  49      */
  50     public IllegalMonitorStateException() {
  51         super();
  52     }
  53 
  54     /**
  55      * Constructs an <code>IllegalMonitorStateException</code> with the
  56      * specified detail message.
  57      *
  58      * @param   s   the detail message.
  59      */
  60     public IllegalMonitorStateException(String s) {
  61         super(s);
  62     }
  63 }
< prev index next >