/**
* Setter for the subject argument
*
* @param TableInterface $value The value to set
*
* @return TableInterface
*
* @throws BadMethodCallException If the argument is not of the expected type.
*/
protected function setSubject($value)
{
if (!\is_object($value) || !$value instanceof TableInterface) {
throw new BadMethodCallException("Argument 'subject' of event {$this->name} is not of the expected type");
}
return $value;
}