tufao  0.8.1
An asynchronous web framework for C++ built on top of Qt
 All Classes Namespaces Functions Variables Enumerations Enumerator Pages
Tufao::AbstractHttpServerRequestHandlerFactory Class Referenceabstract

This class provides an factory interface to create AbstractHttpServerRequestHandler objects. More...

+ Collaboration diagram for Tufao::AbstractHttpServerRequestHandlerFactory:

Public Member Functions

virtual
AbstractHttpServerRequestHandler
createHandler (QObject *parent)=0
 Creates one handler. More...
 

Detailed Description

This class provides an factory interface to create AbstractHttpServerRequestHandler objects.

If you want to implement plugins to interact with HttpPluginServer, then you need to make your plugins implement this interface.

#ifndef PLUGIN_H
#define PLUGIN_H
#include <Tufao/AbstractHttpServerRequestHandlerFactory>
{
Q_OBJECT
public:
explicit Plugin(QObject *parent = 0);
Tufao::AbstractHttpServerRequestHandler *createHandler(QObject *parent);
};
#endif // PLUGIN_H
#include "plugin.h"
#include "requesthandler.h"
#include <QtCore/QtPlugin>
Plugin::Plugin(QObject *parent) :
QObject(parent)
{
}
Tufao::AbstractHttpServerRequestHandler *Plugin::createHandler(QObject *parent)
{
return new RequestHandler(parent);
}
Q_EXPORT_PLUGIN2(PLUGIN, Plugin)
Since
0.3

Member Function Documentation

virtual AbstractHttpServerRequestHandler* Tufao::AbstractHttpServerRequestHandlerFactory::createHandler ( QObject *  parent)
pure virtual

Creates one handler.

All handlers created by this method should return objects with similar behaviour (e.g. returning objects from the same class).


The documentation for this class was generated from the following file: