DABC (Data Acquisition Backbone Core)  2.9.9
eventsapi.cxx
Go to the documentation of this file.
1 // $Id$
2 
3 /************************************************************
4  * The Data Acquisition Backbone Core (DABC) *
5  ************************************************************
6  * Copyright (C) 2009 - *
7  * GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
8  * Planckstr. 1, 64291 Darmstadt, Germany *
9  * Contact: http://dabc.gsi.de *
10  ************************************************************
11  * This software can be used under the GPL license *
12  * agreements as stated in LICENSE.txt file *
13  * which is part of the distribution. *
14  ************************************************************/
15 
16 #include "dabc/eventsapi.h"
17 
18 // ======================================================================================
19 
21 {
22  if (!Assign(buf)) return 0;
23  unsigned cnt = 0;
24  while (NextEvent()) cnt++;
25  Close();
26  return cnt;
27 }
Reference on memory from memory pool.
Definition: Buffer.h:135
virtual void Close()=0
virtual bool Assign(const Buffer &buf)=0
virtual bool NextEvent()=0
unsigned NumEvents(const Buffer &buf)
Definition: eventsapi.cxx:20