* mln/topo/complex_iter.hh: Rename as...
* mln/topo/face_iter.hh: ...this.
(mln::topo::complex_fwd_iter_<D>)
(mln::topo::complex_bkd_iter_<D>):
Rename as...
(mln::topo::face_fwd_iter<D>)
(mln::topo::face_bkd_iter<D>):
...these.
* milena/mln/topo/complex.hh: Adjust.
* milena/tests/topo/complex.cc: Update documentation.
---
milena/ChangeLog | 15 ++++
milena/mln/topo/complex.hh | 10 ++--
milena/mln/topo/{complex_iter.hh => face_iter.hh} | 75 +++++++++++----------
milena/tests/topo/complex.cc | 26 ++++----
4 files changed, 71 insertions(+), 55 deletions(-)
rename milena/mln/topo/{complex_iter.hh => face_iter.hh} (76%)
diff --git a/milena/ChangeLog b/milena/ChangeLog
index e129023..e2d0609 100644
--- a/milena/ChangeLog
+++ b/milena/ChangeLog
@@ -1,5 +1,20 @@
2008-09-26 Roland Levillain <roland(a)lrde.epita.fr>
+ Rename topo::complex_{fwd,bkd}_iter_ as topo::face_{fwd,bkd}_iter.
+
+ * mln/topo/complex_iter.hh: Rename as...
+ * mln/topo/face_iter.hh: ...this.
+ (mln::topo::complex_fwd_iter_<D>)
+ (mln::topo::complex_bkd_iter_<D>):
+ Rename as...
+ (mln::topo::face_fwd_iter<D>)
+ (mln::topo::face_bkd_iter<D>):
+ ...these.
+ * milena/mln/topo/complex.hh: Adjust.
+ * milena/tests/topo/complex.cc: Update documentation.
+
+2008-09-26 Roland Levillain <roland(a)lrde.epita.fr>
+
Rename internal::complex_iter_base_ as internal::complex_iter_base.
* mln/topo/internal/complex_iter_base.hh
diff --git a/milena/mln/topo/complex.hh b/milena/mln/topo/complex.hh
index 2ce88fd..e49f513 100644
--- a/milena/mln/topo/complex.hh
+++ b/milena/mln/topo/complex.hh
@@ -48,7 +48,7 @@
# include <mln/topo/n_face.hh>
# include <mln/topo/n_faces_set.hh>
-# include <mln/topo/complex_iter.hh>
+# include <mln/topo/face_iter.hh>
// FIXME: Disabled (moved to the attic).
# if 0
# include <mln/topo/faces_iter.hh>
@@ -63,8 +63,8 @@ namespace mln
// Forward declarations (external).
template <unsigned N, unsigned D> class n_faces_set;
- template <unsigned D> class complex_fwd_iter_;
- template <unsigned D> class complex_bkd_iter_;
+ template <unsigned D> class face_fwd_iter;
+ template <unsigned D> class face_bkd_iter;
// FIXME: Disabled (moved to the attic).
# if 0
template <unsigned N, unsigned D> class faces_fwd_iter_;
@@ -92,9 +92,9 @@ namespace mln
{
public:
/// Forward mln::Iterator type iterating on all faces.
- typedef complex_fwd_iter_<D> fwd_citer;
+ typedef face_fwd_iter<D> fwd_citer;
/// Backward mln::Iterator type iterating on all faces.
- typedef complex_bkd_iter_<D> bkd_citer;
+ typedef face_bkd_iter<D> bkd_citer;
// FIXME: Disabled (moved to the attic).
# if 0
diff --git a/milena/mln/topo/complex_iter.hh b/milena/mln/topo/face_iter.hh
similarity index 76%
rename from milena/mln/topo/complex_iter.hh
rename to milena/mln/topo/face_iter.hh
index c589093..e366441 100644
--- a/milena/mln/topo/complex_iter.hh
+++ b/milena/mln/topo/face_iter.hh
@@ -25,11 +25,12 @@
// reasons why the executable file might be covered by the GNU General
// Public License.
-#ifndef MLN_TOPO_COMPLEX_ITER_HH
-# define MLN_TOPO_COMPLEX_ITER_HH
+#ifndef MLN_TOPO_FACE_ITER_HH
+# define MLN_TOPO_FACE_ITER_HH
-/// \file mln/topo/complex_iter.hh
-/// \brief Definition of forward and backward iterators on complexes.
+/// \file mln/topo/face_iter.hh
+/// \brief Definition of forward and backward iterators on all the
+/// faces of a complex.
# include <mln/topo/internal/complex_iter_base.hh>
# include <mln/topo/face.hh>
@@ -47,23 +48,23 @@ namespace mln
template <unsigned D> class complex;
- /*-----------------------------.
- | topo::complex_fwd_iter_<D>. |
- `-----------------------------*/
+ /*-------------------------.
+ | topo::face_fwd_iter<D>. |
+ `-------------------------*/
- /// \brief Forward iterator on all the faces of a mln::complex<D>.
+ /// \brief Forward iterator on all the faces of an mln::complex<D>.
///
/// \arg \p D The dimension of the complex this iterator belongs to.
template <unsigned D>
- class complex_fwd_iter_
- : public internal::complex_iter_base< face<D>, complex_fwd_iter_<D>
>
+ class face_fwd_iter
+ : public internal::complex_iter_base< face<D>, face_fwd_iter<D>
>
{
public:
/// Type of associated face.
typedef face<D> face;
private:
- typedef complex_fwd_iter_<D> self_;
+ typedef face_fwd_iter<D> self_;
typedef internal::complex_iter_base< face, self_ > super_;
public:
@@ -73,9 +74,9 @@ namespace mln
public:
/// Construction and assignment.
/// \{
- complex_fwd_iter_();
+ face_fwd_iter();
// FIXME: See comment in internal::complex_iter_base's default ctor
- complex_fwd_iter_(complex<D>& c);
+ face_fwd_iter(complex<D>& c);
/// \}
/// Manipulation.
@@ -91,23 +92,23 @@ namespace mln
};
- /*-----------------------------.
- | topo::complex_bkd_iter_<D>. |
- `-----------------------------*/
+ /*-------------------------.
+ | topo::face_bkd_iter<D>. |
+ `-------------------------*/
- /// \brief Backward iterator on all the faces of a mln::complex<D>.
+ /// \brief Backward iterator on all the faces of an mln::complex<D>.
///
/// \arg \p D The dimension of the complex this iterator belongs to.
template <unsigned D>
- class complex_bkd_iter_
- : public internal::complex_iter_base< face<D>, complex_bkd_iter_<D>
>
+ class face_bkd_iter
+ : public internal::complex_iter_base< face<D>, face_bkd_iter<D> >
{
public:
/// Type of associated face.
typedef face<D> face;
private:
- typedef complex_bkd_iter_<D> self_;
+ typedef face_bkd_iter<D> self_;
typedef internal::complex_iter_base< face, self_ > super_;
public:
@@ -117,9 +118,9 @@ namespace mln
public:
/// Construction and assignment.
/// \{
- complex_bkd_iter_();
+ face_bkd_iter();
// FIXME: See comment in internal::complex_iter_base's default ctor
- complex_bkd_iter_(complex<D>& c);
+ face_bkd_iter(complex<D>& c);
/// \}
/// Manipulation.
@@ -138,20 +139,20 @@ namespace mln
# ifndef MLN_INCLUDE_ONLY
- /*-----------------------------.
- | topo::complex_fwd_iter_<D>. |
- `-----------------------------*/
+ /*-------------------------.
+ | topo::face_fwd_iter<D>. |
+ `-------------------------*/
template <unsigned D>
inline
- complex_fwd_iter_<D>::complex_fwd_iter_()
+ face_fwd_iter<D>::face_fwd_iter()
: super_()
{
}
template <unsigned D>
inline
- complex_fwd_iter_<D>::complex_fwd_iter_(complex<D>& c)
+ face_fwd_iter<D>::face_fwd_iter(complex<D>& c)
: super_(c)
{
set_cplx(c);
@@ -161,7 +162,7 @@ namespace mln
template <unsigned D>
inline
void
- complex_fwd_iter_<D>::start()
+ face_fwd_iter<D>::start()
{
face_.set_n(0u);
face_.set_face_id(0u);
@@ -170,7 +171,7 @@ namespace mln
template <unsigned D>
inline
void
- complex_fwd_iter_<D>::next_()
+ face_fwd_iter<D>::next_()
{
if (is_valid())
{
@@ -202,20 +203,20 @@ namespace mln
}
- /*-----------------------------.
- | topo::complex_bkd_iter_<D>. |
- `-----------------------------*/
+ /*-------------------------.
+ | topo::face_bkd_iter<D>. |
+ `-------------------------*/
template <unsigned D>
inline
- complex_bkd_iter_<D>::complex_bkd_iter_()
+ face_bkd_iter<D>::face_bkd_iter()
: super_()
{
}
template <unsigned D>
inline
- complex_bkd_iter_<D>::complex_bkd_iter_(complex<D>& c)
+ face_bkd_iter<D>::face_bkd_iter(complex<D>& c)
: super_(c)
{
set_cplx(c);
@@ -225,7 +226,7 @@ namespace mln
template <unsigned D>
inline
void
- complex_bkd_iter_<D>::start()
+ face_bkd_iter<D>::start()
{
face_.set_n(D);
face_.set_face_id(face_.cplx().template nfaces<D>() - 1);
@@ -234,7 +235,7 @@ namespace mln
template <unsigned D>
inline
void
- complex_bkd_iter_<D>::next_()
+ face_bkd_iter<D>::next_()
{
if (is_valid())
{
@@ -271,4 +272,4 @@ namespace mln
} // end of namespace mln
-#endif // ! MLN_TOPO_COMPLEX_ITER_HH
+#endif // ! MLN_TOPO_FACE_ITER_HH
diff --git a/milena/tests/topo/complex.cc b/milena/tests/topo/complex.cc
index eeaeb14..3319813 100644
--- a/milena/tests/topo/complex.cc
+++ b/milena/tests/topo/complex.cc
@@ -189,24 +189,24 @@ int main()
complex_faces_piter) use a static `n'. We should also have
n-faces iterators where n could be dynamic.
- But first, we need to clarify (existing) names.
+
+ But first, we need to clarify (existing) names. These ones are
+ OK:
-----------------------------------------------------------------
- Current name New name Definition
+ Name Definition
-----------------------------------------------------------------
- complex<D> (n/a) General complex
+ complex<D> General complex
- face_data<N, D> (n/a) Face data
- n_face<N, D> (n/a) (Static) n-face handle
- n_faces_set<N, D> (n/a) Set of face handles
- face<D> (n/a) Dynamic face handle
+ face_data<N, D> Face data
+ n_face<N, D> (Static) n-face handle
+ n_faces_set<N, D> Set of face handles
+ face<D> Dynamic face handle
- complex_fwd_iter_<D>(c) face_fwd_iter<D>(c) | Iterators on all
- complex_bkd_iter_<D>(c) face_bkd_iter<D>(c) | faces of c
+ face_fwd_iter<D>(c) | Iterators on all the faces
+ face_bkd_iter<D>(c) | of c
- complex_iter_base_<F, E> complex_iter_base<F, E>
- | Factoring base
- | class.
+ internal::complex_iter_base<F, E> Factoring base class.
-----------------------------------------------------------------
(Note: get rid of trailing underscores, even for entities in
@@ -286,7 +286,7 @@ int main()
n_face<N, D>'s.
faces_fwd_iter_<N, D> Iterators on N-faces, N being
- faces_fwd_iter_<N, D> static, acting as proxies of
+ faces_fwd_iter_<N, D> static, acting as proxies of
face<D>'s.
-----------------------------------------------------------------
*/
--
1.6.0.1