public interface WindowConstants 
      setDefaultCloseOperation层getDefaultCloseOperation所提供的方法JFrame , JInternalFrame和JDialog使用这些常量。 
       有关设置默认窗口关闭操作的示例,请参阅Java Tutorial中的 Responding to Window-Closing Events部分。 
      | Modifier and Type | Field and Description | 
|---|---|
| static int | DISPOSE_ON_CLOSE
              配置窗口默认窗口关闭操作。 
             | 
| static int | DO_NOTHING_ON_CLOSE
              不做任何默认窗口关闭操作。 
             | 
| static int | EXIT_ON_CLOSE
              退出应用程序默认窗口关闭操作。 
             | 
| static int | HIDE_ON_CLOSE
              隐藏窗口默认窗口关闭操作 
             | 
static final int DO_NOTHING_ON_CLOSE
static final int HIDE_ON_CLOSE
static final int DISPOSE_ON_CLOSE
注意 :当Java虚拟机(VM)中的最后一个可显示的窗口被丢弃时,VM可能会终止。 见AWT Threading Issues以获取更多信息。
static final int EXIT_ON_CLOSE
JFrame ,可能会抛出一个SecurityException基于SecurityManager 。 
           建议您只在应用程序中使用。 
          JFrame.setDefaultCloseOperation(int) , 
            Constant Field Values 
            Submit a bug or feature 
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
 Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.