RecogniserFactory Class Reference

The RecogniserFactory class creates AbstractRecogniser objects. More...

#include <recogniserfactory.h>

List of all members.

Static Public Member Functions

static const QList< QByteArray > & keys ()
static AbstractRecognisercreate (const QByteArray &key, JavaVM *jvm, DigestDbModel *digestDbModel, QObject *parent=0)
static QString title (const QByteArray &key)
static QString description (const QByteArray &key)
static void loadPlugins (JavaVM *jvm)
static void unloadPlugins ()


Detailed Description

The RecogniserFactory class creates AbstractRecogniser objects.

Note that QByteArray is more than enough for keys. There is no need for QString, and we definitely don't want the keys to be language dependant.

Also on the topic of QByteArray, from the Qt 4.0.0 documentation: "Using QByteArray is much more convenient than using const char *. Behind the scenes, it always ensures that the data is followed by a '\0' terminator, and uses implicit sharing (copy-on-write) to reduce memory usage and avoid needless copying of data."


Member Function Documentation

const QList< QByteArray > & RecogniserFactory::keys (  )  [static]

Warning: This method is not thread-safe until it returns from the first call.

AbstractRecogniser * RecogniserFactory::create ( const QByteArray &  key,
JavaVM *  jvm,
DigestDbModel digestDbModel,
QObject *  parent = 0 
) [static]

Creates an instance of a recogniser, specified using the given key. The jvm, digestDbModel and parent parameters are all passed directly to the given recogniser 's constructor as needed.

Note: Not all recogniser s make use of the jvm, but some do, such as JLinearRecogniser. Hence, to handle this generically, a valid Java Virtual Machine must always be passed.

Note: This method uses case in-sensitive key matching.

QString RecogniserFactory::title ( const QByteArray &  key  )  [static]

QString RecogniserFactory::description ( const QByteArray &  key  )  [static]

void RecogniserFactory::loadPlugins ( JavaVM *  jvm  )  [static]

Warning: This must not be called if any plugin created recognisers are still in use.

void RecogniserFactory::unloadPlugins (  )  [static]

Warning: This must not be called if any plugin created recognisers are still in use.


The documentation for this class was generated from the following files:
Generated on Mon Jul 30 09:46:53 2007 for Digest by  doxygen 1.5.2