Scorum
api_template.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 namespace scorum {
4 namespace app {
5 
6 template <class T> class api_obj : public T
7 {
8  struct constructor
9  {
10  void operator()(const T&)
11  {
12  }
13  };
14 
15 public:
17  : T(constructor(), std::allocator<T>())
18  {
19  }
20 
21  api_obj(const T& other)
22  : T(constructor(), std::allocator<T>())
23  {
24  T& base = static_cast<T&>(*this);
25  base = other;
26  }
27 };
28 }
29 }
api_obj(const T &other)
Definition: asset.cpp:15