<?php
|
namespace JVBase\managers\SEO\render\Traits\_Properties;
|
|
use JVBase\managers\SEO\render\Thing\CreativeWork\CreativeWork;
|
|
if (!defined('ABSPATH')) {
|
exit;
|
}
|
trait sdLicenseTrait {
|
/**
|
* @var CreativeWork|string A license document that applies to this structured data, typically indicated by URL.
|
*/
|
protected CreativeWork|string $sdLicense;
|
|
public function getSdLicense():CreativeWork|string|null
|
{
|
return $this->sdLicense??null;
|
}
|
public function setSdLicense(CreativeWork|string $sdLicense):void
|
{
|
if (is_string($sdLicense) && !filter_var($sdLicense, FILTER_VALIDATE_URL)) {
|
error_log('[SEO]sdLicense is meant to be a URL: '.$sdLicense);
|
return;
|
}
|
$this->sdLicense = $sdLicense;
|
}
|
}
|