Sha256: 2299f32993380af7c719d0b5f9a14721abab286482ff1b9679ec256781af0e94

Contents?: true

Size: 1.3 KB

Versions: 19

Compression:

Stored size: 1.3 KB

Contents

require 'rest-client'
require 'groupdocs/version'
require 'groupdocs/errors'
require 'groupdocs/api'
require 'groupdocs/extensions'
require 'groupdocs/datasource'
require 'groupdocs/document'
require 'groupdocs/job'
require 'groupdocs/questionnaire'
require 'groupdocs/storage'
require 'groupdocs/user'

module GroupDocs
  class << self

    # @attr [String] client_id Client ID
    attr_accessor :client_id

    # @attr [String] private_key Private key
    attr_accessor :private_key

    # @attr [String] api_server API server
    attr_accessor :api_server

    # @attr [String] api_version Version of API server
    attr_accessor :api_version

    #
    # Returns hostname of API server.
    #
    # @return [String] API hostname. Default one if it has not been explicitly set
    #
    def api_server
      @api_server || 'https://api.groupdocs.com'
    end

    #
    # Calls block for configuration of GroupDocs.
    #
    # @example
    #   GroupDocs.configure do |groupdocs|
    #     groupdocs.client_id = '07aaaf95f8eb33a4'
    #     groupdocs.private_key = '5cb711b3a52ffc5d90ee8a0f79206f5a'
    #     groupdocs.api_server = 'https://api.groupdocs.com'
    #     groupdocs.api_version = '2.0'
    #   end
    #
    # @yield [GroupDocs]
    #
    def configure(&blk)
      yield self
    end

  end # << self
end # GroupDocs

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
groupdocs-0.3.11 lib/groupdocs.rb
groupdocs-0.3.10 lib/groupdocs.rb
groupdocs-0.3.9 lib/groupdocs.rb
groupdocs-0.3.8 lib/groupdocs.rb
groupdocs-0.3.7 lib/groupdocs.rb
groupdocs-0.3.6 lib/groupdocs.rb
groupdocs-0.3.5 lib/groupdocs.rb
groupdocs-0.3.0 lib/groupdocs.rb
groupdocs-0.2.11 lib/groupdocs.rb
groupdocs-0.2.10 lib/groupdocs.rb
groupdocs-0.2.9 lib/groupdocs.rb
groupdocs-0.2.8 lib/groupdocs.rb
groupdocs-0.2.7 lib/groupdocs.rb
groupdocs-0.2.6 lib/groupdocs.rb
groupdocs-0.2.5 lib/groupdocs.rb
groupdocs-0.2.4 lib/groupdocs.rb
groupdocs-0.2.3 lib/groupdocs.rb
groupdocs-0.2.2 lib/groupdocs.rb
groupdocs-0.2.1 lib/groupdocs.rb