Sha256: f181ddb1091dc75ca921f9fd41df6b1faf09dee667e00f4e73191b185759e43c

Contents?: true

Size: 811 Bytes

Versions: 25

Compression:

Stored size: 811 Bytes

Contents

# frozen_string_literal: true
module Valkyrie
  module Indexing
    # A Valkyrie indexer that does nothing for all index requests. This is
    # useful for applications using alternate/legacy (e.g. ActiveFedora)
    # indexing strategies that don't want the overhead of running separate
    # index requests.
    #
    # rubocop:disable Lint/UnusedMethodArgument RuboCop wants us to accept all
    #   arguments, but we actually want to raise ArgumentError when the caller
    #   isn't using the correct signature.
    class NullIndexingAdapter
      def save(resource:)
        :noop
      end

      def save_all(resources:)
        :noop
      end

      def delete(resource:)
        :noop
      end

      def wipe!
        :noop
      end
    end
    # rubocop:enable Lint/UnusedMethodArgument
  end
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
hyrax-5.0.1 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-5.0.0 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-5.0.0.rc3 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-5.0.0.rc2 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-5.0.0.rc1 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-3.6.0 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-4.0.0 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-4.0.0.rc3 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-4.0.0.rc2 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-4.0.0.rc1 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-3.5.0 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-4.0.0.beta2 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-3.4.2 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-4.0.0.beta1 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-3.4.1 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-3.4.0 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-3.3.0 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-3.2.0 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-3.1.0 lib/valkyrie/indexing/null_indexing_adapter.rb
hyrax-3.0.2 lib/valkyrie/indexing/null_indexing_adapter.rb