Class: Course::Conditional::ConditionalSatisfiabilityEvaluationService

Inherits:
Object
  • Object
show all
Defined in:
app/services/course/conditional/conditional_satisfiability_evaluation_service.rb

Instance Method Summary collapse

Instance Method Details

#evaluate(course_user) ⇒ Object

Evaluate the satisfiability of the conditionals for the given course user

Parameters:

  • course_user (CourseUser)

    The course user with conditionals to be evaluated


13
14
15
16
17
18
# File 'app/services/course/conditional/conditional_satisfiability_evaluation_service.rb', line 13

def evaluate(course_user)
  @course_user = course_user
  @course = course_user.course

  update_conditions(satisfiability_graph.evaluate(@course_user))
end