Module: NotificationCenter::Configuration

Included in:
NotificationCenter
Defined in:
lib/notification_center/configuration.rb

Constant Summary collapse

VALID_OPTIONS_KEYS =
[:enable_cache, :enable_notifications, :method_suffix]
DEFAULT_ENABLE_CACHE =
false
DEFAULT_ENABLE_NOTIFICATIONS =
true
DEFAULT_METHOD_SUFFIX =
'handler'

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.extended(base) ⇒ Object



11
12
13
# File 'lib/notification_center/configuration.rb', line 11

def self.extended base
  base.reset
end

Instance Method Details

#resetObject



15
16
17
18
19
20
# File 'lib/notification_center/configuration.rb', line 15

def reset
  self.enable_cache = DEFAULT_ENABLE_CACHE
  self.enable_notifications = DEFAULT_ENABLE_NOTIFICATIONS
  self.method_suffix = DEFAULT_METHOD_SUFFIX
  self
end