DGtal  1.3.beta
CDomainAdjacency.h
1 
17 #pragma once
18 
31 #if defined(CDomainAdjacency_RECURSES)
32 #error Recursive header files inclusion detected in CDomainAdjacency.h
33 #else // defined(CDomainAdjacency_RECURSES)
34 
35 #define CDomainAdjacency_RECURSES
36 
37 #if !defined CDomainAdjacency_h
38 
39 #define CDomainAdjacency_h
40 
42 // Inclusions
43 #include <iostream>
44 #include "boost/concept_check.hpp"
45 #include "DGtal/base/Common.h"
46 #include "DGtal/topology/CAdjacency.h"
48 
49 // @since 0.8 In DGtal::concepts
50 namespace DGtal {
51  namespace concepts {
52 
54  // class CDomainAdjacency
95  template <typename T>
97  {
98  // ----------------------- Concept checks ------------------------------
99  public:
100 
101  typedef typename Adj::Domain Domain;
102  typedef typename Adj::Predicate Predicate;
103 
104  // ------------------------- Private Datas --------------------------------
105  private:
107  {
108  // check domain()
109  ConceptUtils::sameType( myDomain, myT.domain() );
110  // check predicate()
111  ConceptUtils::sameType( myPredicate, myT.predicate() );
112  }
113 
114  // ------------------------- Internals ------------------------------------
115  private:
116  T myT;
119 
120  }; // end of concept CDomainAdjacency
121 
122 } // namespace concepts
123 } // namespace DGtal
124 
125  //
127 
128 #endif // !defined CDomainAdjacency_h
129 
130 #undef CDomainAdjacency_RECURSES
131 #endif // else defined(CDomainAdjacency_RECURSES)
DGtal::concepts::CDomainAdjacency
Aim: Refines the concept CAdjacency by telling that the adjacency is specific to a given domain of th...
Definition: CDomainAdjacency.h:96
DGtal::concepts::CDomainAdjacency::BOOST_CONCEPT_USAGE
BOOST_CONCEPT_USAGE(CDomainAdjacency)
Definition: CDomainAdjacency.h:106
DGtal::concepts::CDomainAdjacency::myDomain
Domain myDomain
Definition: CDomainAdjacency.h:117
DGtal::concepts::CDomainAdjacency::Predicate
Adj::Predicate Predicate
Definition: CDomainAdjacency.h:102
DGtal::concepts::CDomainAdjacency::myPredicate
Predicate myPredicate
Definition: CDomainAdjacency.h:118
DGtal
DGtal is the top-level namespace which contains all DGtal functions and types.
Domain
HyperRectDomain< Space > Domain
Definition: testSimpleRandomAccessRangeFromPoint.cpp:44
DGtal::concepts::ConceptUtils::sameType
void sameType(const T &, const T &)
Definition: ConceptUtils.h:117
DGtal::concepts::CAdjacency
Aim: The concept CAdjacency defines an elementary adjacency relation between points of a digital spac...
Definition: CAdjacency.h:99
DGtal::concepts::CDomainAdjacency::myT
T myT
Definition: CDomainAdjacency.h:116
DGtal::concepts::CDomainAdjacency::Domain
Adj::Domain Domain
Definition: CDomainAdjacency.h:101