Module: Module::ExtModule

Included in:
Module
Defined in:
lib/ext/module.rb

Instance Method Summary collapse

Instance Method Details

#const_missing(id) ⇒ Object



4
5
6
7
8
9
10
11
12
# File 'lib/ext/module.rb', line 4

def const_missing(id)
  if self.name =~ /^ProconBypassMan::Plugin/
    parent_const = Object.const_get("#{self.name}")
    parent_const.const_set(id, Module.new)
    Object.const_get("#{self.name}::#{id}")
  else
    super
  end
end