CoreFiles by mySites.guru
BeforeCheckinEvent.php45 lines, 1,168 bytes, from Joomla_4.2.7-Stable-Full_Package.zip
Raw History Compare with 4.2.6
md5
5376769bd14b3aaf6aef431a016a0dd8
sha1
34eb0a97feaa0a86895a6d769653440dcdfec2b0
sha256
1ea8d35f7a1c8a5499b0d318b3433a140c56022aa56fa8d06f17a1977bdafc0c
<?php

/**
 * Joomla! Content Management System
 *
 * @copyright  (C) 2016 Open Source Matters, Inc. <https://www.joomla.org>
 * @license    GNU General Public License version 2 or later; see LICENSE
 */

namespace Joomla\CMS\Event\Table;

use BadMethodCallException;

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

/**
 * Event class for JTable's onBeforeCheckin event
 *
 * @since  4.0.0
 */
class BeforeCheckinEvent extends AbstractEvent
{
    /**
     * Constructor.
     *
     * Mandatory arguments:
     * subject      JTableInterface The table we are operating on
     * pk           mixed           An optional primary key value to check out.
     *
     * @param   string  $name       The event name.
     * @param   array   $arguments  The event arguments.
     *
     * @throws  BadMethodCallException
     */
    public function __construct($name, array $arguments = [])
    {
        if (!\array_key_exists('pk', $arguments)) {
            throw new BadMethodCallException("Argument 'pk' is required for event $name");
        }

        parent::__construct($name, $arguments);
    }
}

The same content is in 16 releases, Joomla 4.2.7-rc1 to 4.3.1. See them all, or every version of this file.