<?php
|
namespace JVBase\managers\SEO\render\Traits\_Properties;
|
|
use JVBase\managers\SEO\render\Thing\Organization\Organization;
|
use JVBase\managers\SEO\render\Thing\Person\Person;
|
use JVBase\managers\SEO\render\Traits\_Helpers\arrayHelper;
|
|
if (!defined('ABSPATH')) {
|
exit;
|
}
|
trait publisherTrait {
|
use arrayHelper;
|
/**
|
* @var Organization|Person|array The publisher of the article in question.
|
*/
|
protected Organization|Person|array $publisher;
|
|
public function getPublisher():Organization|Person|array|null
|
{
|
return $this->publisher??null;
|
}
|
public function setPublisher(Organization|Person|array $publisher):void
|
{
|
if (is_array($publisher)) {
|
$publisher = $this->mixedArray('publisher', $publisher, [
|
'JVBase\managers\SEO\render\Thing\Organization\Organization',
|
'JVBase\managers\SEO\render\Thing\Person\Person'
|
]);
|
}
|
$this->publisher = $publisher;
|
}
|
}
|