com.mucommander.ui.viewer.image
Class ImageFactory

java.lang.Object
  extended by com.mucommander.ui.viewer.image.ImageFactory
All Implemented Interfaces:
ViewerFactory

public class ImageFactory
extends java.lang.Object
implements ViewerFactory

ViewerFactory implementation for creating image viewers.

Author:
Nicolas Rinaudo

Constructor Summary
ImageFactory()
           
 
Method Summary
 boolean canViewFile(AbstractFile file)
          Returns true if this factory can create a file viewer for the specified file.
 FileViewer createFileViewer()
          Returns a new instance of FileViewer.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ImageFactory

public ImageFactory()
Method Detail

canViewFile

public boolean canViewFile(AbstractFile file)
Description copied from interface: ViewerFactory
Returns true if this factory can create a file viewer for the specified file.

The FileEditor may base its decision stricly upon the file's name and its extension or may wish to read some of the file and compare it to a magic number.

Specified by:
canViewFile in interface ViewerFactory
Parameters:
file - file for which a viewer must be created.
Returns:
true if this factory can create a file viewer for the specified file.

createFileViewer

public FileViewer createFileViewer()
Description copied from interface: ViewerFactory
Returns a new instance of FileViewer.

Specified by:
createFileViewer in interface ViewerFactory
Returns:
a new instance of FileViewer.


This file is part of muCommander - Copyright (C) 2002-2008 Maxence Bernard