original_string: public static function read_framework($id) {
          static::require_enabled();
          $framework = new competency_framework($id);
          if (!has_any_capability(array('moodle/competency:competencyview', 'moodle/competency:competencymanage'),
                  $framework->get_context())) {
              throw new required_capability_exception($framework->get_context(), 'moodle/competency:competencyview',
                  'nopermissions', '');
          }
          return $framework;
      }
code: public static function read_framework($id) {
          static::require_enabled();
          $framework = new competency_framework($id);
          if (!has_any_capability(array('moodle/competency:competencyview', 'moodle/competency:competencymanage'),
                  $framework->get_context())) {
              throw new required_capability_exception($framework->get_context(), 'moodle/competency:competencyview',
                  'nopermissions', '');
          }
          return $framework;
      }
code_tokens: public static function read_framework ( $ id ) { static :: require_enabled ( ) ; $ framework = new competency_framework ( $ id ) ; if ( ! has_any_capability ( array ( 'moodle/competency:competencyview' , 'moodle/competency:competencymanage' ) , $ framework -> get_context ( ) ) ) { throw new required_capability_exception ( $ framework -> get_context ( ) , 'moodle/competency:competencyview' , 'nopermissions' , '' ) ; } return $ framework ; }
docstring: Read a the details for a single competency framework and return a record.
  
  Requires moodle/competency:competencyview capability at the system context.
  
  @param int $id The id of the framework to read.
  @return competency_framework
docstring_tokens: Read a the details for a single competency framework and return a record .