Gridarta Editor
net.sf.gridarta.utils.FileChooserUtils Class Reference
+ Collaboration diagram for net.sf.gridarta.utils.FileChooserUtils:

Static Public Member Functions

static void sanitizeCurrentDirectory (@NotNull final JFileChooser fileChooser)
 
static void setCurrentDirectory (@NotNull final JFileChooser fileChooser, @Nullable final File dir)
 

Private Member Functions

 FileChooserUtils ()
 

Static Private Member Functions

static File sanitize (@Nullable final File dir)
 

Detailed Description

Utility class for JFileChooser related functions.

Author
Andreas Kirschbaum

Definition at line 31 of file FileChooserUtils.java.

Constructor & Destructor Documentation

◆ FileChooserUtils()

net.sf.gridarta.utils.FileChooserUtils.FileChooserUtils ( )
private

Private constructor to prevent instantiation.

Definition at line 36 of file FileChooserUtils.java.

Member Function Documentation

◆ sanitize()

static File net.sf.gridarta.utils.FileChooserUtils.sanitize ( @Nullable final File  dir)
staticprivate

Performs sanity checks on the given directory. Returns the given directory or one of its parent directories if it doesn't exist.

Parameters
dirthe directory to check
Returns
the existing directory

Definition at line 67 of file FileChooserUtils.java.

References net.sf.gridarta.utils.ConfigFileUtils.getHomeDir().

Referenced by net.sf.gridarta.utils.FileChooserUtils.setCurrentDirectory().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ sanitizeCurrentDirectory()

◆ setCurrentDirectory()

static void net.sf.gridarta.utils.FileChooserUtils.setCurrentDirectory ( @NotNull final JFileChooser  fileChooser,
@Nullable final File  dir 
)
static

The documentation for this class was generated from the following file: