lmi
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Re[2]: [lmi] Code review: product editor


From: Evgeniy Tarassov
Subject: Re: Re[2]: [lmi] Code review: product editor
Date: Tue, 20 Mar 2007 11:51:16 +0100

Hello, Greg!
I have created a new 'branch-20070316T1045Z-product-editor' and
committed a simplified version of MultiDimGrid. As you have described
above it is a simple base class for 1-dimensional and 7-dimensional
versions of MDGrid, it provides type-safety for table values and does
not do type-checking on axes (which is done in the corresponding
versions).
   template
       <typename T
       ,typename Derived
       ,typename ConversionPolicy = ValueCastConversion<T>
       >
   class MultiDimTableN;
The class has 3 template parameters:
T - type of table data values
ConversionPolicy - a class describing how to convert values into/from
strings, with a default implementation using value_cast
Derived - the only meta-programming twist in the class, which allows
us to use non-virtual methods to implement custom behavior. Derived
type should be the type of the class deriving from MultiDimTableN. For
example:
   class DatabaseTableAdapter
     :public MultiDimTableN<double, DatabaseTableAdapter>;

I tried to create a patch for each commit. I will send it archived to
your personal email.

MultiDimTable simplified is not the only change I made there -- I'm
reviewing the code and correcting the issues you have pointed out
(with marker EVGENIY) and some other ones.

--
ET




reply via email to

[Prev in Thread] Current Thread [Next in Thread]