| Conditions | 1 |
| Paths | 1 |
| Total Lines | 33 |
| Code Lines | 17 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 12 | public function __construct() |
||
| 13 | { |
||
| 14 | $configuration = [ |
||
| 15 | /** |
||
| 16 | * Because you may create multiple drivers and assign types to the |
||
| 17 | * schema from each, there would be a name collision if this object |
||
| 18 | * used only the name `PageInfo` as defined in section 2.1.2 of the |
||
| 19 | * GraphQL spec:ification. |
||
| 20 | * https://relay.dev/graphql/connections.htm#sec-Connection-Types.Fields.PageInfo |
||
| 21 | */ |
||
| 22 | 'name' => 'PageInfo', |
||
| 23 | 'description' => 'Page information', |
||
| 24 | 'fields' => [ |
||
| 25 | 'startCursor' => [ |
||
| 26 | 'description' => 'Cursor corresponding to the first node in edges.', |
||
| 27 | 'type' => Type::nonNull(Type::string()), |
||
| 28 | ], |
||
| 29 | 'endCursor' => [ |
||
| 30 | 'description' => 'Cursor corresponding to the last node in edges.', |
||
| 31 | 'type' => Type::nonNull(Type::string()), |
||
| 32 | ], |
||
| 33 | 'hasPreviousPage' => [ |
||
| 34 | 'description' => 'If edges contains more than last elements return true, otherwise false.', |
||
| 35 | 'type' => Type::nonNull(Type::boolean()), |
||
| 36 | ], |
||
| 37 | 'hasNextPage' => [ |
||
| 38 | 'description' => 'If edges contains more than first elements return true, otherwise false.', |
||
| 39 | 'type' => Type::nonNull(Type::boolean()), |
||
| 40 | ], |
||
| 41 | ], |
||
| 42 | ]; |
||
| 43 | |||
| 44 | parent::__construct($configuration); |
||
| 45 | } |
||
| 47 |