JGraphpad Pro
v6.0.5.0


com.jgraph.pad.util
Class JGraphpadFileFilter.ImageFileFilter

java.lang.Object
  extended byjavax.swing.filechooser.FileFilter
      extended bycom.jgraph.pad.util.JGraphpadFileFilter.ImageFileFilter
Enclosing class:
JGraphpadFileFilter

public static class JGraphpadFileFilter.ImageFileFilter
extends FileFilter

Utility file filter to accept all image formats supported by image io.

See Also:
ImageIO.getReaderFormatNames()

Field Summary
protected  String desc
          Description of the filter.
protected static String[] imageFormats
          Holds the accepted file format extensions for images.
 
Constructor Summary
JGraphpadFileFilter.ImageFileFilter(String description)
          Constructs a new file filter for all supported image formats using the specified description.
 
Method Summary
 boolean accept(File file)
          Returns true if the file is a directory or ends with a known image extension.
 String getDescription()
          Returns the description.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

imageFormats

protected static String[] imageFormats
Holds the accepted file format extensions for images.


desc

protected String desc
Description of the filter.

Constructor Detail

JGraphpadFileFilter.ImageFileFilter

public JGraphpadFileFilter.ImageFileFilter(String description)
Constructs a new file filter for all supported image formats using the specified description.

Parameters:
description - The description to use for the file filter.
Method Detail

accept

public boolean accept(File file)
Returns true if the file is a directory or ends with a known image extension.

Parameters:
file - The file to be checked.
Returns:
Returns true if the file is accepted.

getDescription

public String getDescription()
Returns the description.

Returns:
Returns the description.

JGraphpad Pro
v6.0.5.0


Copyright (C) 2005 JGraph.com. All rights reserved.