Collage  1.3.0
High-performance C++ library for developing object-oriented distributed applications.
customOCommand.h
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_CUSTOMOCOMMAND_H
21 #define CO_CUSTOMOCOMMAND_H
22 
23 #include <co/oCommand.h> // base class
24 
25 namespace co
26 {
27 namespace detail { class CustomOCommand; }
28 
33 class CustomOCommand : public OCommand
34 {
35 public:
43  CO_API CustomOCommand( const Connections& receivers,
44  const uint128_t& commandID );
45 
52  CO_API CustomOCommand( LocalNodePtr localNode, const uint128_t& commandID );
53 
54  CO_API CustomOCommand( const CustomOCommand& rhs );
55 
57  CO_API virtual ~CustomOCommand();
58 
59 private:
60  CustomOCommand();
61  CustomOCommand& operator = ( const CustomOCommand& );
62  detail::CustomOCommand* const _impl;
63 
64  void _init();
65 };
66 }
67 
68 #endif //CO_CUSTOMOCOMMAND_H
std::vector< ConnectionPtr > Connections
A vector of ConnectionPtr's.
Definition: types.h:126
lunchbox::RefPtr< LocalNode > LocalNodePtr
A reference pointer for LocalNode pointers.
Definition: types.h:91
A class for sending custom commands and data to nodes.
Object-oriented network library.
Definition: barrier.h:27
virtual CO_API ~CustomOCommand()
Send or dispatch this command during destruction.
A class for sending commands with data to local and external nodes.
Definition: oCommand.h:40