Today me, Lalo and Xiru spent the day hacking away over
CMFCommerce. We started by abducting the CMFCommerce module from the
Collective into X3ng CVS so we could work on it without to much
Lalo named the effort Syncronized Hacking, joking that we could
participate on the Olympic Games on this sport. :)
I started sometime last week by implementing a FactoryRegistry, and
refactoring pieces of the CommerceTool code to use that, instead of
hardcoding class names. Today, Lalo suggested to use named factories
instead of single interfaces, so we changed the FactoryRegistry to do
that. Now you register a Factory by passing a Interface and a name,
and each feature of the Commerce Tool has an interface
associated. Then, you go to the Factories tab of the CommerceTool
and choose which named factory do you want to use for your
application. The factories are already filtered by the interface
informed for a given feature, and in the next iteration we’re going to
allow subclasses of a given interface to be queried as well.
Xiru is working on defining the interfaces, while discussing with us
about the best way to implement it. He’s also building a
CMFCommerceExample product, to serve as an example of the new
interfaces and as an implementation which people can base their work on.
We’re also going to write tests for it during the week, and when
the dust settles down, we’re going to move it out from the Collective
under a separate project (possibly on Savannah).
Watch out on this space for more info, and have a nice weekend.