2020-11-05 16:21:38 +00:00
|
|
|
<?php
|
|
|
|
|
2020-11-18 21:54:20 +00:00
|
|
|
namespace Automattic\WooCommerce\Vendor\League\Container\Argument;
|
2020-11-05 16:21:38 +00:00
|
|
|
|
|
|
|
class ClassNameWithOptionalValue implements ClassNameInterface
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* @var string
|
|
|
|
*/
|
|
|
|
private $className;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var mixed
|
|
|
|
*/
|
|
|
|
private $optionalValue;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @param string $className
|
|
|
|
* @param mixed $optionalValue
|
|
|
|
*/
|
|
|
|
public function __construct(string $className, $optionalValue)
|
|
|
|
{
|
|
|
|
$this->className = $className;
|
|
|
|
$this->optionalValue = $optionalValue;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @inheritDoc
|
|
|
|
*/
|
|
|
|
public function getClassName(): string
|
|
|
|
{
|
|
|
|
return $this->className;
|
|
|
|
}
|
|
|
|
|
|
|
|
public function getOptionalValue()
|
|
|
|
{
|
|
|
|
return $this->optionalValue;
|
|
|
|
}
|
|
|
|
}
|