Class: DashOverlord::UseCases::V1::Videos::Index::Base

Inherits:
Base
  • Object
show all
Defined in:
lib/dash_overlord/use_cases/v1/videos/index/base.rb

Constant Summary collapse

DEFAULT_SEARCH_ADAPTER_USE_CASE =
ElasticSearch::Base

Constants inherited from Base

Base::AbortError

Instance Attribute Summary

Attributes inherited from Base

#context

Instance Method Summary collapse

Methods inherited from Base

context_reader, #initialize, perform, target, #target_valid?

Constructor Details

This class inherits a constructor from DashOverlord::UseCases::Base

Instance Method Details

#finalObject



15
16
17
18
# File 'lib/dash_overlord/use_cases/v1/videos/index/base.rb', line 15

def final
  context.data = Serializers::V1::Videos::Index.to_hash \
    context, status.ok? ? nil : false
end

#performObject



10
11
12
13
# File 'lib/dash_overlord/use_cases/v1/videos/index/base.rb', line 10

def perform
  invoke! Users::FindCurrentUser
  invoke! search_adapter_use_case
end