Collage  1.7.0
High-performance C++ library for developing object-oriented distributed applications.
objectICommand.h
1 
2 /* Copyright (c) 2012-2017, Daniel Nachbaur <danielnachbaur@gmail.com>
3  * Stefan.Eilemann@epfl.ch
4  *
5  * This file is part of Collage <https://github.com/Eyescale/Collage>
6  *
7  * This library is free software; you can redistribute it and/or modify it under
8  * the terms of the GNU Lesser General Public License version 2.1 as published
9  * by the Free Software Foundation.
10  *
11  * This library is distributed in the hope that it will be useful, but WITHOUT
12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
13  * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
14  * details.
15  *
16  * You should have received a copy of the GNU Lesser General Public License
17  * along with this library; if not, write to the Free Software Foundation, Inc.,
18  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
19  */
20 
21 #ifndef CO_OBJECTICOMMAND_H
22 #define CO_OBJECTICOMMAND_H
23 
24 #include <co/iCommand.h> // base class
25 
26 namespace co
27 {
28 namespace detail
29 {
30 class ObjectICommand;
31 }
32 
34 class ObjectICommand : public ICommand
35 {
36 public:
38  CO_API ObjectICommand(LocalNodePtr local, NodePtr remote,
39  ConstBufferPtr buffer);
40 
42  // cppcheck-suppress noExplicitConstructor
43  CO_API ObjectICommand(const ICommand& command);
44 
46  CO_API ObjectICommand(const ObjectICommand& rhs);
47 
49  CO_API virtual ~ObjectICommand();
50 
52  const uint128_t& getObjectID() const;
53 
55  uint32_t getInstanceID() const;
56 
57 private:
58  ObjectICommand();
59  ObjectICommand& operator=(const ObjectICommand&);
60  detail::ObjectICommand* const _impl;
61 
62  void _init();
63 };
64 
66 CO_API std::ostream& operator<<(std::ostream& os, const ObjectICommand&);
67 }
68 
69 #endif // CO_OBJECTICOMMAND_H
lunchbox::RefPtr< LocalNode > LocalNodePtr
A reference pointer for LocalNode pointers.
Definition: types.h:89
Object-oriented network library.
Definition: barrier.h:27
A class managing received commands.
Definition: iCommand.h:45
An input command specialization for objects.
lunchbox::RefPtr< Node > NodePtr
A reference pointer for Node pointers.
Definition: types.h:85