audiojury.gui.admin
Class ResultfileFilter

java.lang.Object
  |
  +--javax.swing.filechooser.FileFilter
        |
        +--audiojury.gui.admin.ResultfileFilter

public class ResultfileFilter
extends javax.swing.filechooser.FileFilter

A filter approving ajr-files containing ProjectResults. Extends the FileFilter to filter and accept these files, which has the extension 'ajr'.


Constructor Summary
ResultfileFilter()
           
 
Method Summary
 boolean accept(java.io.File f)
          Checks a File is a ajr-file or not (or a directory).
 java.lang.String getDescription()
          Retrieves a short description of this filter.
static java.lang.String getExtension(java.io.File f)
          Retrieves the extension of a File.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResultfileFilter

public ResultfileFilter()
Method Detail

accept

public boolean accept(java.io.File f)
Checks a File is a ajr-file or not (or a directory). This check is done by looking at the file extension. Directories are also accepted.

Specified by:
accept in class javax.swing.filechooser.FileFilter
Parameters:
f - Checks a File is a supported sound file or not (or a directory). This check is done by looking at the file extension. Direcotries are also accepted.
Returns:
boolean indicating if the file is accepted by this filter or not.

getExtension

public static java.lang.String getExtension(java.io.File f)
Retrieves the extension of a File.

Parameters:
f - File to retrive the extension from.
Returns:
String with the extension from the File.

getDescription

public java.lang.String getDescription()
Retrieves a short description of this filter.

Specified by:
getDescription in class javax.swing.filechooser.FileFilter
Returns:
String with a short description of the filter.