uk.ac.kcl.cch.jb.pliny.views.utils
Interface IPlinyImporter

All Known Implementing Classes:
PlinyArchiveImporter, PlinyTxtImporter

public interface IPlinyImporter

code that wishes to act as an importer for Pliny data must implement this interface. It will be called by the importer Action.

Author:
John Bradley
See Also:
ResourceExplorerImportAction

Method Summary
 boolean getOptions(org.eclipse.swt.widgets.Shell parentShell)
          the importer will call this method when it is time to get options from the user that will control this importer.
 void run(org.eclipse.core.runtime.IProgressMonitor monitor)
          the exportAction will call this method when it is time to do the import.
 void setFileName(String fileName)
          the export Action will call this method to provide a String containing the fully qualified fileName that is to be used for the import.
 

Method Detail

getOptions

public boolean getOptions(org.eclipse.swt.widgets.Shell parentShell)
the importer will call this method when it is time to get options from the user that will control this importer. The return value is true if the user has confirmed that the import is to go ahead. Simply return true and do nothing else if there are no options to be provided. If there are options, this code should invoke a wizard to get them from the user.

Parameters:
parentShell - Shell to be used to support display of a wizard for options.
Returns:
true if user wants to proceed to actual import

setFileName

public void setFileName(String fileName)
the export Action will call this method to provide a String containing the fully qualified fileName that is to be used for the import.

Parameters:
fileName -

run

public void run(org.eclipse.core.runtime.IProgressMonitor monitor)
         throws PlinyImportException
the exportAction will call this method when it is time to do the import.

Parameters:
monitor - monitor to be used during the import
Throws:
PlinyImportException - all internally arising exceptions should be converted to this exception