Class: Storage::Algolia::Index::Clear

Inherits:
Base show all
Defined in:
lib/storage/algolia/index/clear.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from ApplicationService

process

Constructor Details

#initialize(model_name:) ⇒ Clear

Returns a new instance of Clear.



11
12
13
# File 'lib/storage/algolia/index/clear.rb', line 11

def initialize(model_name:)
  @model_name = model_name
end

Instance Attribute Details

#model_nameObject (readonly)

Returns the value of attribute model_name.



9
10
11
# File 'lib/storage/algolia/index/clear.rb', line 9

def model_name
  @model_name
end

Instance Method Details

#processObject



15
16
17
# File 'lib/storage/algolia/index/clear.rb', line 15

def process
  index.clear
end