Sha256: f7a30c25d8948bf96c5f8eea85df354f2c84e79825062daf8682ccd739adbd91

Contents?: true

Size: 465 Bytes

Versions: 15

Compression:

Stored size: 465 Bytes

Contents

module OmfEc
  module GroupExt
    @@methods_to_fwd = []

    def fwd_method_to_aliases(*m)
      @@methods_to_fwd += m.flatten
    end

    def method_added(m)
      if @@methods_to_fwd.delete(m)
        alias_method "#{m}_without_fwd_to_aliases", m
        define_method m do |*args, &block|
          method("#{m}_without_fwd_to_aliases").call(*args, &block)
          self.g_aliases.each { |g| g.send(m, *args, &block) }
        end
      end
    end
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
omf_ec-6.2.3 lib/omf_ec/group_ext.rb
omf_ec-6.2.2 lib/omf_ec/group_ext.rb
omf_ec-6.2.1 lib/omf_ec/group_ext.rb
omf_ec-6.2.0 lib/omf_ec/group_ext.rb
omf_ec-6.2.0.pre.2 lib/omf_ec/group_ext.rb
omf_ec-6.2.0.pre.1 lib/omf_ec/group_ext.rb
omf_ec-6.1.14.pre.2 lib/omf_ec/group_ext.rb
omf_ec-6.1.14.pre.1 lib/omf_ec/group_ext.rb
omf_ec-6.1.12 lib/omf_ec/group_ext.rb
omf_ec-6.1.11 lib/omf_ec/group_ext.rb
omf_ec-6.1.10 lib/omf_ec/group_ext.rb
omf_ec-6.1.9 lib/omf_ec/group_ext.rb
omf_ec-6.1.9.pre.4 lib/omf_ec/group_ext.rb
omf_ec-6.1.9.pre.3 lib/omf_ec/group_ext.rb
omf_ec-6.1.9.pre.2 lib/omf_ec/group_ext.rb