original_string: private static function format_data($eventdata, $eventfullpath) {
          // Get general event information.
          $eventdata[$eventfullpath] = $eventfullpath::get_static_info();
          // Create a link for further event detail.
          $url = new \moodle_url('eventdetail.php', array('eventname' => $eventfullpath));
          $link = \html_writer::link($url, $eventfullpath::get_name_with_info());
          $eventdata[$eventfullpath]['fulleventname'] = \html_writer::span($link);
          $eventdata[$eventfullpath]['fulleventname'] .= \html_writer::empty_tag('br');
          $eventdata[$eventfullpath]['fulleventname'] .= \html_writer::span($eventdata[$eventfullpath]['eventname'],
                  'report-eventlist-name');
  
          $eventdata[$eventfullpath]['crud'] = self::get_crud_string($eventdata[$eventfullpath]['crud']);
          $eventdata[$eventfullpath]['edulevel'] = self::get_edulevel_string($eventdata[$eventfullpath]['edulevel']);
          $eventdata[$eventfullpath]['legacyevent'] = $eventfullpath::get_legacy_eventname();
  
          // Mess around getting since information.
          $ref = new \ReflectionClass($eventdata[$eventfullpath]['eventname']);
          $eventdocbloc = $ref->getDocComment();
          $sincepattern = "/since\s*Moodle\s([0-9]+.[0-9]+)/i";
          preg_match($sincepattern, $eventdocbloc, $result);
          if (isset($result[1])) {
              $eventdata[$eventfullpath]['since'] = $result[1];
          } else {
              $eventdata[$eventfullpath]['since'] = null;
          }
  
          // Human readable plugin information to go with the component.
          $pluginstring = explode('\\', $eventfullpath);
          if ($pluginstring[1] !== 'core') {
              $component = $eventdata[$eventfullpath]['component'];
              $manager = get_string_manager();
              if ($manager->string_exists('pluginname', $pluginstring[1])) {
                  $eventdata[$eventfullpath]['component'] = \html_writer::span(get_string('pluginname', $pluginstring[1]));
              }
          }
  
          // Raw event data to be used to sort the "Event name" column.
          $eventdata[$eventfullpath]['raweventname'] = $eventfullpath::get_name_with_info() . ' ' . $eventdata[$eventfullpath]['eventname'];
  
          // Unset information that is not currently required.
          unset($eventdata[$eventfullpath]['action']);
          unset($eventdata[$eventfullpath]['target']);
          return $eventdata;
      }
code: private static function format_data($eventdata, $eventfullpath) {
          // Get general event information.
          $eventdata[$eventfullpath] = $eventfullpath::get_static_info();
          // Create a link for further event detail.
          $url = new \moodle_url('eventdetail.php', array('eventname' => $eventfullpath));
          $link = \html_writer::link($url, $eventfullpath::get_name_with_info());
          $eventdata[$eventfullpath]['fulleventname'] = \html_writer::span($link);
          $eventdata[$eventfullpath]['fulleventname'] .= \html_writer::empty_tag('br');
          $eventdata[$eventfullpath]['fulleventname'] .= \html_writer::span($eventdata[$eventfullpath]['eventname'],
                  'report-eventlist-name');
  
          $eventdata[$eventfullpath]['crud'] = self::get_crud_string($eventdata[$eventfullpath]['crud']);
          $eventdata[$eventfullpath]['edulevel'] = self::get_edulevel_string($eventdata[$eventfullpath]['edulevel']);
          $eventdata[$eventfullpath]['legacyevent'] = $eventfullpath::get_legacy_eventname();
  
          // Mess around getting since information.
          $ref = new \ReflectionClass($eventdata[$eventfullpath]['eventname']);
          $eventdocbloc = $ref->getDocComment();
          $sincepattern = "/since\s*Moodle\s([0-9]+.[0-9]+)/i";
          preg_match($sincepattern, $eventdocbloc, $result);
          if (isset($result[1])) {
              $eventdata[$eventfullpath]['since'] = $result[1];
          } else {
              $eventdata[$eventfullpath]['since'] = null;
          }
  
          // Human readable plugin information to go with the component.
          $pluginstring = explode('\\', $eventfullpath);
          if ($pluginstring[1] !== 'core') {
              $component = $eventdata[$eventfullpath]['component'];
              $manager = get_string_manager();
              if ($manager->string_exists('pluginname', $pluginstring[1])) {
                  $eventdata[$eventfullpath]['component'] = \html_writer::span(get_string('pluginname', $pluginstring[1]));
              }
          }
  
          // Raw event data to be used to sort the "Event name" column.
          $eventdata[$eventfullpath]['raweventname'] = $eventfullpath::get_name_with_info() . ' ' . $eventdata[$eventfullpath]['eventname'];
  
          // Unset information that is not currently required.
          unset($eventdata[$eventfullpath]['action']);
          unset($eventdata[$eventfullpath]['target']);
          return $eventdata;
      }
