DGtal
2.2.0
Toggle main menu visibility
Loading...
Searching...
No Matches
CSpace.h
1
16
17
#pragma once
18
33
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
55
namespace
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
;
117
BOOST_CONCEPT_ASSERT
((
CUnsignedNumber< Dimension >
));
118
BOOST_CONCEPT_ASSERT
((
CIntegralNumber< Dimension >
));
119
BOOST_CONCEPT_ASSERT
((
CInteger< Integer >
));
120
BOOST_CONCEPT_ASSERT
((
CUnsignedNumber< Size >
));
121
BOOST_CONCEPT_ASSERT
((
CIntegralNumber< Size >
));
122
123
BOOST_CONCEPT_USAGE
(
CSpace
)
124
{
125
//Should have a static dimension.
126
ConceptUtils::sameType
(
myDim
, T::dimension );
127
}
128
129
// ------------------------- Private Data --------------------------------
130
private
:
131
Dimension
myDim
;
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)
DGtal::concepts::ConceptUtils::sameType
void sameType(const T &, const T &)
Definition
ConceptUtils.h:117
DGtal::concepts
Aim: Gathers several functions useful for concept checks.
Definition
CPositiveIrreducibleFraction.h:54
DGtal
DGtal is the top-level namespace which contains all DGtal functions and types.
Definition
ClosedIntegerHalfPlane.h:49
DGtal::concepts::CInteger
Aim: Concept checking for Integer Numbers. More precisely, this concept is a refinement of both CEucl...
Definition
CInteger.h:88
DGtal::concepts::CIntegralNumber
Aim: Concept checking for Integral Numbers. Models of this concept should be listed in NumberTraits c...
Definition
CIntegralNumber.h:102
DGtal::concepts::CSpace
Aim: Defines the concept describing a digital space, ie a cartesian product of integer lines.
Definition
CSpace.h:106
DGtal::concepts::CSpace::BOOST_CONCEPT_ASSERT
BOOST_CONCEPT_ASSERT((CUnsignedNumber< Dimension >))
DGtal::concepts::CSpace::myDim
Dimension myDim
Definition
CSpace.h:131
DGtal::concepts::CSpace::Space
T::Space Space
Definition
CSpace.h:109
DGtal::concepts::CSpace::BOOST_CONCEPT_ASSERT
BOOST_CONCEPT_ASSERT((CIntegralNumber< Dimension >))
DGtal::concepts::CSpace::Dimension
T::Dimension Dimension
Definition
CSpace.h:113
DGtal::concepts::CSpace::Point
T::Point Point
Definition
CSpace.h:111
DGtal::concepts::CSpace::BOOST_CONCEPT_USAGE
BOOST_CONCEPT_USAGE(CSpace)
Definition
CSpace.h:123
DGtal::concepts::CSpace::Integer
T::Integer Integer
Definition
CSpace.h:110
DGtal::concepts::CSpace::BOOST_CONCEPT_ASSERT
BOOST_CONCEPT_ASSERT((CInteger< Integer >))
DGtal::concepts::CSpace::Vector
T::Vector Vector
Definition
CSpace.h:112
DGtal::concepts::CSpace::BOOST_CONCEPT_ASSERT
BOOST_CONCEPT_ASSERT((CIntegralNumber< Size >))
DGtal::concepts::CSpace::RealVector
T::RealVector RealVector
Definition
CSpace.h:116
DGtal::concepts::CSpace::RealPoint
T::RealPoint RealPoint
Definition
CSpace.h:115
DGtal::concepts::CSpace::BOOST_CONCEPT_ASSERT
BOOST_CONCEPT_ASSERT((CUnsignedNumber< Size >))
DGtal::concepts::CSpace::Size
T::Size Size
Definition
CSpace.h:114
DGtal::concepts::CUnsignedNumber
Aim: Concept checking for Unsigned numbers. Models of this concept should be listed in NumberTraits c...
Definition
CUnsignedNumber.h:95
src
DGtal
kernel
CSpace.h
Generated on
for DGtal by
1.18.0