for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/*******************************************************************************
* This file is part of the GraphQL Bundle package.
*
* (c) YnloUltratech <[email protected]>
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
******************************************************************************/
namespace Ynlo\GraphQLBundle\Pagination;
/**
* PaginationRequest
*/
class PaginationRequest
{
* @var int
protected $first;
protected $last;
* @var string
protected $after;
protected $before;
* PaginationRequest constructor.
* @param string $first
* @param string $last
* @param string $after
* @param string $before
public function __construct($first, $last, $after, $before)
$this->first = $first;
$first
integer
string
This check looks for assignments to scalar types that may be of the wrong type.
To ensure the code behaves as expected, it may be a good idea to add an explicit type cast.
$answer = 42; $correct = false; $correct = (bool) $answer;
$this->last = $last;
$last
$this->after = $after;
$this->before = $before;
}
* @return int
public function getFirst(): ?int
return $this->first;
* @param int $first
* @return PaginationRequest
public function setFirst(int $first): PaginationRequest
return $this;
public function getLast(): ?int
return $this->last;
* @param int $last
public function setLast(int $last): PaginationRequest
* @return string
public function getAfter(): ?string
return $this->after;
public function setAfter(string $after): PaginationRequest
public function getBefore(): ?string
return $this->before;
public function setBefore(string $before): PaginationRequest
This check looks for assignments to scalar types that may be of the wrong type.
To ensure the code behaves as expected, it may be a good idea to add an explicit type cast.