Automattic\WooCommerce\Vendor\League\Container\Inflector

InflectorAggregate::add()publicWC 1.0

{@inheritdoc}

Method of the class: InflectorAggregate{}

No Hooks.

Return

null. Nothing.

Usage

$InflectorAggregate = new InflectorAggregate();
$InflectorAggregate->add( $type, $callback ) : Inflector;
$type(string) (required)
-
$callback(callable)
-
Default: null

InflectorAggregate::add() code WC 7.1.0

public function add(string $type, callable $callback = null) : Inflector
{
    $inflector          = new Inflector($type, $callback);
    $this->inflectors[] = $inflector;

    return $inflector;
}