Class: RestMyCase::DefenseAttorney::Base
- Inherits:
-
Object
- Object
- RestMyCase::DefenseAttorney::Base
- Defined in:
- lib/rest_my_case/defense_attorney/base.rb
Instance Method Summary collapse
- #build_case_for_the_defendant ⇒ Object
-
#initialize(trial_case) ⇒ Base
constructor
A new instance of Base.
Constructor Details
#initialize(trial_case) ⇒ Base
Returns a new instance of Base.
6 7 8 9 |
# File 'lib/rest_my_case/defense_attorney/base.rb', line 6 def initialize(trial_case) @trial_case = trial_case @trial_case.use_cases = [] end |
Instance Method Details
#build_case_for_the_defendant ⇒ Object
11 12 13 14 15 |
# File 'lib/rest_my_case/defense_attorney/base.rb', line 11 def build_case_for_the_defendant dependencies(@trial_case.defendant_class).map do |dependency| gather_all_use_cases dependency, @trial_case.defendant end end |