getFirstResult() public méthode

Returns NULL if {@link setFirstResult} was not applied to this QueryBuilder.
public getFirstResult ( ) : integer
Résultat integer The position of the first result.
 /**
  * @test
  */
 public function getFirstResultDelegatesToConcreteQueryBuilder()
 {
     $this->concreteQueryBuilder->getFirstResult()->shouldBeCalled()->willReturn(1);
     $this->subject->getFirstResult();
 }
 public function testSetFirstResult()
 {
     $qb = new QueryBuilder($this->conn);
     $qb->setFirstResult(10);
     $this->assertEquals(QueryBuilder::STATE_DIRTY, $qb->getState());
     $this->assertEQuals(10, $qb->getFirstResult());
 }
Exemple #3
0
 /**
  * Gets the position of the first result the query object was set to retrieve (the "offset").
  * Returns NULL if {@link setFirstResult} was not applied to this QueryBuilder.
  *
  * @return int The position of the first result.
  */
 public function getFirstResult() : int
 {
     return (int) $this->concreteQueryBuilder->getFirstResult();
 }
 /**
  * Gets the position of the first result the query object was set to retrieve (the "offset").
  * Returns NULL if {@link setFirstResult} was not applied to this QueryBuilder.
  *
  * @return integer The position of the first result.
  */
 public function getFirstResult()
 {
     return $this->queryBuilder->getFirstResult();
 }
Exemple #5
0
 /**
  * Gets the position of the first result the query object was set to retrieve (the "offset").
  * Returns NULL if {@link setFirstResult} was not applied to this query builder.
  *
  * @return integer The position of the first result.
  */
 public function getFirstResult()
 {
     return $this->qb->getFirstResult();
 }