Exception: Gem::Package::FormatError

Inherits:
Error show all
Defined in:
lib/rubygems/package.rb

Instance Attribute Summary collapse

Attributes inherited from Exception

#source_exception

Instance Method Summary collapse

Methods included from Deprecate

deprecate, skip, skip=, skip_during

Constructor Details

#initialize(message, source = nil) ⇒ FormatError

Returns a new instance of FormatError.



59
60
61
62
63
64
65
66
67
# File 'lib/rubygems/package.rb', line 59

def initialize(message, source = nil)
  if source
    @path = source.path

    message = message + " in #{path}" if path
  end

  super message
end

Instance Attribute Details

#pathObject (readonly)

Returns the value of attribute path



57
58
59
# File 'lib/rubygems/package.rb', line 57

def path
  @path
end