last() public method

Returns the last value, null if empty
public last ( ) : mixed
return mixed The last value
Exemplo n.º 1
0
 /**
  * @dataProvider oneToTen
  */
 public function testThatFirstReturnsTheFirstValue(\Pinq\ITraversable $numbers, array $data)
 {
     $this->assertEquals(end($data), $numbers->last());
 }
Exemplo n.º 2
0
 public function visitLast(Requests\Last $request)
 {
     return $this->traversable->last();
 }