[Clam-devel] Adding descriptions to networks

David García Garzón dgarcia at iua.upf.edu
Fri Jun 5 11:33:31 PDT 2009


To let the testfarm in green I did the quick fix (not storing if empty). If 
the previous behaviour is the desired (storing an empty 'description' 
element), then, please revert the fix and fix the tests instead. Sorry, I 
have no time now. Still, whatever the case, the new tests should be written.

David.


On Friday 05 June 2009 20:16:58 David García Garzón wrote:
> Oops, we forgot something:
> http://clam-project.org/testfarm/details-BM_hardy-2009-06-05-20-00-24.html
>
> Those tests that generate networks are failing because the expected does
> not have the <description/> element. We could fix the tests or reverting to
> previous point where having an empty description means not dumping an empty
> 'description' xml element.
>
> Any preferences, Pau?
>
> Beside that, should we add unit tests for the description so that we won't
> have regressions on the load/store policy?
>
> On Friday 05 June 2009 16:33:02 David García Garzón wrote:
> > It's perfect, Angelo. Commit r13266. Keep it going!
> >
> > On Friday 05 June 2009 16:07:58 Angelo A.S. wrote:
> > > Hello everybody! ... and thanks David for your re-recommendations!
> > >
> > > 1. When loading the description, I put your proposal. However, when the
> > > Load function can not find the 'description' not delimited with \0,
> > > simply do not modify. So what if it fails I put it all empty ( "" )
> > >
> > > 2. I replace the line for:
> > > _textDescriptionEdit->setText(_network.GetDescription().c_str());
> > >
> > > 3. I replace the line for:
> > > QtGui/QTextEdit
> > >
> > > *Modified classes*:
> > >
> > > BaseNetwork.hxx: added virtual method 'get' and 'set' for description.
> > > FlattenedNetwork.cxx: reimplementation of StoreOn and LoadFrom
> > > (methods)... this was necessary to support reading and writing
> > > descriptionsFlattenedNetwork.hxx: added method 'get' and 'set' for
> > > description ant attribute 'Text _description'
> > > MainWindows.hxx: added a _descriptionPanel and _textDescriptionEdit...
> > > this was necessary to show the description
> > >
> > > *See you*!! :o)
> > >
> > > ~ Angelo Scorza ~
> > > "El que no posee el don de maravillarse ni de entusiasmarse más le
> > > valdría estar muerto, porque sus ojos están cerrados." A. Einstein.






More information about the clam-devel mailing list