Sha256: 6b2a57c86eaeccf2122360fd1c49cba9dc2011e94adb88b315bf63f7cc9464d9

Contents?: true

Size: 703 Bytes

Versions: 1

Compression:

Stored size: 703 Bytes

Contents

# frozen_string_literal: true

require "logger"

module Mountapi
  # Config management
  class Config
    attr_accessor :version_in_path, :logger, :user_info_adapter
    attr_reader :open_api_spec

    # Constructor setting the version path prefix to true by default and registering the logger
    def initialize
      @version_in_path = true
      @logger = Logger.new(STDOUT)
    end

    # Allow to assign one or more OpenAPI specs to MountAPI
    #
    # @param specs [String, Array<String>] a string (or an array of strings) representing an OpenAPI definition
    # @return [Array] an array of OpenAPI definitions
    def open_api_spec=(specs)
      @open_api_spec = Array(specs)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
mountapi-0.11.1 lib/mountapi/config.rb