Exception: Puppet::ModuleTool::Errors::MissingPackageError Private
- Inherits:
-
InstallError
- Object
- RuntimeError
- Error
- ModuleToolError
- InstallError
- Puppet::ModuleTool::Errors::MissingPackageError
- Defined in:
- lib/puppet/module_tool/errors/installer.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 Error
Instance Method Summary collapse
-
#initialize(options) ⇒ MissingPackageError
constructor
private
A new instance of MissingPackageError.
- #multiline ⇒ Object private
Methods inherited from ModuleToolError
Constructor Details
#initialize(options) ⇒ MissingPackageError
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 MissingPackageError.
29 30 31 32 33 34 |
# File 'lib/puppet/module_tool/errors/installer.rb', line 29 def initialize() @requested_package = [:requested_package] @source = [:source] super _("Could not install '%{requested_package}'; no releases are available from %{source}") % { requested_package: @requested_package, source: @source } end |
Instance Method Details
#multiline ⇒ 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.
36 37 38 39 40 41 42 |
# File 'lib/puppet/module_tool/errors/installer.rb', line 36 def multiline = [] << _("Could not install '%{requested_package}'") % { requested_package: @requested_package } << _(" No releases are available from %{source}") % { source: @source } << _(" Does '%{requested_package}' have at least one published release?") % { requested_package: @requested_package } .join("\n") end |