OpenFPM_pdata  1.1.0
Project that contain the implementation of distributed structures
 All Data Structures Namespaces Functions Variables Typedefs Enumerations Friends Pages
vector_dist_key.hpp
1 /*
2  * vector_dist_key.hpp
3  *
4  * Created on: Mar 10, 2015
5  * Author: i-bird
6  */
7 
8 #ifndef VECTOR_DIST_KEY_HPP_
9 #define VECTOR_DIST_KEY_HPP_
10 
11 
12 
20 {
22 
23  size_t key;
24 
25 public:
26 
32  inline void setKey(size_t key)
33  {
34  this->key = key;
35  }
36 
42  inline size_t getKey() const
43  {
44  return key;
45  }
46 
52  std::string to_string()
53  {
54  std::stringstream ts;
55 
56  ts << "x[0]=" << key;
57 
58  return ts.str();
59  }
60 
62 /* inline vect_dist_key_dx(size_t key)
63  :key(key)
64  {
65  }*/
66 
69  {
70  /* coverity[uninit_member] */
71  }
72 
74  inline vect_dist_key_dx(size_t key)
75  :key(key)
76  {
77  }
78 };
79 
80 
81 
82 #endif /* VECTOR_DIST_KEY_HPP_ */
std::string to_string()
Convert the key into a string message.
Grid key for a distributed grid.
size_t key
Local grid iterator.
size_t getKey() const
Get the key.
This class is a trick to indicate the compiler a specific specialization pattern. ...
Definition: memory_c.hpp:201
vect_dist_key_dx(size_t key)
Default constructor.
void setKey(size_t key)
set the key
vect_dist_key_dx()
constructor from a key