original_string: public function export_related_data(array $subcontext, $name, $data) : content_writer {
          $path = $this->get_path($subcontext, "{$name}.json");
  
          $this->write_data($path, json_encode($data, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT));
  
          return $this;
      }
code: public function export_related_data(array $subcontext, $name, $data) : content_writer {
          $path = $this->get_path($subcontext, "{$name}.json");
  
          $this->write_data($path, json_encode($data, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT));
  
          return $this;
      }
code_tokens: public function export_related_data ( array $ subcontext , $ name , $ data ) : content_writer { $ path = $ this -> get_path ( $ subcontext , "{$name}.json" ) ; $ this -> write_data ( $ path , json_encode ( $ data , JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT ) ) ; return $ this ; }
docstring: Export a piece of related data.
  
  @param   array           $subcontext The location within the current context that this data belongs.
  @param   string          $name       The name of the file to be exported.
  @param   \stdClass       $data       The related data to export.
  @return  content_writer
docstring_tokens: Export a piece of related data .