Module: Kiba::Extend::Registry::RequirableFile
- Included in:
- RegisteredLookup, RegisteredSource
- Defined in:
- lib/kiba/extend/registry/requirable_file.rb
Overview
Mixin module for children of RegisteredFile that other jobs depend upon
Defined Under Namespace
Classes: NoDependencyCreatorError
Instance Method Summary collapse
-
#required ⇒ Method
The creator method for a required dependency job.
Instance Method Details
#required ⇒ Method
Returns the creator method for a required dependency job.
21 22 23 24 25 26 27 28 29 30 |
# File 'lib/kiba/extend/registry/requirable_file.rb', line 21 def required return if File.exist?(@data.path) %i[missing_creator_for_non_supplied_file creator_not_a_method].each do |err| raise NoDependencyCreatorError, @key if @data.errors.keys.any?(err) end @data.creator end |