Class ConnectionResolver
Class Connections
This class is meant to be extended by ConnectionResolvers
- WPGraphQL\Data\ConnectionResolver implements WPGraphQL\Data\ConnectionResolverInterface
Direct known subclasses
WPGraphQL\Type\Comment\Connection\CommentConnectionResolver
,
WPGraphQL\Type\PostObject\Connection\PostObjectConnectionResolver
,
WPGraphQL\Type\TermObject\Connection\TermObjectConnectionResolver
,
WPGraphQL\Type\User\Connection\UserConnectionResolver
Methods summary
public static
array
|
#
resolve( mixed $source, array $args,
Runs the query for comments |
public static
array
|
#
get_connection( mixed $query, array $array, mixed $source, array $args,
Take an array return a connection |
public static
array
|
#
get_array_slice( mixed $query, array $args )
This returns a slice of the query results based on the posts retrieved and the $args passed to the query |
public static
integer|null
|
#
get_amount_requested( array $args )
This checks the $args to determine the amount requested, and if |
public static
mixed
|
|
public static
array
|
#
get_array_meta( mixed $query, array $args )
This returns a meta array to be used in preparing the connection edges |
public static
integer|mixed
|
#
get_offset( $args )
This returns the offset to be used in the $query_args based on the $args passed to the GraphQL query. |
public static
integer
|
#
get_query_info( mixed $query )
WordPress has different queries that return date in different shapes. This normalizes the return for re-use. |