Automattic\WooCommerce\Vendor\GraphQL\Utils
SchemaPrinter::printUnion
Method of the class: SchemaPrinter{}
No Hooks.
Returns
null. Nothing (null).
Usage
$result = SchemaPrinter::printUnion( $type, $options ): string;
- $type(UnionType) (required)
- .
- $options(array) (required)
- .
SchemaPrinter::printUnion() SchemaPrinter::printUnion code WC 10.9.4
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;
}