original_string: public static function data_for_competency_summary($competencyid, $includerelated = false, $includecourses = false) {
          global $PAGE;
          $params = self::validate_parameters(self::data_for_competency_summary_parameters(), array(
              'competencyid' => $competencyid,
              'includerelated' => $includerelated,
              'includecourses' => $includecourses
          ));
  
          $competency = api::read_competency($params['competencyid']);
          $framework = api::read_framework($competency->get_competencyframeworkid());
          self::validate_context($framework->get_context());
          $renderable = new output\competency_summary($competency, $framework, $params['includerelated'], $params['includecourses']);
          $renderer = $PAGE->get_renderer('tool_lp');
  
          $data = $renderable->export_for_template($renderer);
  
          return $data;
      }
code: public static function data_for_competency_summary($competencyid, $includerelated = false, $includecourses = false) {
          global $PAGE;
          $params = self::validate_parameters(self::data_for_competency_summary_parameters(), array(
              'competencyid' => $competencyid,
              'includerelated' => $includerelated,
              'includecourses' => $includecourses
          ));
  
          $competency = api::read_competency($params['competencyid']);
          $framework = api::read_framework($competency->get_competencyframeworkid());
          self::validate_context($framework->get_context());
          $renderable = new output\competency_summary($competency, $framework, $params['includerelated'], $params['includecourses']);
          $renderer = $PAGE->get_renderer('tool_lp');
  
          $data = $renderable->export_for_template($renderer);
  
          return $data;
      }
code_tokens: public static function data_for_competency_summary ( $ competencyid , $ includerelated = false , $ includecourses = false ) { global $ PAGE ; $ params = self :: validate_parameters ( self :: data_for_competency_summary_parameters ( ) , array ( 'competencyid' => $ competencyid , 'includerelated' => $ includerelated , 'includecourses' => $ includecourses ) ) ; $ competency = api :: read_competency ( $ params [ 'competencyid' ] ) ; $ framework = api :: read_framework ( $ competency -> get_competencyframeworkid ( ) ) ; self :: validate_context ( $ framework -> get_context ( ) ) ; $ renderable = new output \ competency_summary ( $ competency , $ framework , $ params [ 'includerelated' ] , $ params [ 'includecourses' ] ) ; $ renderer = $ PAGE -> get_renderer ( 'tool_lp' ) ; $ data = $ renderable -> export_for_template ( $ renderer ) ; return $ data ; }
docstring: Loads the data required to render the competency_page template.
  
  @param int $competencyid Competency id.
  @param boolean $includerelated Include or not related competencies.
  @param boolean $includecourses Include or not competency courses.
  
  @return \stdClass
docstring_tokens: Loads the data required to render the competency_page template .