https://svn.lrde.epita.fr/svn/oln/trunk/olena
Index: ChangeLog
from Roland Levillain <roland(a)lrde.epita.fr>
Adjust virtual types class names.
* oln/core/abstract/image.hh,
* oln/core/abstract/image_dimension.hh,
* oln/core/abstract/image_typeness.hh,
* oln/core/abstract/grid.hh, oln/core/1d/grid1d.hh,
* oln/core/2d/grid2d.hh, oln/core/3d/grid3d.hh,
* tests/image_entry.cc (vtypes): Rename as...
(vtypes_in_category): ...this.
* oln/core/abstract/image.hh, oln/core/abstract/grid.hh,
* tests/image_entry.cc (packed_vtypes): Rename as...
(packed_vtypes_in_category): ...this.
* oln/core/abstract/point.hh, oln/core/abstract/dpoint.hh,
* oln/core/abstract/piter.hh, oln/core/abstract/pset.hh,
* oln/core/gen/bbox.hh,
* oln/core/gen/bkd_piter.hh, oln/core/gen/fwd_piter.hh,
* oln/core/2d/point2d.hh, oln/core/2d/dpoint2d.hh (vtypes_):
Rename as...
(vtypes).
* oln/core/abstract/pset.hh, oln/core/abstract/bbox.hh
(ext_vtype_): Rename as...
(ext_vtype): ...this.
oln/core/1d/grid1d.hh | 2 +-
oln/core/2d/dpoint2d.hh | 2 +-
oln/core/2d/grid2d.hh | 2 +-
oln/core/2d/point2d.hh | 2 +-
oln/core/3d/grid3d.hh | 2 +-
oln/core/abstract/bbox.hh | 4 ++--
oln/core/abstract/dpoint.hh | 2 +-
oln/core/abstract/grid.hh | 8 ++++----
oln/core/abstract/image.hh | 17 +++++++++++------
oln/core/abstract/image_dimension.hh | 8 ++++----
oln/core/abstract/image_typeness.hh | 16 ++++++++--------
oln/core/abstract/image_typeness_integre.hh | 8 ++++----
oln/core/abstract/internal/image_impl.hh | 6 +++---
oln/core/abstract/piter.hh | 2 +-
oln/core/abstract/point.hh | 2 +-
oln/core/abstract/pset.hh | 8 ++++----
oln/core/gen/bbox.hh | 2 +-
oln/core/gen/bkd_piter.hh | 2 +-
oln/core/gen/fwd_piter.hh | 2 +-
tests/image_entry.cc | 5 +++--
20 files changed, 54 insertions(+), 48 deletions(-)
Index: tests/image_entry.cc
--- tests/image_entry.cc (revision 520)
+++ tests/image_entry.cc (working copy)
@@ -48,7 +48,7 @@
/// Virtual types associated to my::image.
template<>
- struct vtypes<category::image, my::image>
+ struct vtypes_in_category<category::image, my::image>
{
// The switch for image_dimension (above image_entry) plugs the
// inheritance relation to the right abstract::image_dimension
@@ -105,5 +105,6 @@
// Print my::image's vtypes.
// FIXME: To be removed in the final version.
- oln::packed_vtypes<oln::category::image, my::image>::echo (std::cout);
+ oln::packed_vtypes_in_category< oln::category::image,
+ my::image >::echo (std::cout);
}
Index: oln/core/abstract/image.hh
--- oln/core/abstract/image.hh (revision 520)
+++ oln/core/abstract/image.hh (working copy)
@@ -57,7 +57,7 @@
/// Virtual types associated to oln::abstract::image.
template <typename I>
- struct vtypes< category::image, abstract::image<I> >
+ struct vtypes_in_category< category::image, abstract::image<I> >
{
typedef I exact_type;
@@ -96,9 +96,10 @@
/// Packing of the virtual types of any image class.
template <typename I>
- struct packed_vtypes<category::image, I>
+ struct packed_vtypes_in_category<category::image, I>
{
- // Internally defined virtual types.
+ /// Virtual types defined internally.
+ /// \{
typedef oln_type_of(I, exact) exact_type;
typedef oln_type_of(I, grid) grid_type;
@@ -133,16 +134,20 @@
// typedef oln_type_of(I, image_constness) image_constness_type;
// typedef oln_type_of(I, image_rawness) image_rawness_type;
// --------------------------------------------------------------------
+ /// \}
- // Defined externally virtual types.
+ /// Virtual types defined as extensions.
+ /// \{
typedef oln_type_of(I, image_dimension) image_dimension_type;
typedef oln_type_of(I, image_typeness) image_typeness_type;
+ /// \}
/// Pretty-printing.
static void echo(std::ostream& ostr)
{
ostr
- << "vtypes_of(oln::category::image, " << mlc_to_string(I) <<
") ="
+ << "vtypes_in_category(oln::category::image, "
+ << mlc_to_string(I) << ") ="
<< std::endl
<< "{" << std::endl
<< " exact_type = " << mlc_to_string(exact_type) <<
std::endl
@@ -441,7 +446,7 @@
virtual ~image()
{
- packed_vtypes<category::image, E>::ensure();
+ packed_vtypes_in_category<category::image, E>::ensure();
// FIXME: static check fails because "pointer to member conversion via virtual
base"...
// mlc_check_method_impl(E, const size_type&, size, ,
const);
// mlc_check_method_impl(E, unsigned long, npoints, , const);
Index: oln/core/abstract/piter.hh
--- oln/core/abstract/piter.hh (revision 520)
+++ oln/core/abstract/piter.hh (working copy)
@@ -51,7 +51,7 @@
/// Virtual types associated to abstract::piter<E>.
template <typename E>
- struct vtypes_< abstract::piter<E> >
+ struct vtypes< abstract::piter<E> >
{
typedef mlc::undefined point_type;
};
Index: oln/core/abstract/grid.hh
--- oln/core/abstract/grid.hh (revision 520)
+++ oln/core/abstract/grid.hh (working copy)
@@ -59,7 +59,7 @@
/// Virtual types associated to oln::abstract::image.
template <typename G>
- struct vtypes< category::grid, abstract::grid<G> >
+ struct vtypes_in_category< category::grid, abstract::grid<G> >
{
typedef mlc::undefined point_type;
typedef mlc::none dpoint_type;
@@ -70,7 +70,7 @@
template <typename G>
- struct packed_vtypes<category::grid, G>
+ struct packed_vtypes_in_category<category::grid, G>
{
typedef oln_grd_type_of(G, point) point_type;
typedef oln_grd_type_of(G, dpoint) dpoint_type;
@@ -81,7 +81,7 @@
static void echo(std::ostream& ostr)
{
ostr
- << "vtypes(oln::category::grid, " << mlc_to_string(G) <<
") ="
+ << "vtypes_in_category(oln::category::grid, " << mlc_to_string(G)
<< ") ="
<< std::endl
<< "{" << std::endl
<< " point_type = " << mlc_to_string(point_type) <<
std::endl
@@ -114,7 +114,7 @@
~grid()
{
- packed_vtypes<category::grid, E>::ensure();
+ packed_vtypes_in_category<category::grid, E>::ensure();
}
};
Index: oln/core/abstract/image_dimension.hh
--- oln/core/abstract/image_dimension.hh (revision 520)
+++ oln/core/abstract/image_dimension.hh (working copy)
@@ -184,15 +184,15 @@
/*----------------------------------.
-| Dimension external virtual type. |
+| Dimension extended virtual type. |
`----------------------------------*/
-// FIXME: Is this external vtype really useful?
+// FIXME: Is this extended vtype really useful?
namespace oln
{
- /// Image dimension type as an external vtype of abstract::image.
+ /// Image dimension type as an extended vtype of abstract::image.
template <typename I>
- struct ext_vtype< category::image,
+ struct ext_vtype_in_category< category::image,
abstract::image<I>,
// FIXME: Get rid of this typedef_:: qualifier.
typedef_::image_dimension_type >
Index: oln/core/abstract/image_typeness_integre.hh
--- oln/core/abstract/image_typeness_integre.hh (revision 520)
+++ oln/core/abstract/image_typeness_integre.hh (working copy)
@@ -104,7 +104,7 @@
{
// Definition of the super class corresponding to this case.
typedef stc::abstraction_as_type<abstract::binary_image> super_type;
- // Definition of the external virtual type (same as the super
+ // Definition of the extended virtual type (same as the super
// class in this case).
typedef super_type image_typeness_type;
};
@@ -120,7 +120,7 @@
typedef
stc::abstraction_as_type<abstract::internal::grey_level_image_>
super_type;
- // Definition of the external virtual type.
+ // Definition of the extended virtual type.
typedef stc::abstraction_as_type<abstract::grey_level_image>
image_typeness_type;
};
@@ -135,7 +135,7 @@
// abstract::label_image and abstract::not_binary_image).
typedef stc::abstraction_as_type<abstract::internal::label_image_>
super_type;
- // Definition of the external virtual type.
+ // Definition of the extended virtual type.
typedef stc::abstraction_as_type<abstract::label_image>
image_typeness_type;
};
@@ -150,7 +150,7 @@
// abstract::color_image and abstract::not_binary_image).
typedef stc::abstraction_as_type<abstract::internal::color_image_>
super_type;
- // Definition of the external virtual type.
+ // Definition of the extended virtual type.
typedef stc::abstraction_as_type<abstract::color_image>
image_typeness_type;
};
Index: oln/core/abstract/point.hh
--- oln/core/abstract/point.hh (revision 520)
+++ oln/core/abstract/point.hh (working copy)
@@ -54,7 +54,7 @@
/// Virtual types associated to abstract::point<E>.
template <typename E>
- struct vtypes_< abstract::point<E> >
+ struct vtypes< abstract::point<E> >
{
typedef mlc::undefined grid_type;
typedef mlc::undefined dpoint_type;
Index: oln/core/abstract/bbox.hh
--- oln/core/abstract/bbox.hh (revision 520)
+++ oln/core/abstract/bbox.hh (working copy)
@@ -54,7 +54,7 @@
template <typename E>
- struct ext_vtype_< abstract::bbox<E>, typedef_::fwd_piter_type >
+ struct ext_vtype< abstract::bbox<E>, typedef_::fwd_piter_type >
{
private:
typedef oln_type_of(E, point) P;
@@ -63,7 +63,7 @@
};
template <typename E>
- struct ext_vtype_< abstract::bbox<E>, typedef_::bkd_piter_type >
+ struct ext_vtype< abstract::bbox<E>, typedef_::bkd_piter_type >
{
private:
typedef oln_type_of(E, point) P;
Index: oln/core/abstract/dpoint.hh
--- oln/core/abstract/dpoint.hh (revision 520)
+++ oln/core/abstract/dpoint.hh (working copy)
@@ -52,7 +52,7 @@
/// Virtual types associated to abstract::dpoint<E>.
template <typename E>
- struct vtypes_< abstract::dpoint<E> >
+ struct vtypes< abstract::dpoint<E> >
{
typedef mlc::undefined grid_type;
typedef mlc::undefined point_type;
Index: oln/core/abstract/pset.hh
--- oln/core/abstract/pset.hh (revision 520)
+++ oln/core/abstract/pset.hh (working copy)
@@ -44,7 +44,7 @@
/// Virtual types associated to oln::bbox_nd<point>.
template <typename E>
- struct vtypes_< abstract::pset<E> >
+ struct vtypes< abstract::pset<E> >
{
typedef mlc::undefined point_type;
// typedef mlc::undefined fwd_piter_type;
@@ -53,13 +53,13 @@
// template <typename E>
-// struct vtype_< abstract::pset<E>, typedef_::coord_type >
+// struct single_vtype< abstract::pset<E>, typedef_::coord_type >
// : type_of_< oln_type_of(E, point), typedef_::coord_type >
// {};
// template <typename E>
-// struct extension_vtype_< abstract::pset<E>, typedef_::coord_type >
+// struct ext_vtype< abstract::pset<E>, typedef_::coord_type >
// {
// private:
// typedef oln_type_of(E, point) P;
@@ -69,7 +69,7 @@
template <typename E>
- struct ext_vtype_< abstract::pset<E>, typedef_::grid_type >
+ struct ext_vtype< abstract::pset<E>, typedef_::grid_type >
{
typedef oln_type_of(E, point) P;
typedef oln_type_of(P, grid) ret;
Index: oln/core/abstract/image_typeness.hh
--- oln/core/abstract/image_typeness.hh (revision 520)
+++ oln/core/abstract/image_typeness.hh (working copy)
@@ -252,7 +252,7 @@
{
// Definition of the super class corresponding to this case.
typedef stc::abstraction_as_type<abstract::binary_image> super_type;
- // Definition of the external virtual type (same as the super
+ // Definition of the extended virtual type (same as the super
// class in this case).
typedef super_type image_typeness_type;
};
@@ -270,7 +270,7 @@
// abstract::grey_level_image and abstract::not_binary_image).
typedef stc::abstraction_as_type<abstract::internal::grey_level_image_>
super_type;
- // Definition of the external virtual type.
+ // Definition of the extended virtual type.
typedef stc::abstraction_as_type<abstract::grey_level_image>
image_typeness_type;
};
@@ -289,7 +289,7 @@
// abstract::data_image and abstract::not_binary_image).
typedef stc::abstraction_as_type<abstract::internal::data_image_>
super_type;
- // Definition of the external virtual type.
+ // Definition of the extended virtual type.
typedef stc::abstraction_as_type<abstract::data_image>
image_typeness_type;
};
@@ -300,21 +300,21 @@
/*---------------------------------.
-| Typeness external virtual type. |
+| Typeness extended virtual type. |
`---------------------------------*/
-// FIXME: Is this external vtype really useful?
+// FIXME: Is this extended vtype really useful?
namespace oln
{
- /// Image ``typeness'' as an external vtype of abstract::image.
+ /// Image ``typeness'' as an extended vtype of abstract::image.
template <typename I>
- struct ext_vtype< category::image,
+ struct ext_vtype_in_category< category::image,
abstract::image<I>,
// FIXME: Get rid of this typedef_:: qualifier.
typedef_::image_typeness_type >
{
// Use the same case as the one use in the inheritance-plugging
- // mechanism above, but retrieve the external vtype
+ // mechanism above, but retrieve the extended vtype
// (image_typename_type), not the super type.
typedef
typename oln::case_< oln::value_type_tag,
Index: oln/core/abstract/internal/image_impl.hh
--- oln/core/abstract/internal/image_impl.hh (revision 520)
+++ oln/core/abstract/internal/image_impl.hh (working copy)
@@ -85,10 +85,10 @@
delegated type (i.e. D = mlc::none), get_image_impl inherits
from oln::any_best_speed (trough get_image_impl_helper);
otherwise, get_image_impl is plugged to set_image_impl, a
- class than can specialized by the user.
+ class than can be specialized by the user.
- (*) This relation is not mandatory (set_image_impl is to be
- defined by the user), but it every specialization of
+ (*) This relation is not systematic (set_image_impl is to be
+ defined by the user), but every specialization of
set_image_impl *should* inherit from oln::any_best_speed. */
template <typename A, typename D, typename E>
Index: oln/core/1d/grid1d.hh
--- oln/core/1d/grid1d.hh (revision 520)
+++ oln/core/1d/grid1d.hh (working copy)
@@ -47,7 +47,7 @@
/// Virtual types associated to oln::grid1d.
template <>
- struct vtypes<category::grid, grid1d>
+ struct vtypes_in_category<category::grid, grid1d>
{
typedef point1d point_type;
typedef dpoint1d dpoint_type;
Index: oln/core/2d/dpoint2d.hh
--- oln/core/2d/dpoint2d.hh (revision 520)
+++ oln/core/2d/dpoint2d.hh (working copy)
@@ -47,7 +47,7 @@
/// Virtual types associated to oln::abstract::image.
template <typename C>
- struct vtypes_< dpoint2d_<C> >
+ struct vtypes< dpoint2d_<C> >
{
typedef grid2d grid_type;
typedef point2d point_type;
Index: oln/core/2d/grid2d.hh
--- oln/core/2d/grid2d.hh (revision 520)
+++ oln/core/2d/grid2d.hh (working copy)
@@ -47,7 +47,7 @@
/// Virtual types associated to oln::grid2d.
template <>
- struct vtypes<category::grid, grid2d>
+ struct vtypes_in_category<category::grid, grid2d>
{
typedef point2d point_type;
typedef dpoint2d dpoint_type;
Index: oln/core/2d/point2d.hh
--- oln/core/2d/point2d.hh (revision 520)
+++ oln/core/2d/point2d.hh (working copy)
@@ -45,7 +45,7 @@
/// Virtual types associated to oln::abstract::image.
template <typename C>
- struct vtypes_< point2d_<C> >
+ struct vtypes< point2d_<C> >
{
typedef grid2d grid_type;
typedef dpoint2d dpoint_type;
Index: oln/core/3d/grid3d.hh
--- oln/core/3d/grid3d.hh (revision 520)
+++ oln/core/3d/grid3d.hh (working copy)
@@ -47,7 +47,7 @@
/// Virtual types associated to oln::grid3d.
template <>
- struct vtypes<category::grid, grid3d>
+ struct vtypes_in_category<category::grid, grid3d>
{
typedef point3d point_type;
typedef dpoint3d dpoint_type;
Index: oln/core/gen/bkd_piter.hh
--- oln/core/gen/bkd_piter.hh (revision 520)
+++ oln/core/gen/bkd_piter.hh (working copy)
@@ -53,7 +53,7 @@
/// Virtual types associated to oln::bbox_<point>.
template <typename point>
- struct vtypes_< bkd_piter_<point> >
+ struct vtypes< bkd_piter_<point> >
{
typedef point point_type;
typedef oln_type_of(point, grid) grid_type;
Index: oln/core/gen/fwd_piter.hh
--- oln/core/gen/fwd_piter.hh (revision 520)
+++ oln/core/gen/fwd_piter.hh (working copy)
@@ -53,7 +53,7 @@
/// Virtual types associated to oln::fwd_piter_<point>.
template <typename point>
- struct vtypes_< fwd_piter_<point> >
+ struct vtypes< fwd_piter_<point> >
{
typedef point point_type;
typedef oln_type_of(point, grid) grid_type;
Index: oln/core/gen/bbox.hh
--- oln/core/gen/bbox.hh (revision 520)
+++ oln/core/gen/bbox.hh (working copy)
@@ -53,7 +53,7 @@
/// Virtual types associated to oln::bbox_<point>.
template <typename point>
- struct vtypes_< bbox_<point> >
+ struct vtypes< bbox_<point> >
{
typedef point point_type;
// typedef fwd_piter_<point> fwd_piter_type;