Sha256: 0db887840010f4b7bea2aefb5f773ea71c424ff1c8a348aa182a8685e99943f4

Contents?: true

Size: 547 Bytes

Versions: 12

Compression:

Stored size: 547 Bytes

Contents

module Sidetiq
  class << self
    # Public: Sets the configuration used by Sidetiq.
    attr_writer :config

    # Public: Configuration wrapper for block configurations.
    #
    # Examples
    #
    #   Sidetiq.configure do |config|
    #     config.resolution = 0.2
    #   end
    #
    # Yields the configuration OpenStruct currently set.
    # Returns nothing.
    def configure
      yield config
    end

    # Public: Returns the current configuration used by Sidetiq.
    def config
      @config ||= OpenStruct.new
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
sidetiq-0.3.7 lib/sidetiq/config.rb
sidetiq-0.3.6 lib/sidetiq/config.rb
sidetiq-0.3.5 lib/sidetiq/config.rb
sidetiq-0.3.4 lib/sidetiq/config.rb
sidetiq-0.3.3 lib/sidetiq/config.rb
sidetiq-0.3.2 lib/sidetiq/config.rb
sidetiq-0.3.1 lib/sidetiq/config.rb
sidetiq-0.3.0 lib/sidetiq/config.rb
sidetiq-0.2.0 lib/sidetiq/config.rb
sidetiq-0.1.5 lib/sidetiq/config.rb
sidetiq-0.1.4 lib/sidetiq/config.rb
sidetiq-0.1.3 lib/sidetiq/config.rb