PrimitiveShapeVisitor.h
Go to the documentation of this file.
1 #ifndef PRIMITIVESHAPEVISITOR_HEADER
2 #define PRIMITIVESHAPEVISITOR_HEADER
3 
4 #ifndef DLL_LINKAGE
5 #define DLL_LINKAGE
6 #endif
7 
13 
15 {
16 public:
18  virtual void Visit(const PlanePrimitiveShape& plane) = 0;
19  virtual void Visit(const SpherePrimitiveShape& sphere) = 0;
20  virtual void Visit(const CylinderPrimitiveShape& cylinder) = 0;
21  virtual void Visit(const ConePrimitiveShape& cone) = 0;
22  virtual void Visit(const TorusPrimitiveShape& torus) = 0;
23 };
24 
25 template< class BaseT >
27  : public BaseT
28 {
29 public:
31 
32  template< class T >
34  : BaseT(t)
35  {}
36 
37  template< class A, class B >
38  PrimitiveShapeVisitorShell(const A& a, const B& b)
39  : BaseT(a, b)
40  {}
41 
42  void Visit(const PlanePrimitiveShape& plane)
43  {
44  BaseT::Visit(plane);
45  }
46 
47  void Visit(const SpherePrimitiveShape& sphere)
48  {
49  BaseT::Visit(sphere);
50  }
51 
52  void Visit(const CylinderPrimitiveShape& cylinder)
53  {
54  BaseT::Visit(cylinder);
55  }
56 
57  void Visit(const ConePrimitiveShape& cone)
58  {
59  BaseT::Visit(cone);
60  }
61 
62  void Visit(const TorusPrimitiveShape& torus)
63  {
64  BaseT::Visit(torus);
65  }
66 };
67 
68 #endif
PrimitiveShapeVisitorShell::Visit
void Visit(const TorusPrimitiveShape &torus)
Definition: PrimitiveShapeVisitor.h:62
PrimitiveShapeVisitorShell::Visit
void Visit(const SpherePrimitiveShape &sphere)
Definition: PrimitiveShapeVisitor.h:47
ConePrimitiveShape
Definition: ConePrimitiveShape.h:11
TorusPrimitiveShape
Definition: TorusPrimitiveShape.h:12
PrimitiveShapeVisitorShell::PrimitiveShapeVisitorShell
PrimitiveShapeVisitorShell(const T &t)
Definition: PrimitiveShapeVisitor.h:33
PrimitiveShapeVisitorShell::PrimitiveShapeVisitorShell
PrimitiveShapeVisitorShell()
Definition: PrimitiveShapeVisitor.h:30
PrimitiveShapeVisitorShell::Visit
void Visit(const ConePrimitiveShape &cone)
Definition: PrimitiveShapeVisitor.h:57
PrimitiveShapeVisitorShell::PrimitiveShapeVisitorShell
PrimitiveShapeVisitorShell(const A &a, const B &b)
Definition: PrimitiveShapeVisitor.h:38
armarx::ctrlutil::a
double a(double t, double a0, double j)
Definition: CtrlUtil.h:45
CylinderPrimitiveShape
Definition: CylinderPrimitiveShape.h:11
PlanePrimitiveShape
Definition: PlanePrimitiveShape.h:15
PrimitiveShapeVisitor
Definition: PrimitiveShapeVisitor.h:14
A
class A(deque< T, A >)) ARMARX_OVERLOAD_STD_HASH_FOR_ITERABLE((class T
Enables hashing of std::list.
PrimitiveShapeVisitorShell::Visit
void Visit(const CylinderPrimitiveShape &cylinder)
Definition: PrimitiveShapeVisitor.h:52
PrimitiveShapeVisitorShell
Definition: PrimitiveShapeVisitor.h:26
PrimitiveShapeVisitor::~PrimitiveShapeVisitor
virtual ~PrimitiveShapeVisitor()
Definition: PrimitiveShapeVisitor.h:17
PrimitiveShapeVisitorShell::Visit
void Visit(const PlanePrimitiveShape &plane)
Definition: PrimitiveShapeVisitor.h:42
DLL_LINKAGE
#define DLL_LINKAGE
Definition: PrimitiveShapeVisitor.h:5
T
float T
Definition: UnscentedKalmanFilterTest.cpp:35
SpherePrimitiveShape
Definition: SpherePrimitiveShape.h:19