Line data Source code
1 :
2 : /* Copyright (c) 2012, Daniel Nachbaur <danielnachbaur@gmail.com>
3 : *
4 : * This file is part of Collage <https://github.com/Eyescale/Collage>
5 : *
6 : * This library is free software; you can redistribute it and/or modify it under
7 : * the terms of the GNU Lesser General Public License version 2.1 as published
8 : * by the Free Software Foundation.
9 : *
10 : * This library is distributed in the hope that it will be useful, but WITHOUT
11 : * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12 : * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
13 : * details.
14 : *
15 : * You should have received a copy of the GNU Lesser General Public License
16 : * along with this library; if not, write to the Free Software Foundation, Inc.,
17 : * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18 : */
19 :
20 : #ifndef CO_QUEUEITEM_H
21 : #define CO_QUEUEITEM_H
22 :
23 : #include <co/dataOStream.h> // base class
24 : #include <co/types.h>
25 :
26 : namespace co
27 : {
28 : namespace detail
29 : {
30 : class QueueItem;
31 : }
32 :
33 : /**
34 : * The item of the distributed queue holding the data.
35 : *
36 : * Each enqueued item generated by QueueMaster::push() can be enhanced with
37 : * additional data in a stream-like manner. On the consumer side, the data can
38 : * be retrieved via the ObjectICommand.
39 : */
40 : class QueueItem : public DataOStream
41 : {
42 : public:
43 : /** Destruct this queue item. @version 1.0 */
44 : CO_API ~QueueItem();
45 :
46 : private:
47 : friend class QueueMaster;
48 :
49 : QueueItem(const QueueItem& rhs);
50 : explicit QueueItem(QueueMaster& master);
51 :
52 0 : void sendData(const void*, const uint64_t, const bool) override
53 : {
54 0 : LBDONTCALL
55 0 : }
56 :
57 : detail::QueueItem* const _impl;
58 : };
59 : }
60 :
61 : #endif // CO_QUEUEITEM_H
|