Class: WinewooCore::UseCases::BaseUseCase

Inherits:
Object
  • Object
show all
Defined in:
lib/winewoo_core/use_cases/base_use_case.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(repository, log_params = nil) ⇒ BaseUseCase

Returns a new instance of BaseUseCase.



4
5
6
7
8
9
# File 'lib/winewoo_core/use_cases/base_use_case.rb', line 4

def initialize(repository, log_params=nil)
  @repo = repository
  @log_repo = WinewooCore::Repositories::Mongo::WinewooUserLogsMongoRepo.new
  @log_params = log_params
  @authorizer = WinewooCore.authorizer.new
end

Instance Attribute Details

#authorizerObject

Returns the value of attribute authorizer.



15
16
17
# File 'lib/winewoo_core/use_cases/base_use_case.rb', line 15

def authorizer
  @authorizer
end

#current_callerObject

Returns the value of attribute current_caller.



16
17
18
# File 'lib/winewoo_core/use_cases/base_use_case.rb', line 16

def current_caller
  @current_caller
end

#log_paramsObject

Returns the value of attribute log_params.



14
15
16
# File 'lib/winewoo_core/use_cases/base_use_case.rb', line 14

def log_params
  @log_params
end

#log_repoObject

Returns the value of attribute log_repo.



13
14
15
# File 'lib/winewoo_core/use_cases/base_use_case.rb', line 13

def log_repo
  @log_repo
end

#repoObject

Returns the value of attribute repo.



12
13
14
# File 'lib/winewoo_core/use_cases/base_use_case.rb', line 12

def repo
  @repo
end