Sebastian Padwrote:
> Is there a way of _forcing_ methods to be
> overwritten when including a module?

Here's a somewhat wild suggestion that I have found useful when running
up against the limitations of ruby's modules: use a proc instead. That is,
instead of:

  module ModuleA
    def pluginMethod
      puts "module A"
    end
  end

use

  ModuleA = proc do
    def pluginMethod
      puts "module A"
    end
  end

and then instance_eval the blocks instead of extending:

   ...
   if param == "useA" then
     instance_eval(ModuleA)

If there's just one method that changes, you might be better off using 
define_method... but this way will handle more than one method. You
will get a warning about method redefinition if you enable warnings.... I think 
undef'ing the method first will disable it.

This also works around the problem of not being able to redefine an already
existing method of a class in a module that gets included in that class. It is a fairly
low-level approach, so use with caution