Class: Puppet::Pops::Lookup::ExplainModule Private

Inherits:
ExplainTreeNode show all
Defined in:
lib/puppet/pops/lookup/explainer.rb

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.

Instance Attribute Summary

Attributes inherited from ExplainTreeNode

#event, #key, #parent, #value

Instance Method Summary collapse

Methods inherited from ExplainTreeNode

#dump_outcome, #dump_value, #found, #found_in_defaults, #found_in_overrides, #increase_indent, #location_not_found, #not_found, #result, #to_hash, #to_s

Methods inherited from ExplainNode

#branches, #dump_texts, #explain, #inspect, #text, #to_hash, #to_s

Constructor Details

#initialize(parent, module_name) ⇒ ExplainModule

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.

Returns a new instance of ExplainModule.



213
214
215
216
# File 'lib/puppet/pops/lookup/explainer.rb', line 213

def initialize(parent, module_name)
  super(parent)
  @module_name = module_name
end

Instance Method Details

#dump_on(io, indent, first_indent) ⇒ Object

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.



218
219
220
221
222
223
224
225
# File 'lib/puppet/pops/lookup/explainer.rb', line 218

def dump_on(io, indent, first_indent)
  case @event
  when :module_not_found
    io << indent << 'Module "' << @module_name << "\" not found\n"
  when :module_provider_not_found
    io << indent << 'Module data provider for module "' << @module_name << "\" not found\n"
  end
end

#module_not_foundObject

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.



227
228
229
# File 'lib/puppet/pops/lookup/explainer.rb', line 227

def module_not_found
  @event = :module_not_found
end

#module_provider_not_foundObject

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.



231
232
233
# File 'lib/puppet/pops/lookup/explainer.rb', line 231

def module_provider_not_found
  @event = :module_provider_not_found
end

#typeObject

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.



235
236
237
# File 'lib/puppet/pops/lookup/explainer.rb', line 235

def type
  :module
end