for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Caxy\HtmlDiff\ListDiff;
class DiffList
{
protected $listType;
protected $listItems = array();
protected $attributes = array();
protected $startTag;
protected $endTag;
public function __construct($listType, $startTag, $endTag, $listItems = array(), $attributes = array())
$this->listType = $listType;
This check looks for multiple assignments in successive lines of code. It will report an issue if the operators are not in a straight line.
To visualize
$a = "a"; $ab = "ab"; $abc = "abc";
will produce issues in the first and second line, while this second example
will produce no issues.
$this->startTag = $startTag;
$this->endTag = $endTag;
$this->listItems = $listItems;
$this->attributes = $attributes;
}
/**
* @return mixed
*/
public function getListType()
return $this->listType;
* @param mixed $listType
*
* @return DiffList
public function setListType($listType)
return $this;
public function getStartTag()
return $this->startTag;
public function getStartTagWithDiffClass($class = 'diff-list')
return str_replace('>', ' class="'.$class.'">', $this->startTag);
* @param mixed $startTag
public function setStartTag($startTag)
public function getEndTag()
return $this->endTag;
* @param mixed $endTag
public function setEndTag($endTag)
public function getListItems()
return $this->listItems;
* @param mixed $listItems
public function setListItems($listItems)
$listItems
array
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..
This check looks for multiple assignments in successive lines of code. It will report an issue if the operators are not in a straight line.
To visualize
will produce issues in the first and second line, while this second example
will produce no issues.