Parent

Methods

Class Index [+]

Quicksearch

Webgen::LoadError

This error is raised when a needed library is not found.

Attributes

library[R]

The name of the library that is missing.

gem[R]

The name of the Rubygem that provides the missing library.

Public Class Methods

new(library_or_error, class_name = nil, alcn = nil, gem = nil) click to toggle source

Create a new LoadError using the provided values.

If library_or_error is a String, it is treated as the missing library name and an approriate error message is created. If it is an exception, the exception is wrapped.

     # File lib/webgen/error.rb, line 103
103:     def initialize(library_or_error, class_name = nil, alcn = nil, gem = nil)
104:       if library_or_error.kind_of?(String)
105:         msg = "The needed library '#{library_or_error}' is missing."
106:         msg += " You can install it via rubygems with 'gem install #{gem}'!" if gem
107:         super(msg, class_name, alcn)
108:         @library = library_or_error
109:       else
110:         super(library_or_error, class_name, alcn)
111:         @library = nil
112:       end
113:       @gem = gem
114:     end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.