Class: SmartCore::Container::DependencyWatcher::Observer Private

Inherits:
Object
  • Object
show all
Defined in:
lib/smart_core/container/dependency_watcher/observer.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Since:

  • 0.8.0

Instance Method Summary collapse

Constructor Details

#initialize(container, dependency_path, callback) ⇒ void

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Parameters:

Since:

  • 0.8.0



13
14
15
16
17
# File 'lib/smart_core/container/dependency_watcher/observer.rb', line 13

def initialize(container, dependency_path, callback)
  @container = container
  @dependency_path = dependency_path
  @callback = callback
end

Instance Method Details

#notify!void

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

This method returns an undefined value.

Since:

  • 0.8.0



23
24
25
# File 'lib/smart_core/container/dependency_watcher/observer.rb', line 23

def notify!
  callback.call(dependency_path, container)
end