WordPress at a glance
class is not described

Automattic\WooCommerce\Vendor\League\Container\Argument

ClassNameWithOptionalValue{} WC 1.0

No Hooks.

Return

Null. Nothing.

Usage

$ClassNameWithOptionalValue = new ClassNameWithOptionalValue();
// use class methods

Methods

  1. __construct(string $className, $optionalValue)
  2. getClassName()
  3. getOptionalValue()

Code of ClassNameWithOptionalValue{} WC 5.0.0

<?php
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;
    }
}