- java.lang.Object
 -  
      
- java.lang.Throwable
 -  
        
- java.lang.Exception
 -  
          
- java.lang.InterruptedException
 
 
 
 
-  
       
- 实现的所有接口
 -  
         
Serializable 
public class InterruptedException extends 异常
线程在等待,休眠或以其他方式占用时抛出,并且线程在活动之前或期间被中断。 有时,方法可能希望测试当前线程是否已被中断,如果是,则立即抛出此异常。 以下代码可用于实现此效果:if (Thread.interrupted()) // Clears interrupted status! throw new InterruptedException();- 从以下版本开始:
 - 1.0
 - 另请参见:
 -  
         
Object.wait(),Object.wait(long),Object.wait(long, int),Thread.sleep(long),Thread.interrupt(),Thread.interrupted(), Serialized Form 
 
-  
        
       
-  
             
构造方法摘要
构造方法 构造器 描述 InterruptedException()构造一个没有详细消息的InterruptedException。InterruptedException(String s)使用指定的详细消息构造InterruptedException。 
-  
             
方法摘要
 
 -  
             
 
-  
        
       
-  
             
构造方法详细信息
-  
InterruptedException
public InterruptedException()
构造一个没有详细消息的InterruptedException。 
-  
InterruptedException
public InterruptedException(String s)
使用指定的详细消息构造InterruptedException。- 参数
 -  
              
s- 详细信息。 
 
 -  
 
 -