Example usage for javax.swing JFileChooser getFileSelectionMode

List of usage examples for javax.swing JFileChooser getFileSelectionMode

Introduction

In this page you can find the example usage for javax.swing JFileChooser getFileSelectionMode.

Prototype

public int getFileSelectionMode() 

Source Link

Document

Returns the current file-selection mode.

Usage

From source file:Main.java

public static void main(String[] a) {
    JFrame frame = new JFrame("JFileChooser Popup");
    frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);

    JFileChooser fileChooser = new JFileChooser(".");

    int mode = fileChooser.getFileSelectionMode();
    frame.add(fileChooser, BorderLayout.CENTER);

    frame.pack();//w w w .j  ava2  s  .co m
    frame.setVisible(true);
}