Module: Bundler::Plugin::Events
| Relationships & Source Files | |
| Defined in: | lib/bundler/plugin/events.rb | 
Constant Summary
- 
    GEM_AFTER_INSTALL_ALL =
    
 # File 'lib/bundler/plugin/events.rb', line 3"after-install-all"
- 
    GEM_BEFORE_INSTALL_ALL =
    
 # File 'lib/bundler/plugin/events.rb', line 3"before-install-all"
Class Method Summary
- 
    
      .defined_event?(event)  ⇒ Boolean 
    
    Check if an event has been defined. 
- .define(const, event) private
- .reset private
Class Method Details
.define(const, event) (private)
[ GitHub ]# File 'lib/bundler/plugin/events.rb', line 6
def self.define(const, event) const = const.to_sym.freeze if const_defined?(const) && const_get(const) != event raise ArgumentError, "Attempting to reassign #{const} to a different value" end const_set(const, event) unless const_defined?(const) @events ||= {} @events[event] = const end
    .defined_event?(event)  ⇒ Boolean 
  
Check if an event has been defined
# File 'lib/bundler/plugin/events.rb', line 28
def self.defined_event?(event) @events ||= {} @events.key?(event) end
.reset (private)
[ GitHub ]# File 'lib/bundler/plugin/events.rb', line 17
def self.reset @events.each_value do |const| remove_const(const) end @events = nil end