def define(m)
      if m.is_a?(Method)
        @methods[m.name.to_sym] = m
      elsif m.is_a?(Signal)
        @signals[m.name.to_sym] = m
      end
    end
def define(m)
      if m.is_a?(Method)
        @methods[m.name.to_sym] = m
      elsif m.is_a?(Signal)
        @signals[m.name.to_sym] = m
      end
    end
Helper method for defining a method _m_.