Automattic\WooCommerce\Vendor\GraphQL\Utils

SchemaPrinter::printUnionprotected staticWC 1.0

Метод класса: SchemaPrinter{}

Хуков нет.

Возвращает

null. Ничего (null).

Использование

$result = SchemaPrinter::printUnion( $type, $options ): string;
$type(UnionType) (обязательный)
.
$options(массив) (обязательный)
.

Код SchemaPrinter::printUnion() WC 11.0.1

protected static function printUnion(UnionType $type, array $options): string
{
    $types = $type->getTypes();
    $types = $types === []
        ? ''
        : ' = ' . implode(' | ', $types);

    return static::printDescription($options, $type) . 'union ' . $type->name . $types;
}