Main Page | Modules | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

OmgScraperPluginInterface Class Reference
[Library]

#include <omgscraperplugininterface.h>

Inheritance diagram for OmgScraperPluginInterface:

Inheritance graph
[legend]
Collaboration diagram for OmgScraperPluginInterface:

Collaboration graph
[legend]
List of all members.

Detailed Description

An abstract base class that provides the mandatory api for all 'scraper' plugins. These are plugins that know how to fetch locality data from online databases.

Definition at line 36 of file omgscraperplugininterface.h.

Public Member Functions

virtual ~OmgScraperPluginInterface ()
virtual bool search (QString theTaxonName, QString theFileName)=0
void setMinimumRecords (int theMinimum)
virtual const QString getName ()=0
virtual const QString getLicense ()=0
virtual const OmgPluginMessengergetMessenger ()

Protected Types

typedef QVector< OmgLocalityLocalityVector

Protected Member Functions

 OmgScraperPluginInterface ()
void createShapefile (QString theShapefileName)
QString createTextFile (QString theShapefileName)

Protected Attributes

LocalityVector mLocalityVector
QString mTaxonName
QString mFileName
int mMinimumRecords
OmgPluginMessenger mMessenger


Member Typedef Documentation

typedef QVector<OmgLocality> OmgScraperPluginInterface::LocalityVector [protected]
 

Definition at line 59 of file omgscraperplugininterface.h.


Constructor & Destructor Documentation

OmgScraperPluginInterface::~OmgScraperPluginInterface  )  [virtual]
 

Definition at line 31 of file omgscraperplugininterface.cpp.

OmgScraperPluginInterface::OmgScraperPluginInterface  )  [inline, protected]
 

The default constructor is protected so that no besides inheriting classes can use it!

Definition at line 59 of file omgscraperplugininterface.h.


Member Function Documentation

void OmgScraperPluginInterface::createShapefile QString  theShapefileName  )  [protected]
 

Definition at line 83 of file omgscraperplugininterface.cpp.

References Omgui::localitiesToShapefile(), mLocalityVector, and mMinimumRecords.

Referenced by OmgScraperGbif::localitiesRequestDone(), OmgScraperSplink::search(), and OmgScraperGbifRest::search().

Here is the call graph for this function:

QString OmgScraperPluginInterface::createTextFile QString  theShapefileName  )  [protected]
 

Create an output text file.

Note:
Takes a shapefile name, strips the .shp off and saves a text file .txt

Definition at line 49 of file omgscraperplugininterface.cpp.

References OmgPluginMessenger::emitError(), OmgLocality::id(), OmgLocality::label(), OmgLocality::latitude(), OmgLocality::longitude(), mLocalityVector, mMessenger, and mMinimumRecords.

Referenced by OmgScraperGbif::localitiesRequestDone(), OmgScraperSplink::search(), and OmgScraperGbifRest::search().

Here is the call graph for this function:

virtual const QString OmgScraperPluginInterface::getLicense  )  [pure virtual]
 

Implemented in OmgScraperGbif, OmgScraperGbifRest, and OmgScraperSplink.

const OmgPluginMessenger * OmgScraperPluginInterface::getMessenger  )  [virtual]
 

Get a pointer to the plugin messenger instance associated with this plugin. The pluginmessenger is used to relay signals between the application using the plugin and the plugin itself. Ideally we would just make the plugin interface inherit qobject and implement the signals directly in the interface, but this approach only works on mac and linux at the moment so we resort to this slightly more cumbersome appraoch.

Returns:
OmgPluginMessenger *

Definition at line 35 of file omgscraperplugininterface.cpp.

References mMessenger.

Referenced by OmgDataFetcherWizardProgressPage::search().

virtual const QString OmgScraperPluginInterface::getName  )  [pure virtual]
 

Implemented in OmgScraperGbif, OmgScraperGbifRest, and OmgScraperSplink.

Referenced by OmgScraperPluginRegistry::OmgScraperPluginRegistry(), and OmgDataFetcherWizardProgressPage::search().

virtual bool OmgScraperPluginInterface::search QString  theTaxonName,
QString  theFileName
[pure virtual]
 

Implemented in OmgScraperGbif, OmgScraperGbifRest, and OmgScraperSplink.

Referenced by OmgDataFetcherWizardProgressPage::search().

void OmgScraperPluginInterface::setMinimumRecords int  theMinimum  ) 
 

Definition at line 40 of file omgscraperplugininterface.cpp.

References mMinimumRecords.

Referenced by OmgDataFetcherWizardProgressPage::search().


Member Data Documentation

QString OmgScraperPluginInterface::mFileName [protected]
 

Definition at line 63 of file omgscraperplugininterface.h.

LocalityVector OmgScraperPluginInterface::mLocalityVector [protected]
 

Definition at line 61 of file omgscraperplugininterface.h.

Referenced by createShapefile(), and createTextFile().

OmgPluginMessenger OmgScraperPluginInterface::mMessenger [protected]
 

The plugin messenger instance associated with this plugin

Definition at line 72 of file omgscraperplugininterface.h.

Referenced by createTextFile(), and getMessenger().

int OmgScraperPluginInterface::mMinimumRecords [protected]
 

Definition at line 64 of file omgscraperplugininterface.h.

Referenced by createShapefile(), createTextFile(), and setMinimumRecords().

QString OmgScraperPluginInterface::mTaxonName [protected]
 

Definition at line 62 of file omgscraperplugininterface.h.


The documentation for this class was generated from the following files:
Generated on Mon Apr 28 15:13:59 2008 for openModellerDesktop by  doxygen 1.4.1-20050210