You are here

function views_oai_pmh_plugin_row_auto::render in Views OAI-PMH 7.2

Same name and namespace in other branches
  1. 6.2 plugins/views_oai_pmh_plugin_row_auto.inc \views_oai_pmh_plugin_row_auto::render()

Render a row object. This usually passes through to a theme template of some form, but not always.

Parameters

stdClass $row: A single row of the query result, so an element of $view->result.

Return value

string The rendered output of a single row, used by the style plugin.

Overrides views_plugin_row::render

File

plugins/views_oai_pmh_plugin_row_auto.inc, line 112
Definition of the views_oai_pmh_plugin_row_auto class.

Class

views_oai_pmh_plugin_row_auto

Code

function render($row) {
  if ($this
    ->_check_row_objects()) {

    // We only want to "render" the appropriate object from our set.
    if (!empty($this->_row_objects[$this->_metadata_format]) && is_object($this->_row_objects[$this->_metadata_format])) {

      // Call the object's render() function and return its result.
      return $this->_row_objects[$this->_metadata_format]
        ->render($row);
    }
  }
  return '';
}