public class PathChooser
extends java.lang.Object
FileChooser equivalent handling Paths instead of Files.FileChooser| Constructor | Description |
|---|---|
PathChooser() |
Crates a new
PathChooser. |
| Modifier and Type | Method | Description |
|---|---|---|
javafx.collections.ObservableList<javafx.stage.FileChooser.ExtensionFilter> |
getExtensionFilters() |
Returns the extension filters of the displayed file dialog.
|
java.nio.file.Path |
getInitialDirectory() |
Returns the initial directory of the displayed file dialog.
|
java.lang.String |
getInitialFileName() |
Returns the initial file name of the displayed file dialog.
|
javafx.stage.FileChooser.ExtensionFilter |
getSelectedExtensionFilter() |
Returns the selected extension filter of the displayed file dialog.
|
java.lang.String |
getTitle() |
Returns the title of the displayed file dialog.
|
javafx.beans.property.ObjectProperty<java.nio.file.Path> |
initialDirectoryProperty() |
Returns the property for the initial directory of the displayed file dialog.
|
javafx.beans.property.ObjectProperty<java.lang.String> |
initialFileNameProperty() |
Returns the property for the initial file name of the displayed file dialog.
|
javafx.beans.property.ObjectProperty<javafx.stage.FileChooser.ExtensionFilter> |
selectedExtensionFilterProperty() |
Returns the property for the selected extension filter of the displayed file dialog.
|
void |
setInitialDirectory(java.nio.file.Path directory) |
Sets the initial directory of the displayed file dialog.
|
void |
setInitialFileName(java.lang.String fileName) |
Sets the initial file name of the displayed file dialog.
|
void |
setSelectedExtensionFilter(javafx.stage.FileChooser.ExtensionFilter extensionFilter) |
Sets the selected extension filter of the displayed file dialog.
|
void |
setTitle(java.lang.String title) |
Sets the title of the displayed file dialog.
|
java.util.Optional<java.nio.file.Path> |
showOpenDialog(javafx.stage.Window ownerWindow) |
Shows a file open dialog.
|
java.util.List<java.nio.file.Path> |
showOpenMultipleDialog(javafx.stage.Window ownerWindow) |
Shows a file open dialog in which multiple files can be selected.
|
java.util.Optional<java.nio.file.Path> |
showSaveDialog(javafx.stage.Window ownerWindow) |
Shows a file save dialog.
|
javafx.beans.property.StringProperty |
titleProperty() |
Returns the property for the title of the displayed file dialog.
|
public javafx.collections.ObservableList<javafx.stage.FileChooser.ExtensionFilter> getExtensionFilters()
public java.nio.file.Path getInitialDirectory()
public java.lang.String getInitialFileName()
public javafx.stage.FileChooser.ExtensionFilter getSelectedExtensionFilter()
public java.lang.String getTitle()
public javafx.beans.property.ObjectProperty<java.nio.file.Path> initialDirectoryProperty()
public javafx.beans.property.ObjectProperty<java.lang.String> initialFileNameProperty()
public javafx.beans.property.ObjectProperty<javafx.stage.FileChooser.ExtensionFilter> selectedExtensionFilterProperty()
public void setInitialDirectory(java.nio.file.Path directory)
java.lang.IllegalArgumentException - if directory is nullpublic void setInitialFileName(java.lang.String fileName)
java.lang.IllegalArgumentException - if fileName is null or emptypublic void setSelectedExtensionFilter(javafx.stage.FileChooser.ExtensionFilter extensionFilter)
java.lang.IllegalArgumentException - if extensionFilter is nullpublic void setTitle(java.lang.String title)
java.lang.IllegalArgumentException - if title is null or emptypublic java.util.Optional<java.nio.file.Path> showOpenDialog(javafx.stage.Window ownerWindow)
public java.util.List<java.nio.file.Path> showOpenMultipleDialog(javafx.stage.Window ownerWindow)
public java.util.Optional<java.nio.file.Path> showSaveDialog(javafx.stage.Window ownerWindow)
public javafx.beans.property.StringProperty titleProperty()