class GitCompound::Worker::ComponentsCollector

Worker thas collects are encountered components

Attributes

components[R]

Public Class Methods

new(collection) click to toggle source
# File lib/git_compound/worker/components_collector.rb, line 8
def initialize(collection)
  raise GitCompoundError, 'Collection should be a Hash' unless
    collection.is_a? Hash

  @components = collection
end

Public Instance Methods

visit_component(component) click to toggle source
# File lib/git_compound/worker/components_collector.rb, line 15
def visit_component(component)
  @components.store(component.name, component)
end