original_string: public static function create_from_record($feedback, $cm, $course) {
          $event = self::create(array(
              'objectid' => $feedback->id,
              'context' => \context_module::instance($cm->id),
              'anonymous' => ($feedback->anonymous == FEEDBACK_ANONYMOUS_YES),
              'other' => array(
                  'anonymous' => $feedback->anonymous // Deprecated.
              )
          ));
          $event->add_record_snapshot('course_modules', $cm);
          $event->add_record_snapshot('course', $course);
          $event->add_record_snapshot('feedback', $feedback);
          return $event;
      }
code: public static function create_from_record($feedback, $cm, $course) {
          $event = self::create(array(
              'objectid' => $feedback->id,
              'context' => \context_module::instance($cm->id),
              'anonymous' => ($feedback->anonymous == FEEDBACK_ANONYMOUS_YES),
              'other' => array(
                  'anonymous' => $feedback->anonymous // Deprecated.
              )
          ));
          $event->add_record_snapshot('course_modules', $cm);
          $event->add_record_snapshot('course', $course);
          $event->add_record_snapshot('feedback', $feedback);
          return $event;
      }
code_tokens: public static function create_from_record ( $ feedback , $ cm , $ course ) { $ event = self :: create ( array ( 'objectid' => $ feedback -> id , 'context' => \ context_module :: instance ( $ cm -> id ) , 'anonymous' => ( $ feedback -> anonymous == FEEDBACK_ANONYMOUS_YES ) , 'other' => array ( 'anonymous' => $ feedback -> anonymous // Deprecated. ) ) ) ; $ event -> add_record_snapshot ( 'course_modules' , $ cm ) ; $ event -> add_record_snapshot ( 'course' , $ course ) ; $ event -> add_record_snapshot ( 'feedback' , $ feedback ) ; return $ event ; }
docstring: Creates an instance from feedback record
  
  @param stdClass $feedback
  @param cm_info|stdClass $cm
  @param stdClass $course
  @return course_module_viewed
docstring_tokens: Creates an instance from feedback record