Class: Appsignal::Config
- Defined in:
- lib/appsignal/config.rb,
sig/appsignal.rbs
Defined Under Namespace
Classes: ConfigDSL
Instance Method Summary collapse
-
#active? ⇒ Boolean
Check if AppSignal is active.
-
#active_for_env? ⇒ Boolean
Check if AppSignal is active for the current environment.
-
#valid? ⇒ Boolean
Check if the configuration is valid.
- #yml_config_file? ⇒ Boolean private
Instance Method Details
#active? ⇒ Boolean
Check if AppSignal is active.
@return — True if valid and active for the current environment.
451 452 453 |
# File 'lib/appsignal/config.rb', line 451 def active? valid? && active_for_env? end |
#active_for_env? ⇒ Boolean
Check if AppSignal is active for the current environment.
@return — True if active for the current environment.
444 445 446 |
# File 'lib/appsignal/config.rb', line 444 def active_for_env? config_hash[:active] end |
#valid? ⇒ Boolean
Check if the configuration is valid.
@return — True if the configuration is valid, false otherwise.
437 438 439 |
# File 'lib/appsignal/config.rb', line 437 def valid? @valid end |
#yml_config_file? ⇒ Boolean
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.
546 547 548 549 550 |
# File 'lib/appsignal/config.rb', line 546 def yml_config_file? return false unless yml_config_file File.exist?(yml_config_file) end |