original_string: public static function get_authors($id, $from, $limit, $options) {
          global $PAGE;
  
          $params = self::validate_parameters(self::get_authors_parameters(), array(
              'id' => $id,
              'from' => $from,
              'limit' => $limit,
              'options' => $options,
          ));
          $id = $params['id'];
          $from = $params['from'];
          $limit = $params['limit'];
          $options = $params['options'];
          $warnings = array();
  
          // Get and validate the glossary.
          list($glossary, $context) = self::validate_glossary($id);
  
          // Fetching the entries.
          list($users, $count) = glossary_get_authors($glossary, $context, $limit, $from, $options);
  
          $canviewfullnames = has_capability('moodle/site:viewfullnames', $context);
          foreach ($users as $user) {
              $userpicture = new user_picture($user);
              $userpicture->size = 1;
  
              $author = new stdClass();
              $author->id = $user->id;
              $author->fullname = fullname($user, $canviewfullnames);
              $author->pictureurl = $userpicture->get_url($PAGE)->out(false);
              $authors[] = $author;
          }
          $users->close();
  
          return array(
              'count' => $count,
              'authors' => $authors,
              'warnings' => array(),
          );
      }
code: public static function get_authors($id, $from, $limit, $options) {
          global $PAGE;
  
          $params = self::validate_parameters(self::get_authors_parameters(), array(
              'id' => $id,
              'from' => $from,
              'limit' => $limit,
              'options' => $options,
          ));
          $id = $params['id'];
          $from = $params['from'];
          $limit = $params['limit'];
          $options = $params['options'];
          $warnings = array();
  
          // Get and validate the glossary.
          list($glossary, $context) = self::validate_glossary($id);
  
          // Fetching the entries.
          list($users, $count) = glossary_get_authors($glossary, $context, $limit, $from, $options);
  
          $canviewfullnames = has_capability('moodle/site:viewfullnames', $context);
          foreach ($users as $user) {
              $userpicture = new user_picture($user);
              $userpicture->size = 1;
  
              $author = new stdClass();
              $author->id = $user->id;
              $author->fullname = fullname($user, $canviewfullnames);
              $author->pictureurl = $userpicture->get_url($PAGE)->out(false);
              $authors[] = $author;
          }
          $users->close();
  
          return array(
              'count' => $count,
              'authors' => $authors,
              'warnings' => array(),
          );
      }
code_tokens: public static function get_authors ( $ id , $ from , $ limit , $ options ) { global $ PAGE ; $ params = self :: validate_parameters ( self :: get_authors_parameters ( ) , array ( 'id' => $ id , 'from' => $ from , 'limit' => $ limit , 'options' => $ options , ) ) ; $ id = $ params [ 'id' ] ; $ from = $ params [ 'from' ] ; $ limit = $ params [ 'limit' ] ; $ options = $ params [ 'options' ] ; $ warnings = array ( ) ; // Get and validate the glossary. list ( $ glossary , $ context ) = self :: validate_glossary ( $ id ) ; // Fetching the entries. list ( $ users , $ count ) = glossary_get_authors ( $ glossary , $ context , $ limit , $ from , $ options ) ; $ canviewfullnames = has_capability ( 'moodle/site:viewfullnames' , $ context ) ; foreach ( $ users as $ user ) { $ userpicture = new user_picture ( $ user ) ; $ userpicture -> size = 1 ; $ author = new stdClass ( ) ; $ author -> id = $ user -> id ; $ author -> fullname = fullname ( $ user , $ canviewfullnames ) ; $ author -> pictureurl = $ userpicture -> get_url ( $ PAGE ) -> out ( false ) ; $ authors [ ] = $ author ; } $ users -> close ( ) ; return array ( 'count' => $ count , 'authors' => $ authors , 'warnings' => array ( ) , ) ; }
docstring: Get the authors of a glossary.
  
  @param int $id The glossary ID.
  @param int $from Start returning records from here.
  @param int $limit Number of records to return.
  @param array $options Array of options.
  @return array Containing count, authors and warnings.
  @since Moodle 3.1
  @throws moodle_exception
docstring_tokens: Get the authors of a glossary .