Sha256: 1420db7821f03640541d58662f05bf04eddcea047b6f4dc652e1674bc485e9b9

Contents?: true

Size: 522 Bytes

Versions: 24

Compression:

Stored size: 522 Bytes

Contents

# frozen_string_literal: true

module Typesense
  class Override
    def initialize(collection_name, override_id, api_call)
      @collection_name = collection_name
      @override_id     = override_id
      @api_call        = api_call
    end

    def retrieve
      @api_call.get(endpoint_path)
    end

    def delete
      @api_call.delete(endpoint_path)
    end

    private

    def endpoint_path
      "#{Collections::RESOURCE_PATH}/#{@collection_name}#{Overrides::RESOURCE_PATH}/#{@override_id}"
    end
  end
end

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
typesense-1.1.0 lib/typesense/override.rb
typesense-1.0.0 lib/typesense/override.rb
typesense-0.15.0 lib/typesense/override.rb
typesense-0.14.1 lib/typesense/override.rb
typesense-0.14.0 lib/typesense/override.rb
typesense-0.13.0 lib/typesense/override.rb
typesense-0.12.0 lib/typesense/override.rb
typesense-0.11.1 lib/typesense/override.rb
typesense-0.11.0 lib/typesense/override.rb
typesense-0.10.0 lib/typesense/override.rb
typesense-0.9.0 lib/typesense/override.rb
typesense-0.8.0 lib/typesense/override.rb
typesense-0.8.0pre lib/typesense/override.rb
typesense-0.7.0 lib/typesense/override.rb
typesense-0.7.0.pre1 lib/typesense/override.rb
typesense-0.7.0.pre0 lib/typesense/override.rb
typesense-0.6.0 lib/typesense/override.rb
typesense-0.5.5 lib/typesense/override.rb
typesense-0.5.4 lib/typesense/override.rb
typesense-0.5.3 lib/typesense/override.rb