← Back to team overview

yade-dev team mailing list archive

Re: [Branch ~yade-dev/yade/trunk] Rev 2680: 1. Rename NozzleFactory to SpheresFactory; add derived CircularFactory and QuadroFactory. Example...

 

Hi Sega,

thanks for cleaning the factory code, I think it was very much needed. I have afew suggestions, in the decreasing order of importance:
1. I would suggest that QuadroFactor is renamed to something that is 
english (BoxFactory, for instance?), and that we don't use 
center/extents for boxes anymore, it is plain frustrating (see facetBox, 
that is just horrible; why not 2 corner points? Much easier, maybe just 
for me?).
2. The SpheresFactor::pickRandomPosition should not ask to report bug 
directly... It could also suggest that SpheresFactory was used in the 
script, but that it is an abstract class and that a derived class should 
be used instead. (Unfortunately, because we used pointer hierarchy and 
serializaiton, and the macros etc, it would be very difficult to have 
real abstract classes, which would not be instantiable from python; 
although perhaps doable).
3. Perhaps you could put NozzleFactory to py/system.py in _deprecated, 
so that people with old script know that they should replace it with 
something else. OTOH it is true that it was perhaps not much used, dunno.
4. As a suggestion, instead of CircularFactory, we could perhaps have 
PolygonFactory (that is what edem uses, regular polygon specified by 
number of vertices and radius). it is  more flexible, and not much more 
complicated perhaps, no? Sorry, I know I am suggesting you to do 
something extra :-|
Cheers, Vaclav



Follow ups

References