00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027 #ifndef MLN_TOPO_ADJ_HIGHER_FACE_ITER_HH
00028 # define MLN_TOPO_ADJ_HIGHER_FACE_ITER_HH
00029
00034
00035 # include <mln/topo/internal/complex_relative_iterator_base.hh>
00036 # include <mln/topo/algebraic_face.hh>
00037
00038
00039 namespace mln
00040 {
00041
00042 namespace topo
00043 {
00044
00045
00046 template <unsigned D> class complex;
00047
00048 namespace internal
00049 {
00050
00051 template <typename C, typename F, typename E>
00052 class forward_complex_relative_iterator_base;
00053
00054 template <typename C, typename F, typename E>
00055 class backward_complex_relative_iterator_base;
00056
00057 }
00058
00059 template <unsigned D>
00060 class algebraic_face;
00061
00062
00063
00064
00065
00070
00071 template <unsigned D>
00072 class adj_higher_face_fwd_iter
00073 : public internal::forward_complex_relative_iterator_base< topo::face<D>,
00074 algebraic_face<D>,
00075 adj_higher_face_fwd_iter<D> >
00076 {
00077 typedef adj_higher_face_fwd_iter<D> self_;
00078 typedef internal::forward_complex_relative_iterator_base< topo::face<D>,
00079 algebraic_face<D>,
00080 self_ > super_;
00081
00082
00083 public:
00086 adj_higher_face_fwd_iter();
00087 template <typename Fref>
00088 adj_higher_face_fwd_iter(const Fref& f_ref);
00090
00092 void update_adj_faces_();
00093 };
00094
00095
00096
00097
00098
00099
00104
00105 template <unsigned D>
00106 class adj_higher_face_bkd_iter
00107 : public internal::backward_complex_relative_iterator_base< topo::face<D>,
00108 algebraic_face<D>,
00109 adj_higher_face_bkd_iter<D> >
00110 {
00111 typedef adj_higher_face_bkd_iter<D> self_;
00112 typedef internal::backward_complex_relative_iterator_base< topo::face<D>,
00113 algebraic_face<D>,
00114 self_ > super_;
00115
00116
00117 public:
00120 adj_higher_face_bkd_iter();
00121 template <typename Fref>
00122 adj_higher_face_bkd_iter(const Fref& f_ref);
00124
00126 void update_adj_faces_();
00127 };
00128
00129
00130
00131 # ifndef MLN_INCLUDE_ONLY
00132
00133
00134
00135
00136
00137 template <unsigned D>
00138 inline
00139 adj_higher_face_fwd_iter<D>::adj_higher_face_fwd_iter()
00140 {
00141 }
00142
00143 template <unsigned D>
00144 template <typename Fref>
00145 inline
00146 adj_higher_face_fwd_iter<D>::adj_higher_face_fwd_iter(const Fref& f_ref)
00147 : super_(f_ref)
00148 {
00149 }
00150
00151 template <unsigned D>
00152 inline
00153 void
00154 adj_higher_face_fwd_iter<D>::update_adj_faces_()
00155 {
00156 mln_precondition(this->c_);
00157 this->adj_faces_ = this->c_->higher_dim_adj_faces();
00158 }
00159
00160
00161
00162
00163
00164
00165 template <unsigned D>
00166 inline
00167 adj_higher_face_bkd_iter<D>::adj_higher_face_bkd_iter()
00168 {
00169 }
00170
00171 template <unsigned D>
00172 template <typename Fref>
00173 inline
00174 adj_higher_face_bkd_iter<D>::adj_higher_face_bkd_iter(const Fref& f_ref)
00175 : super_(f_ref)
00176 {
00177 }
00178
00179 template <unsigned D>
00180 inline
00181 void
00182 adj_higher_face_bkd_iter<D>::update_adj_faces_()
00183 {
00184 mln_precondition(this->c_);
00185 this->adj_faces_ = this->c_->higher_dim_adj_faces();
00186 }
00187
00188 # endif // ! MLN_INCLUDE_ONLY
00189
00190 }
00191
00192 }
00193
00194 #endif // ! MLN_TOPO_ADJ_HIGHER_FACE_ITER_HH