Automattic\WooCommerce\Internal\Api\Autogenerated\GraphQLTypes\Pagination
ProductConnection{}
No Hooks.
Usage
$ProductConnection = new ProductConnection(); // use class methods
Methods
- public static get()
ProductConnection{} ProductConnection{} code WC 10.9.1
class ProductConnection {
private static ?ObjectType $instance = null;
public static function get(): ObjectType {
if ( null === self::$instance ) {
self::$instance = new ObjectType(
array(
'name' => 'ProductConnection',
'description' => __( 'A connection to a list of Product items.', 'woocommerce' ),
'fields' => fn() => array(
'edges' => array(
'type' => Type::nonNull(
Type::listOf(
Type::nonNull(
ProductEdge::get()
)
)
),
),
'nodes' => array(
'type' => Type::nonNull(
Type::listOf(
Type::nonNull(
ProductType::get()
)
)
),
),
'page_info' => array(
'type' => Type::nonNull( PageInfo::get() ),
),
'total_count' => array(
'type' => Type::nonNull( Type::int() ),
),
),
)
);
}
return self::$instance;
}
}