FileDocCategorySizeDatePackage
ImageFileView.javaAPI DocExample1788Tue Dec 12 18:59:20 GMT 2000None

ImageFileView

public class ImageFileView extends FileView

Fields Summary
ImageIcon
jpgIcon
ImageIcon
gifIcon
ImageIcon
tiffIcon
Constructors Summary
Methods Summary
public java.lang.StringgetDescription(java.io.File f)

        return null; // let the L&F FileView figure this out
    
public javax.swing.IcongetIcon(java.io.File f)

        String extension = Utils.getExtension(f);
        Icon icon = null;

        if (extension != null) {
            if (extension.equals(Utils.jpeg) ||
                extension.equals(Utils.jpg)) {
                icon = jpgIcon;
            } else if (extension.equals(Utils.gif)) {
                icon = gifIcon;
            } else if (extension.equals(Utils.tiff) ||
                       extension.equals(Utils.tif)) {
                icon = tiffIcon;
            } 
        }
        return icon;
    
public java.lang.StringgetName(java.io.File f)

    
        
        return null; // let the L&F FileView figure this out
    
public java.lang.StringgetTypeDescription(java.io.File f)

        String extension = Utils.getExtension(f);
        String type = null;

        if (extension != null) {
            if (extension.equals(Utils.jpeg) ||
                extension.equals(Utils.jpg)) {
                type = "JPEG Image";
            } else if (extension.equals(Utils.gif)){
                type = "GIF Image";
            } else if (extension.equals(Utils.tiff) ||
                       extension.equals(Utils.tif)) {
                type = "TIFF Image";
            } 
        }
        return type;
    
public java.lang.BooleanisTraversable(java.io.File f)

        return null; // let the L&F FileView figure this out