original_string: public function get_instance_data(int $instanceid, bool $returnall = false) : array {
          $fields = $returnall ? $this->get_fields() : $this->get_visible_fields($instanceid);
          return api::get_instance_fields_data($fields, $instanceid);
      }
code: public function get_instance_data(int $instanceid, bool $returnall = false) : array {
          $fields = $returnall ? $this->get_fields() : $this->get_visible_fields($instanceid);
          return api::get_instance_fields_data($fields, $instanceid);
      }
code_tokens: public function get_instance_data ( int $ instanceid , bool $ returnall = false ) : array { $ fields = $ returnall ? $ this -> get_fields ( ) : $ this -> get_visible_fields ( $ instanceid ) ; return api :: get_instance_fields_data ( $ fields , $ instanceid ) ; }
docstring: Returns the custom field values for an individual instance
  
  The caller must check access to the instance itself before invoking this method
  
  The result is an array of data_controller objects
  
  @param int $instanceid
  @param bool $returnall return data for all fields (by default only visible fields)
  @return data_controller[] array of data_controller objects indexed by fieldid. All fields are present,
  some data_controller objects may have 'id', some not
  In the last case data_controller::get_value() and export_value() functions will return default values.
docstring_tokens: Returns the custom field values for an individual instance