YAPOG  0.0.1
Yet Another Pokemon Online Game
WorldObjectState.cpp
Go to the documentation of this file.
2 
3 namespace yap
4 {
6  : info_ (nullptr)
7  {
8  }
9 
11  : info_ (copy.info_)
12  {
13  }
14 
16  : info_ (nullptr)
17  {
19  }
20 
22  {
23  if (this == &copy)
24  return *this;
25 
26  info_ = copy.info_;
27 
28  return *this;
29  }
30 
32  {
33  if (info_->GetName () == other)
34  return *this;
35 
37 
38  return *this;
39  }
40 
42  {
43  return true;
44  }
45 
47  {
48  return info_ == right.info_;
49  }
50 
52  {
53  return !operator== (right);
54  }
55 
56  bool WorldObjectState::operator== (const String& right) const
57  {
58  return GetName () == right;
59  }
60 
61  bool WorldObjectState::operator!= (const String& right) const
62  {
63  return !operator== (right);
64  }
65 
67  {
68  return info_->GetName ();
69  }
70 
72  {
73  return info_->GetLogicalName ();
74  }
75 
76  bool WorldObjectState::IsJoinedTo (const String& other) const
77  {
78  return info_->IsJoinedTo (other);
79  }
80 } // namespace yap