Java JOptionPane Constructor's

javax.swing
Class JOptionPane

java.lang.Object
  extended byjava.awt.Component
      extended byjava.awt.Container
          extended byjavax.swing.JComponent
              extended byjavax.swing.JOptionPane
All Implemented Interfaces:
Accessible, ImageObserver, MenuContainer, Serializable

 

 

JOptionPane Constructor

 

 

 

JOptionPane()
Creates a JOptionPane with a test message.


JOptionPane(Object message)
Creates a instance of JOptionPane to display a message using the plain-message message type and the default options delivered by the UI.


JOptionPane(Object message, int messageType)
Creates an instance of JOptionPane to display a message with the specified message type and the default options,


JOptionPane(Object message, int messageType, int optionType)
Creates an instance of JOptionPane to display a message with the specified message type and options.


JOptionPane(Object message, int messageType, int optionType, Icon icon)
Creates an instance of JOptionPane to display a message with the specified message type, options, and icon.


JOptionPane(Object message, int messageType, int optionType, Icon icon, Object[] options)
Creates an instance of JOptionPane to display a message with the specified message type, icon, and options.


JOptionPane(Object message, int messageType, int optionType, Icon icon, Object[] options, Object initialValue)
Creates an instance of JOptionPane to display a message with the specified message type, icon, and options, with the initially-selected option specified.