You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-08-08 14:22:09 +03:00
Reformat all code to coding standard
This commit is contained in:
@@ -14,77 +14,83 @@
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
||||
MA 02110-1301, USA. */
|
||||
|
||||
/*******************************************************************************
|
||||
* $Id$
|
||||
*
|
||||
*******************************************************************************/
|
||||
|
||||
/*
|
||||
* we_cpifeederthread.h
|
||||
*
|
||||
* Created on: Mar 29, 2012
|
||||
* Author: bpaul
|
||||
*/
|
||||
|
||||
#ifndef WE_CPIFEEDERTHREAD_H_
|
||||
#define WE_CPIFEEDERTHREAD_H_
|
||||
|
||||
#include <queue>
|
||||
|
||||
namespace WriteEngine
|
||||
{
|
||||
|
||||
class WEDataLoader;
|
||||
class WECpiFeederThread;
|
||||
|
||||
class WECpiFeederRunner
|
||||
{
|
||||
public:
|
||||
WECpiFeederRunner(WECpiFeederThread& Ref): fOwner(Ref){ /* ctor */ }
|
||||
virtual ~WECpiFeederRunner(){/* dtor */}
|
||||
void operator()();
|
||||
|
||||
public:
|
||||
WECpiFeederThread& fOwner;
|
||||
};
|
||||
|
||||
|
||||
class WECpiFeederThread
|
||||
{
|
||||
public:
|
||||
WECpiFeederThread(WEDataLoader& Ref);
|
||||
virtual ~WECpiFeederThread();
|
||||
|
||||
public:
|
||||
void startFeederThread();
|
||||
void add2MsgQueue(messageqcpp::ByteStream& Ibs);
|
||||
void feedData2Cpi();
|
||||
void stopThread();
|
||||
bool isMsgQueueEmpty();
|
||||
//bool isPushing() { return fPushing; }
|
||||
bool isStopped() { return fStopped; }
|
||||
int getQueueSize() { return fMsgQueue.size(); }
|
||||
bool isContinue();
|
||||
private:
|
||||
|
||||
WEDataLoader& fOwner;
|
||||
|
||||
boost::condition fFeederCond;
|
||||
boost::mutex fMsgQMutex;
|
||||
typedef std::queue<messageqcpp::SBS> WEMsgQueue;
|
||||
WEMsgQueue fMsgQueue;
|
||||
|
||||
boost::thread *fpThread;
|
||||
bool fContinue;
|
||||
boost::mutex fContMutex;
|
||||
//bool fPushing;
|
||||
bool fStopped;
|
||||
|
||||
|
||||
friend class WEDataLoader;
|
||||
};
|
||||
|
||||
} /* namespace WriteEngine */
|
||||
|
||||
#endif /* WE_CPIFEEDERTHREAD_H_ */
|
||||
|
||||
/*******************************************************************************
|
||||
* $Id$
|
||||
*
|
||||
*******************************************************************************/
|
||||
|
||||
/*
|
||||
* we_cpifeederthread.h
|
||||
*
|
||||
* Created on: Mar 29, 2012
|
||||
* Author: bpaul
|
||||
*/
|
||||
|
||||
#ifndef WE_CPIFEEDERTHREAD_H_
|
||||
#define WE_CPIFEEDERTHREAD_H_
|
||||
|
||||
#include <queue>
|
||||
|
||||
namespace WriteEngine
|
||||
{
|
||||
|
||||
class WEDataLoader;
|
||||
class WECpiFeederThread;
|
||||
|
||||
class WECpiFeederRunner
|
||||
{
|
||||
public:
|
||||
WECpiFeederRunner(WECpiFeederThread& Ref): fOwner(Ref) { /* ctor */ }
|
||||
virtual ~WECpiFeederRunner() {/* dtor */}
|
||||
void operator()();
|
||||
|
||||
public:
|
||||
WECpiFeederThread& fOwner;
|
||||
};
|
||||
|
||||
|
||||
class WECpiFeederThread
|
||||
{
|
||||
public:
|
||||
WECpiFeederThread(WEDataLoader& Ref);
|
||||
virtual ~WECpiFeederThread();
|
||||
|
||||
public:
|
||||
void startFeederThread();
|
||||
void add2MsgQueue(messageqcpp::ByteStream& Ibs);
|
||||
void feedData2Cpi();
|
||||
void stopThread();
|
||||
bool isMsgQueueEmpty();
|
||||
//bool isPushing() { return fPushing; }
|
||||
bool isStopped()
|
||||
{
|
||||
return fStopped;
|
||||
}
|
||||
int getQueueSize()
|
||||
{
|
||||
return fMsgQueue.size();
|
||||
}
|
||||
bool isContinue();
|
||||
private:
|
||||
|
||||
WEDataLoader& fOwner;
|
||||
|
||||
boost::condition fFeederCond;
|
||||
boost::mutex fMsgQMutex;
|
||||
typedef std::queue<messageqcpp::SBS> WEMsgQueue;
|
||||
WEMsgQueue fMsgQueue;
|
||||
|
||||
boost::thread* fpThread;
|
||||
bool fContinue;
|
||||
boost::mutex fContMutex;
|
||||
//bool fPushing;
|
||||
bool fStopped;
|
||||
|
||||
|
||||
friend class WEDataLoader;
|
||||
};
|
||||
|
||||
} /* namespace WriteEngine */
|
||||
|
||||
#endif /* WE_CPIFEEDERTHREAD_H_ */
|
||||
|
Reference in New Issue
Block a user