Module: Safely
- Defined in:
- lib/safely.rb,
lib/safely/mixin.rb,
lib/safely/config.rb,
lib/safely/version.rb,
lib/safely/strategy.rb,
lib/safely/backtrace.rb,
lib/safely/strategy/log.rb,
lib/safely/strategy/mail.rb,
lib/safely/strategy/hoptoad.rb
Defined Under Namespace
Modules: Mixin, Strategy
Classes: Backtrace, Config
Class Method Summary
collapse
Class Method Details
.config ⇒ Object
20
21
22
|
# File 'lib/safely.rb', line 20
def config
@config ||= Safely::Config.new
end
|
16
17
18
|
# File 'lib/safely.rb', line 16
def configure
yield self.config
end
|
.load_strategies! ⇒ Object
24
25
26
|
# File 'lib/safely.rb', line 24
def load_strategies!
config.strategies.each { |s| s.load! }
end
|
.report!(exception) ⇒ Object
28
29
30
31
32
|
# File 'lib/safely.rb', line 28
def report!( exception )
load_strategies! if @config.nil?
config.strategies.each { |s| s.report! exception }
end
|
.reset! ⇒ Object
12
13
14
|
# File 'lib/safely.rb', line 12
def reset!
self.config = nil
end
|
.version ⇒ Object
3
4
5
|
# File 'lib/safely/version.rb', line 3
def version
"0.3.2"
end
|