On 13/02/07, Chad Perrin <[EMAIL PROTECTED]> wrote:
> The specific module that will be used at a given moment is supposed to be > given by a configuration file, that's why the main program doesn't know its > name a priori (but it does know the name of the subroutine, that must be the > same for all the modules). Do you mean that every time the program runs, it will always use the same module's subroutine, based on the content of a config file?
Not exactly. It can use only a module, or more than one, and that isn't known a priori. The program will fall in a kind of loop and execute the subroutines of every module that appears on the cofig file. If that's the case . . . the question of whether or not you always have
to have all those modules loaded comes up. Do you need each of these modules for reasons other than these specific subroutines? If the different modules are used only to provide different subroutines according to the configuration file, you may think about only loading the module you actually need, based on the configuration file. That might end up providing slightly more easily maintained code. If that's not what's going on, of course, carry on as you have been with the discussion. I just thought I'd bring up that idea in case it's relevant.
Thank you anyway, because you have made me think of an alternative design, but in any case I can't only load one module. Regards Ana -- "El más baldío de todos los días es aquél en que no hemos reído" (de Chamfort)