3D Repo Bouncer  1.4
repo_diff_sharedid.h
1 
18 /*
19 * Simple Diff Comparison - only compare sharedIDs and unique IDs
20 * base scene - base scene to compare from, compare scene - compare scene to compare to
21 * if shared ID from base scene exists in compare scene, check if unique ID is the same
22 * if same - same, if different - modified
23 * if shared ID doesn't exist, the node is deleted.
24 */
25 
26 #pragma once
27 
28 #include "repo_diff_abstract.h"
29 
30 namespace repo{
31  namespace manipulator{
32  namespace diff{
34  {
35  public:
43  const repo::core::model::RepoScene *base,
44  const repo::core::model::RepoScene *compare,
46  = repo::core::model::RepoScene::GraphType::DEFAULT);
47  virtual ~DiffBySharedID();
48 
54  virtual bool isOk(std::string &msg) const
55  {
56  msg = this->msg;
57  return ok;
58  };
59 
60  private:
64  bool compare(
65  std::string &msg);
66 
67  bool ok; //Check if comparator status is ok
68  std::string msg; //error message if comaprator statis is false
69  };
70  }
71  }
72 }
DiffBySharedID(const repo::core::model::RepoScene *base, const repo::core::model::RepoScene *compare, const repo::core::model::RepoScene::GraphType &gType=repo::core::model::RepoScene::GraphType::DEFAULT)
Definition: repo_diff_sharedid.cpp:22
Definition: repo_connection_pool_mongo.h:32
Definition: repo_scene.h:44
Definition: repo_diff_sharedid.h:33
virtual bool isOk(std::string &msg) const
Definition: repo_diff_sharedid.h:54
Definition: repo_diff_abstract.h:26
GraphType
Definition: repo_scene.h:75