for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Caxy\HtmlDiff\Table;
class TableCell extends AbstractTableElement
{
/**
* @var TableRow
*/
protected $row;
public function getRow()
return $this->row;
}
public function setRow(TableRow $row = null)
$this->row = $row;
if (!in_array($this, $row->getCells())) {
$row->addCell($this);
$row
null
If a variable is not always an object, we recommend to add an additional type check to ensure your method call is safe:
function someFunction(A $objectMaybe = null) { if ($objectMaybe instanceof A) { $objectMaybe->doSomething(); } }
return $this;
public function getColspan()
return $this->getAttribute('colspan') ?: 1;
public function getRowspan()
return $this->getAttribute('rowspan') ?: 1;
If a variable is not always an object, we recommend to add an additional type check to ensure your method call is safe: