DGtal 1.4.2
Loading...
Searching...
No Matches
CSpace.h
1
17#pragma once
18
34#if defined(CSpace_RECURSES)
35#error Recursive header files inclusion detected in CSpace.h
36#else // defined(CSpace_RECURSES)
38#define CSpace_RECURSES
39
40#if !defined CSpace_h
42#define CSpace_h
43
45// Inclusions
46#include <iostream>
47#include "DGtal/base/Common.h"
48#include "DGtal/base/ConceptUtils.h"
49#include "DGtal/kernel/CInteger.h"
50#include "DGtal/kernel/CUnsignedNumber.h"
51#include "DGtal/kernel/CIntegralNumber.h"
52#include "DGtal/kernel/NumberTraits.h"
54
55namespace DGtal
56{
57 namespace concepts
58 {
60 // class CSpace
104 template <typename T>
105 struct CSpace
106 {
107 // ----------------------- Concept checks ------------------------------
108 public:
109 typedef typename T::Space Space;
110 typedef typename T::Integer Integer;
111 typedef typename T::Point Point;
112 typedef typename T::Vector Vector;
113 typedef typename T::Dimension Dimension;
114 typedef typename T::Size Size;
115 typedef typename T::RealPoint RealPoint;
116 typedef typename T::RealVector RealVector;
122
124 {
125 //Should have a static dimension.
126 ConceptUtils::sameType( myDim, T::dimension );
127 }
128
129 // ------------------------- Private Datas --------------------------------
130 private:
132
133 // ------------------------- Internals ------------------------------------
134 private:
135
136 }; // end of concept CSpace
137 }
138} // namespace DGtal
139
140
141
142// //
144
145#endif // !defined CSpace_h
146
147#undef CSpace_RECURSES
148#endif // else defined(CSpace_RECURSES)
void sameType(const T &, const T &)
DGtal is the top-level namespace which contains all DGtal functions and types.
Aim: Concept checking for Integer Numbers. More precisely, this concept is a refinement of both CEucl...
Definition CInteger.h:88
Aim: Concept checking for Integral Numbers. Models of this concept should be listed in NumberTraits c...
Aim: Defines the concept describing a digital space, ie a cartesian product of integer lines.
Definition CSpace.h:106
T::RealPoint RealPoint
Definition CSpace.h:115
BOOST_CONCEPT_ASSERT((CUnsignedNumber< Dimension >))
T::Dimension Dimension
Definition CSpace.h:113
BOOST_CONCEPT_ASSERT((CIntegralNumber< Dimension >))
T::RealVector RealVector
Definition CSpace.h:116
BOOST_CONCEPT_USAGE(CSpace)
Definition CSpace.h:123
BOOST_CONCEPT_ASSERT((CInteger< Integer >))
BOOST_CONCEPT_ASSERT((CIntegralNumber< Size >))
BOOST_CONCEPT_ASSERT((CUnsignedNumber< Size >))
Aim: Concept checking for Unsigned numbers. Models of this concept should be listed in NumberTraits c...