Class: ErrorStalker::Plugin::Base
- Inherits:
-
Object
- Object
- ErrorStalker::Plugin::Base
- Defined in:
- lib/error_stalker/plugin/base.rb
Overview
The base ErrorStalker::Plugin, that all plugins should inherit from. Provides default implementations of all the supported plugin methods, so you can (and should) call super
in your plugin subclasses.
Direct Known Subclasses
Instance Method Summary collapse
-
#after_create(app, exception_report) ⇒ Object
Called after a new exception is reported.
-
#exception_links(exception_report) ⇒ Object
An array of [name, href] pairs of links that will show up on the exception detail page.
-
#initialize(app, params = {}) ⇒ Base
constructor
Create a new instance of this plugin.
Constructor Details
#initialize(app, params = {}) ⇒ Base
Create a new instance of this plugin. app
is the sinatra ErrorStalker::Server instance, and params
is an arbitrary hash of plugin-specific parameters or options.
9 10 |
# File 'lib/error_stalker/plugin/base.rb', line 9 def initialize(app, params = {}) end |
Instance Method Details
#after_create(app, exception_report) ⇒ Object
Called after a new exception is reported. At the point that this is called, exception_report
will have an ID and has been associated with an exception group.
22 23 |
# File 'lib/error_stalker/plugin/base.rb', line 22 def after_create(app, exception_report) end |
#exception_links(exception_report) ⇒ Object
An array of [name, href] pairs of links that will show up on the exception detail page. These are most commonly used to link to additional routes added by the plugin.
15 16 17 |
# File 'lib/error_stalker/plugin/base.rb', line 15 def exception_links(exception_report) [] end |