CoreFiles by mySites.guru
HtmlView.php57 lines, 1,260 bytes, from Joomla_5.0.3-Stable-Full_Package.zip
Raw History Compare with 5.0.2
md5
fe97532e62491d66550cca2b8d421761
sha1
12e30543527956ea57a18d87abf6e21563906772
sha256
39a6297a6613496ae0bdbbe85d18476d4d03739e768adc86b0e0b72ed792f752
<?php

/**
 * @package     Joomla.Administrator
 * @subpackage  com_finder
 *
 * @copyright   (C) 2011 Open Source Matters, Inc. <https://www.joomla.org>
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */

namespace Joomla\Component\Finder\Administrator\View\Statistics;

use Joomla\CMS\MVC\View\GenericDataException;
use Joomla\CMS\MVC\View\HtmlView as BaseHtmlView;

// phpcs:disable PSR1.Files.SideEffects
\defined('_JEXEC') or die;
// phpcs:enable PSR1.Files.SideEffects

/**
 * Statistics view class for Finder.
 *
 * @since  2.5
 */
class HtmlView extends BaseHtmlView
{
    /**
     * The index statistics
     *
     * @var    \Joomla\CMS\Object\CMSObject
     *
     * @since  3.6.1
     */
    protected $data;

    /**
     * Method to display the view.
     *
     * @param   string  $tpl  A template file to load. [optional]
     *
     * @return  void
     *
     * @since   2.5
     */
    public function display($tpl = null)
    {
        // Load the view data.
        $this->data = $this->get('Data');

        // Check for errors.
        if (\count($errors = $this->get('Errors'))) {
            throw new GenericDataException(implode("\n", $errors), 500);
        }

        parent::display($tpl);
    }
}

The same content is in 51 releases, Joomla 5.0.0-rc to 5.2.6. See them all, or every version of this file.