code_tokens: private static function format_data ( $ eventdata , $ eventfullpath ) { // Get general event information. $ eventdata [ $ eventfullpath ] = $ eventfullpath :: get_static_info ( ) ; // Create a link for further event detail. $ url = new \ moodle_url ( 'eventdetail.php' , array ( 'eventname' => $ eventfullpath ) ) ; $ link = \ html_writer :: link ( $ url , $ eventfullpath :: get_name_with_info ( ) ) ; $ eventdata [ $ eventfullpath ] [ 'fulleventname' ] = \ html_writer :: span ( $ link ) ; $ eventdata [ $ eventfullpath ] [ 'fulleventname' ] .= \ html_writer :: empty_tag ( 'br' ) ; $ eventdata [ $ eventfullpath ] [ 'fulleventname' ] .= \ html_writer :: span ( $ eventdata [ $ eventfullpath ] [ 'eventname' ] , 'report-eventlist-name' ) ; $ eventdata [ $ eventfullpath ] [ 'crud' ] = self :: get_crud_string ( $ eventdata [ $ eventfullpath ] [ 'crud' ] ) ; $ eventdata [ $ eventfullpath ] [ 'edulevel' ] = self :: get_edulevel_string ( $ eventdata [ $ eventfullpath ] [ 'edulevel' ] ) ; $ eventdata [ $ eventfullpath ] [ 'legacyevent' ] = $ eventfullpath :: get_legacy_eventname ( ) ; // Mess around getting since information. $ ref = new \ ReflectionClass ( $ eventdata [ $ eventfullpath ] [ 'eventname' ] ) ; $ eventdocbloc = $ ref -> getDocComment ( ) ; $ sincepattern = "/since\s*Moodle\s([0-9]+.[0-9]+)/i" ; preg_match ( $ sincepattern , $ eventdocbloc , $ result ) ; if ( isset ( $ result [ 1 ] ) ) { $ eventdata [ $ eventfullpath ] [ 'since' ] = $ result [ 1 ] ; } else { $ eventdata [ $ eventfullpath ] [ 'since' ] = null ; } // Human readable plugin information to go with the component. $ pluginstring = explode ( '\\' , $ eventfullpath ) ; if ( $ pluginstring [ 1 ] !== 'core' ) { $ component = $ eventdata [ $ eventfullpath ] [ 'component' ] ; $ manager = get_string_manager ( ) ; if ( $ manager -> string_exists ( 'pluginname' , $ pluginstring [ 1 ] ) ) { $ eventdata [ $ eventfullpath ] [ 'component' ] = \ html_writer :: span ( get_string ( 'pluginname' , $ pluginstring [ 1 ] ) ) ; } } // Raw event data to be used to sort the "Event name" column. $ eventdata [ $ eventfullpath ] [ 'raweventname' ] = $ eventfullpath :: get_name_with_info ( ) . ' ' . $ eventdata [ $ eventfullpath ] [ 'eventname' ] ; // Unset information that is not currently required. unset ( $ eventdata [ $ eventfullpath ] [ 'action' ] ) ; unset ( $ eventdata [ $ eventfullpath ] [ 'target' ] ) ; return $ eventdata ; }
docstring: Returns the event data list section with url links and other formatting.
  
  @param array $eventdata The event data list section.
  @param string $eventfullpath Full path to the events for this plugin / subplugin.
  @return array The event data list section with additional formatting.
docstring_tokens: Returns the event data list section with url links and other formatting .