Exception: Flows::Plugin::DependencyInjector::MissingDependencyDefaultError

Inherits:
Error
  • Object
show all
Defined in:
lib/flows/plugin/dependency_injector/errors.rb

Overview

Raised when an optional dependency has no default value.

Since:

  • 0.4.0

Instance Method Summary collapse

Constructor Details

#initialize(klass, name) ⇒ MissingDependencyDefaultError

Returns a new instance of MissingDependencyDefaultError.

Since:

  • 0.4.0



47
48
49
50
# File 'lib/flows/plugin/dependency_injector/errors.rb', line 47

def initialize(klass, name)
  @klass = klass
  @_name = name
end

Instance Method Details

#messageObject

Since:

  • 0.4.0



52
53
54
# File 'lib/flows/plugin/dependency_injector/errors.rb', line 52

def message
  "Optional dependency #{@_name} for #{@klass} has no default value"
end