fatalmind::Command< PT > Class Template Reference

#include <Command.hh>

Inherits fatalmind::Clone.

Inherited by fatalmind::mysql::SQLExecute, fatalmind::mysql::SQLSelect, fatalmind::mysql::Transaction, fatalmind::SQL::RTSQLCommand< TM >, and fatalmind::SQL::RTSQLTransaction< TM >.

List of all members.


Detailed Description

template<class PT>
class fatalmind::Command< PT >

The base class for all commands to be executed by ResourcePool.

Public Types

typedef PT pool_type

Public Member Functions

virtual void execute (typename PT::resource_t &rr)=0
 The execute method is the one which actually carries out the work.
virtual void outputoperator (std::ostream &) const
Clone * clone () const
template<class Derived>
Derived * clone () const

Protected Member Functions

const PT::factory_t & getFactory (const ResourcePool< PT > &p) const
virtual Clone * DoClone () const =0

Friends

class _RPExecute< PT >

Member Function Documentation

template<class PT>
virtual void fatalmind::Command< PT >::execute ( typename PT::resource_t &  rr  )  [pure virtual]

The execute method is the one which actually carries out the work.

This method gets called by ResourcePool with a (valid) plain resource which was obtained from the pool.

On normal execution (no exception) the resource will be free()ed, on abnormal execution (exception) the resource will be failed. If you need to throw an functional exception which should not cause failing of the resource, derive this exception from NoFailoverException.


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

Generated on Mon Jun 9 11:27:03 2008 for ResourcePool by  doxygen 1.5.5