/*
 *  LookAndFeelFilter.java
 *
 *  Created on Jan 14, 2002, 1:25 PM
 * 
 */

package cse605;

/**
 *
 * @author  adev
 * @version 
 */
public class LookAndFeelFilter extends javax.swing.filechooser.FileFilter {

    /** Creates new CobFilter */
    public  LookAndFeelFilter() {
    }
   /**
    * Returns true if the file is a directory or its name ends with
    * .otm
    *
    * @param f the file in question
    * @return true if the file is a directory or its name ends 
    * with ".otm"
    *
    */
   public boolean accept(java.io.File f) {
      if ( f != null ) {
	 return f.isDirectory() ||
	    f.getName().endsWith(".otm");
      } // end of if ()
      return false;
   }

   /**
    * Returns the textual description of the filter.
    *
    * @return the textual description of the filter.
    */
   public String getDescription() {
      return "Look And Feel Files (*.otm)";
   }
}
