Drizzled Public API Documentation

transaction_reader.h
00001 /* -*- mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; -*-
00002  *  vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
00003  *
00004  *  Copyright (C) 2008-2009 Sun Microsystems, Inc.
00005  *
00006  *  Authors:
00007  *
00008  *    Jay Pipes <joinfu@sun.com>
00009  *
00010  *  This program is free software; you can redistribute it and/or modify
00011  *  it under the terms of the GNU General Public License as published by
00012  *  the Free Software Foundation; version 2 of the License.
00013  *
00014  *  This program is distributed in the hope that it will be useful,
00015  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00016  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00017  *  GNU General Public License for more details.
00018  *
00019  *  You should have received a copy of the GNU General Public License
00020  *  along with this program; if not, write to the Free Software
00021  *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
00022  */
00023 
00024 #pragma once
00025 
00026 #include <drizzled/plugin/plugin.h>
00027 #include <drizzled/replication_services.h> /* For global transaction ID typedef */
00028 
00029 #include <drizzled/visibility.h>
00030 
00037 namespace drizzled
00038 {
00039 namespace message { class Transaction; }
00040 
00041 namespace plugin
00042 {
00043 
00044 
00048 class DRIZZLED_API TransactionReader : public Plugin
00049 {
00050   TransactionReader();
00051   TransactionReader(const TransactionReader &);
00052   TransactionReader& operator=(const TransactionReader &);
00053 public:
00054   explicit TransactionReader(std::string name_arg)
00055    : Plugin(name_arg, "TransactionReader") {}
00056   virtual ~TransactionReader() {}
00070   virtual bool read(const ReplicationServices::GlobalTransactionId &to_read, 
00071                     message::Transaction *to_fill)= 0;
00072 };
00073 
00074 } /* end namespace plugin */
00075 } /* end namespace drizzled */
00076