dxcoupling.h

00001 /***************************************************************************
00002  *   Copyright (C) 2003 by Gav Wood                                        *
00003  *   gav@cs.york.ac.uk                                                     *
00004  *                                                                         *
00005  *   This program is free software; you can redistribute it and/or modify  *
00006  *   it under the terms of the GNU Library General Public License as       *
00007  *   published by the Free Software Foundation; either version 2 of the    *
00008  *   License, or (at your option) any later version.                       *
00009  ***************************************************************************/
00010 #ifndef _GEDDEI_DXCOUPLING_H
00011 #define _GEDDEI_DXCOUPLING_H
00012 
00013 #include <qmutex.h>
00014 
00015 #ifdef __GEDDEI_BUILD
00016 #include "qfastwaitcondition.h"
00017 #include "xxcoupling.h"
00018 #else
00019 #include <qtextra/qfastwaitcondition.h>
00020 #include <geddei/xxcoupling.h>
00021 #endif
00022 
00023 namespace Geddei
00024 {
00025 
00026 class DomProcessor;
00027 class BufferReader;
00028 
00046 class DxCoupling : virtual public xxCoupling
00047 {
00048  //* Reimplementations from xxCoupling
00049  virtual void stoppingL();
00050  virtual void stoppedL();
00051 
00058  const bool transactCheckerUNSAFE();
00059 
00060 protected:
00061  // TODO: Look into moving any accesses to theReaders into this class to get rid of friend.
00062  friend class DomProcessor;
00063 
00064  DomProcessor *theDomProcessor;
00065  QValueVector<BufferReader *> theReaders;
00066 
00067  int theLoad;
00068  uint theLastTimeTaken;
00069 
00070 public:
00074  void skip(const uint samples);
00075 
00080  void skipPlungeAndSend(const uint samples);
00081 
00086  void peekAndSend(const uint samples, const uint chunks);
00087 
00096  BufferDatas returnResults();
00097 
00101  DxCoupling(DomProcessor *dom);
00102 
00106  virtual ~DxCoupling();
00107 };
00108 
00109 
00110 };
00111 
00112 #endif

Generated on Fri Nov 10 21:58:26 2006 for Exscalibar by  doxygen 1.5.1