Direct Graphical Models  v.1.7.0
GraphKit.cpp
1 #include "GraphKit.h"
2 #include "GraphDenseKit.h"
3 #include "GraphPairwiseKit.h"
4 #include "macroses.h"
5 
6 namespace DirectGraphicalModels
7 {
8  std::shared_ptr<CGraphKit> CGraphKit::create(GraphType graphType, byte nStates)
9  {
10  switch (graphType)
11  {
13  return std::make_shared<CGraphPairwiseKit>(nStates);
15  return std::make_shared<CGraphDenseKit>(nStates);
16  default:
17  DGM_ASSERT_MSG(false, "Unknown graph type");
18  }
19  }
20 }
GraphType
Types of the graphical model.
Definition: GraphKit.h:10
static std::shared_ptr< CGraphKit > create(GraphType graphType, byte nStates)
Factory method returning graph kit object.
Definition: GraphKit.cpp:8