Sha256: 6ef187803e7ae677908927371d95083b5df3b5c4e1a263fa98cbb8249f93aee1

Contents?: true

Size: 628 Bytes

Versions: 9

Compression:

Stored size: 628 Bytes

Contents

require File.expand_path('connection', __dir__)
require File.expand_path('request', __dir__)

module FirebaseAdmin
  # @private
  class API
    # @private
    attr_accessor(*Configuration::VALID_OPTIONS_KEYS)

    # Creates a new API
    def initialize(options = {})
      options = FirebaseAdmin.options.merge(options)
      Configuration::VALID_OPTIONS_KEYS.each do |key|
        send("#{key}=", options[key])
      end
    end

    def config
      conf = {}
      Configuration::VALID_OPTIONS_KEYS.each do |key|
        conf[key] = send key
      end
      conf
    end

    include Connection
    include Request
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
firebase-admin-0.3.0 lib/firebase-admin/api.rb
firebase-admin-0.2.0 lib/firebase-admin/api.rb
firebase-admin-0.1.6 lib/firebase-admin/api.rb
firebase-admin-0.1.5 lib/firebase-admin/api.rb
firebase-admin-0.1.4 lib/firebase-admin/api.rb
firebase-admin-0.1.3 lib/firebase-admin/api.rb
firebase-admin-0.1.2 lib/firebase-admin/api.rb
firebase-admin-0.1.1 lib/firebase-admin/api.rb
firebase-admin-0.1.0 lib/firebase-admin/api.rb