Sha256: c36e4cc311b8d95daa7811726145f6bca6ec6701fb0b885aba6859f8ceabc678

Contents?: true

Size: 408 Bytes

Versions: 37

Compression:

Stored size: 408 Bytes

Contents

require 'quick_travel/adapter'

module QuickTravel
  class Configuration
    attr_accessor :url, :access_key, :version

    def url=(url)
      @url = url
      QuickTravel::Adapter.base_uri url
    end

    attr_writer :access_key
  end

  def self.configure
    yield QuickTravel.config
  end

  def self.config
    @config ||= QuickTravel::Configuration.new
  end

  def self.url
    config.url
  end
end

Version data entries

37 entries across 37 versions & 1 rubygems

Version Path
quicktravel_client-4.4.0 lib/quick_travel/config.rb
quicktravel_client-4.3.2 lib/quick_travel/config.rb
quicktravel_client-4.3.1 lib/quick_travel/config.rb
quicktravel_client-4.3.0 lib/quick_travel/config.rb
quicktravel_client-4.2.0 lib/quick_travel/config.rb
quicktravel_client-4.1.0 lib/quick_travel/config.rb
quicktravel_client-4.0.0 lib/quick_travel/config.rb
quicktravel_client-3.9.0 lib/quick_travel/config.rb
quicktravel_client-3.8.1 lib/quick_travel/config.rb
quicktravel_client-3.8.0 lib/quick_travel/config.rb
quicktravel_client-1.1.2 lib/quick_travel/config.rb
quicktravel_client-3.7.0 lib/quick_travel/config.rb
quicktravel_client-3.6.1 lib/quick_travel/config.rb
quicktravel_client-3.6.0 lib/quick_travel/config.rb
quicktravel_client-3.5.0 lib/quick_travel/config.rb
quicktravel_client-3.4.0 lib/quick_travel/config.rb
quicktravel_client-3.3.0 lib/quick_travel/config.rb
quicktravel_client-3.2.0 lib/quick_travel/config.rb
quicktravel_client-3.1.0 lib/quick_travel/config.rb
quicktravel_client-3.0.0 lib/quick_travel/config.rb