merge() публичный Метод

Merge the given array into the data of this row and return a new instance.
public merge ( array $array ) : Row
$array array
Результат Row
Пример #1
0
 /**
  * It should merge a given array and return a new instance with the
  * merged data.
  */
 public function testMerge()
 {
     $row = new Row(['bar' => 'bar']);
     $row->setFormatParams(['of' => 'fo']);
     $new = $row->merge(['foo' => 'foo']);
     $this->assertNotSame($row, $new);
     $this->assertEquals(['of' => 'fo'], $new->getFormatParams());
     $this->assertEquals(['bar' => 'bar', 'foo' => 'foo'], $new->getArrayCopy());
 }