Sha256: 33585e35370dfcc72907cfa24f740663b3026edd3b7de52a59527ea2a70bfd1a

Contents?: true

Size: 536 Bytes

Versions: 4

Compression:

Stored size: 536 Bytes

Contents

module NotificationCenter
  module Configuration
    VALID_OPTIONS_KEYS = [:enable_cache, :enable_notifications, :method_suffix]

    DEFAULT_ENABLE_CACHE = false
    DEFAULT_ENABLE_NOTIFICATIONS = true
    DEFAULT_METHOD_SUFFIX = 'handler'

    attr_accessor *VALID_OPTIONS_KEYS

    def self.extended base
      base.reset
    end

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

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
notification_center-0.3.2 lib/notification_center/configuration.rb
notification_center-0.3.1 lib/notification_center/configuration.rb
notification_center-0.3 lib/notification_center/configuration.rb
notification_center-0.2 lib/notification_center/configuration.rb