Class: Inspec::VendorIndex
- Inherits:
-
Object
- Object
- Inspec::VendorIndex
- Defined in:
- lib/inspec/dependencies.rb
Instance Attribute Summary collapse
-
#list ⇒ Object
readonly
Returns the value of attribute list.
-
#path ⇒ Object
readonly
Returns the value of attribute path.
Instance Method Summary collapse
- #find(_dependency) ⇒ Object
-
#initialize(path) ⇒ VendorIndex
constructor
A new instance of VendorIndex.
Constructor Details
#initialize(path) ⇒ VendorIndex
Returns a new instance of VendorIndex.
192 193 194 195 196 |
# File 'lib/inspec/dependencies.rb', line 192 def initialize(path) @path = path FileUtils.mkdir_p(path) unless File.directory?(path) @list = Dir[File.join(path, '*')].map { |x| load_path(x) } end |
Instance Attribute Details
#list ⇒ Object (readonly)
Returns the value of attribute list.
191 192 193 |
# File 'lib/inspec/dependencies.rb', line 191 def list @list end |
#path ⇒ Object (readonly)
Returns the value of attribute path.
191 192 193 |
# File 'lib/inspec/dependencies.rb', line 191 def path @path end |
Instance Method Details
#find(_dependency) ⇒ Object
198 199 200 201 |
# File 'lib/inspec/dependencies.rb', line 198 def find(_dependency) # TODO fail NotImplementedError, '#find(dependency) on VendorIndex seeks implementation.' end |