Class FileFilters

  • java.lang.Object
    • javax.swing.filechooser.FileFilter

  • public class FileFilters
    extends javax.swing.filechooser.FileFilter
    Implements a set of file filters for the file types used by BeatRoot. An object of this class represents a specific file type, which is identified by the extension of the file name.
    • Field Detail

      • csvFileFilter

        public static final FileFilters csvFileFilter
      • description

        protected java.lang.String description
        A text description of this file type
      • matchFileFilter

        public static final FileFilters matchFileFilter
      • midiFileFilter

        public static final FileFilters midiFileFilter
      • sndFileFilter

        public static final FileFilters sndFileFilter
      • suffix

        protected java.lang.String suffix
        The extension corresponding to this file type
      • textFileFilter

        public static final FileFilters textFileFilter
      • tmfFileFilter

        public static final FileFilters tmfFileFilter
      • waveFileFilter

        public static final FileFilters waveFileFilter
    • Constructor Detail

      • FileFilters

        public FileFilters(java.lang.String suff,
                           java.lang.String desc)
        suff - The extension (suffix) of the file name
        desc - A text description of the file type
    • Method Detail

      • accept

        public boolean accept( f)
        Checks file names for a given extension.
        Specified by:
        accept in class javax.swing.filechooser.FileFilter
        f - The File object whose name is to be checked
        True for directories and files with the given extension.
      • getDescription

        public java.lang.String getDescription()
        The description of the file type used in the file dialog's choice box.
        Specified by:
        getDescription in class javax.swing.filechooser.FileFilter
        A String describing the file type.