# Uses of Class
javafx.scene.control.ButtonType

Packages that use ButtonType
Package
Description
javafx.scene.control
The JavaFX User Interface Controls (UI Controls or just Controls) are specialized Nodes in the JavaFX Scenegraph especially suited for reuse in many different application contexts.

- ## Uses of ButtonType in javafx.scene.control

  Fields in javafx.scene.control declared as ButtonType
  Modifier and Type
  Field
  Description
  `static final ButtonType`
  ButtonType.`APPLY`
  A pre-defined `ButtonType` that displays "Apply" and has a `ButtonBar.ButtonData` of `ButtonBar.ButtonData.APPLY`.
  `static final ButtonType`
  ButtonType.`CANCEL`
  A pre-defined `ButtonType` that displays "Cancel" and has a `ButtonBar.ButtonData` of `ButtonBar.ButtonData.CANCEL_CLOSE`.
  `static final ButtonType`
  ButtonType.`CLOSE`
  A pre-defined `ButtonType` that displays "Close" and has a `ButtonBar.ButtonData` of `ButtonBar.ButtonData.CANCEL_CLOSE`.
  `static final ButtonType`
  ButtonType.`FINISH`
  A pre-defined `ButtonType` that displays "Finish" and has a `ButtonBar.ButtonData` of `ButtonBar.ButtonData.FINISH`.
  `static final ButtonType`
  ButtonType.`NEXT`
  A pre-defined `ButtonType` that displays "Next" and has a `ButtonBar.ButtonData` of `ButtonBar.ButtonData.NEXT_FORWARD`.
  `static final ButtonType`
  ButtonType.`NO`
  A pre-defined `ButtonType` that displays "No" and has a `ButtonBar.ButtonData` of `ButtonBar.ButtonData.NO`.
  `static final ButtonType`
  ButtonType.`OK`
  A pre-defined `ButtonType` that displays "OK" and has a `ButtonBar.ButtonData` of `ButtonBar.ButtonData.OK_DONE`.
  `static final ButtonType`
  ButtonType.`PREVIOUS`
  A pre-defined `ButtonType` that displays "Previous" and has a `ButtonBar.ButtonData` of `ButtonBar.ButtonData.BACK_PREVIOUS`.
  `static final ButtonType`
  ButtonType.`YES`
  A pre-defined `ButtonType` that displays "Yes" and has a `ButtonBar.ButtonData` of `ButtonBar.ButtonData.YES`.
  Methods in javafx.scene.control that return types with arguments of type ButtonType
  Modifier and Type
  Method
  Description
  `final ObservableList<ButtonType>`
  Alert.`getButtonTypes()`
  Returns an `ObservableList` of all `ButtonType` instances that are currently set inside this Alert instance.
  `final ObservableList<ButtonType>`
  DialogPane.`getButtonTypes()`
  Observable list of button types used for the dialog button bar area (created via the `DialogPane.createButtonBar()` method).
  `final Callback<ButtonType,R>`
  Dialog.`getResultConverter()`
  Gets the value of the `resultConverter` property.
  `final ObjectProperty<Callback<ButtonType,R>>`
  Dialog.`resultConverterProperty()`
  API to convert the `ButtonType` that the user clicked on into a result that can be returned via the `result` property.
  Methods in javafx.scene.control with parameters of type ButtonType
  Modifier and Type
  Method
  Description
  `protected Node`
  DialogPane.`createButton(ButtonType buttonType)`
  This method can be overridden by subclasses to create a custom button that will subsequently inserted into the DialogPane button area (created via the `DialogPane.createButtonBar()` method, but mostly commonly it is an instance of `ButtonBar`.
  `final Node`
  DialogPane.`lookupButton(ButtonType buttonType)`
  This method provides a way in which developers may retrieve the actual Node for a given `ButtonType` (assuming it is part of the `button types` list).
  Method parameters in javafx.scene.control with type arguments of type ButtonType
  Modifier and Type
  Method
  Description
  `final void`
  Dialog.`setResultConverter(Callback<ButtonType,R> value)`
  Sets the value of the `resultConverter` property.
  Constructors in javafx.scene.control with parameters of type ButtonType
  Modifier
  Constructor
  Description
  ``
  `Alert(Alert.AlertType alertType, String contentText, ButtonType... buttons)`
  Creates an alert with the given contentText, ButtonTypes, and AlertType (refer to the `Alert.AlertType` documentation for clarification over which one is most appropriate).