Class: BiblioTech::Builders::FileInput

Inherits:
File
  • Object
show all
Defined in:
lib/bibliotech/builders/file.rb

Direct Known Subclasses

GzipExpander, IdentityFileInput

Instance Attribute Summary

Attributes inherited from Base

#config

Class Method Summary collapse

Methods inherited from File

#file, find_class

Methods inherited from Base

adapter_registry, for, #initialize, null_adapter, register, registry, supported_adapters

Constructor Details

This class inherits a constructor from BiblioTech::Builders::Base

Class Method Details

.find_explicit(config) ⇒ Object



26
27
28
29
30
31
32
# File 'lib/bibliotech/builders/file.rb', line 26

def self.find_explicit(config)
  return adapter_registry.fetch(config.expander) do
    raise "config.expander is #{config.expander.inspect} - supported expanders are #{supported_adapters.select{|ad| ad.is_a? Symbol}.join(", ")}"
  end
rescue Config::MissingConfig
  nil
end

.identity_adapterObject



22
23
24
# File 'lib/bibliotech/builders/file.rb', line 22

def self.identity_adapter
  IdentityFileInput
end

.registry_hostObject



34
35
36
# File 'lib/bibliotech/builders/file.rb', line 34

def self.registry_host
  FileInput
end