⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 joptionpane.html

📁 API資料大全
💻 HTML
📖 第 1 页 / 共 5 页
字号:
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the option pane's message-object.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#setMessageType(int)">setMessageType</A></B>(int&nbsp;newType)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the option pane's message type.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#setOptions(java.lang.Object[])">setOptions</A></B>(<A HREF="../../java/lang/Object.html">Object</A>[]&nbsp;newOptions)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the options this pane displays.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#setOptionType(int)">setOptionType</A></B>(int&nbsp;newType)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the options to display.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#setRootFrame(java.awt.Frame)">setRootFrame</A></B>(<A HREF="../../java/awt/Frame.html">Frame</A>&nbsp;newRootFrame)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the frame to use for class methods in which a frame is not provided.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#setSelectionValues(java.lang.Object[])">setSelectionValues</A></B>(<A HREF="../../java/lang/Object.html">Object</A>[]&nbsp;newValues)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the selection values for a pane that provides the user with a list of items to choose from.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#setUI(javax.swing.plaf.OptionPaneUI)">setUI</A></B>(<A HREF="../../javax/swing/plaf/OptionPaneUI.html">OptionPaneUI</A>&nbsp;ui)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the UI object which implements the L&F for this component.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#setValue(java.lang.Object)">setValue</A></B>(<A HREF="../../java/lang/Object.html">Object</A>&nbsp;newValue)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the value the user has chosen.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;void</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#setWantsInput(boolean)">setWantsInput</A></B>(boolean&nbsp;newValue)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;If <code>newValue</code> is true, a <code>parentComponent</code> is provided to allow the user to input a value.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showConfirmDialog(java.awt.Component, java.lang.Object)">showConfirmDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                  <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Brings up a modal dialog with the options Yes, No and Cancel; with the title, "Select an Option".</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showConfirmDialog(java.awt.Component, java.lang.Object, java.lang.String, int)">showConfirmDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                  <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message,                  <A HREF="../../java/lang/String.html">String</A>&nbsp;title,                  int&nbsp;optionType)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Brings up a modal dialog where the number of choices is determined by the <code>optionType</code> parameter.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showConfirmDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int)">showConfirmDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                  <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message,                  <A HREF="../../java/lang/String.html">String</A>&nbsp;title,                  int&nbsp;optionType,                  int&nbsp;messageType)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Brings up a modal dialog where the number of choices is determined by the <code>optionType</code> parameter, where the <code>messageType</code> parameter determines the icon to display.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showConfirmDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon)">showConfirmDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                  <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message,                  <A HREF="../../java/lang/String.html">String</A>&nbsp;title,                  int&nbsp;optionType,                  int&nbsp;messageType,                  <A HREF="../../javax/swing/Icon.html">Icon</A>&nbsp;icon)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Brings up a modal dialog with a specified icon, where the number of  choices is determined by the <code>optionType</code> parameter.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;<A HREF="../../java/lang/String.html">String</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showInputDialog(java.awt.Component, java.lang.Object)">showInputDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Shows a question-message dialog requesting input from the user parented to <code>parentComponent</code>.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;<A HREF="../../java/lang/String.html">String</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showInputDialog(java.awt.Component, java.lang.Object, java.lang.String, int)">showInputDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message,                <A HREF="../../java/lang/String.html">String</A>&nbsp;title,                int&nbsp;messageType)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Shows a dialog requesting input from the user parented to <code>parentComponent</code> with the dialog having the title <code>title</code> and message type <code>messageType</code>.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;<A HREF="../../java/lang/Object.html">Object</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showInputDialog(java.awt.Component, java.lang.Object, java.lang.String, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)">showInputDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message,                <A HREF="../../java/lang/String.html">String</A>&nbsp;title,                int&nbsp;messageType,                <A HREF="../../javax/swing/Icon.html">Icon</A>&nbsp;icon,                <A HREF="../../java/lang/Object.html">Object</A>[]&nbsp;selectionValues,                <A HREF="../../java/lang/Object.html">Object</A>&nbsp;initialSelectionValue)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Prompts the user for input in a blocking dialog where the initial selection, possible selections, and all other options can be specified.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;<A HREF="../../java/lang/String.html">String</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showInputDialog(java.lang.Object)">showInputDialog</A></B>(<A HREF="../../java/lang/Object.html">Object</A>&nbsp;message)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Shows a question-message dialog requesting input from the user.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showInternalConfirmDialog(java.awt.Component, java.lang.Object)">showInternalConfirmDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                          <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Brings up an internal dialog panel with the options Yes, No  and Cancel; with the title, "Select an Option".</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showInternalConfirmDialog(java.awt.Component, java.lang.Object, java.lang.String, int)">showInternalConfirmDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                          <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message,                          <A HREF="../../java/lang/String.html">String</A>&nbsp;title,                          int&nbsp;optionType)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Brings up a internal dialog panel where the number of choices  is determined by the <code>optionType</code> parameter.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showInternalConfirmDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int)">showInternalConfirmDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                          <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message,                          <A HREF="../../java/lang/String.html">String</A>&nbsp;title,                          int&nbsp;optionType,                          int&nbsp;messageType)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Brings up an internal dialog panel where the number of choices is determined by the <code>optionType</code> parameter, where the <code>messageType</code> parameter determines the icon to display.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;int</CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showInternalConfirmDialog(java.awt.Component, java.lang.Object, java.lang.String, int, int, javax.swing.Icon)">showInternalConfirmDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                          <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message,                          <A HREF="../../java/lang/String.html">String</A>&nbsp;title,                          int&nbsp;optionType,                          int&nbsp;messageType,                          <A HREF="../../javax/swing/Icon.html">Icon</A>&nbsp;icon)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Brings up an internal dialog panel with a specified icon, where the number of choices is determined by the <code>optionType</code> parameter.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;<A HREF="../../java/lang/String.html">String</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showInternalInputDialog(java.awt.Component, java.lang.Object)">showInternalInputDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                        <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Shows an internal question-message dialog requesting input from the user parented to  <code>parentComponent</code>.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;<A HREF="../../java/lang/String.html">String</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showInternalInputDialog(java.awt.Component, java.lang.Object, java.lang.String, int)">showInternalInputDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                        <A HREF="../../java/lang/Object.html">Object</A>&nbsp;message,                        <A HREF="../../java/lang/String.html">String</A>&nbsp;title,                        int&nbsp;messageType)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Shows an internal dialog requesting input from the user parented to <code>parentComponent</code> with the dialog having the title <code>title</code> and message type <code>messageType</code>.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;<A HREF="../../java/lang/Object.html">Object</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/swing/JOptionPane.html#showInternalInputDialog(java.awt.Component, java.lang.Object, java.lang.String, int, javax.swing.Icon, java.lang.Object[], java.lang.Object)">showInternalInputDialog</A></B>(<A HREF="../../java/awt/Component.html">Component</A>&nbsp;parentComponent,                        <A HREF="../../java/lang/Object.html

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -