Perforce Chronicle 2012.2/486814
API Documentation
|
Collection of named diff results. More...
Public Member Functions | |
__construct (array $results, P4Cms_Diff_OptionsCollection $options) | |
Create a new diff result collection from array of results. | |
getDiffCount () | |
Count all of the differences across all diff results. | |
getOptionsCollection () | |
Get the original options collection that produced this result (ie. | |
hasDiffs () | |
Determine if there are any differences in this collection. | |
Protected Attributes | |
$_options = null |
Collection of named diff results.
P4Cms_Diff_ResultCollection::__construct | ( | array $ | results, |
P4Cms_Diff_OptionsCollection $ | options | ||
) |
Create a new diff result collection from array of results.
array | $results | array of diff results. |
P4Cms_Diff_OptionsCollection | $options | original options collection. |
{ $this->_options = $options; parent::__construct($results); }
P4Cms_Diff_ResultCollection::getDiffCount | ( | ) |
Count all of the differences across all diff results.
{ $count = 0; foreach ($this as $result) { if ($result instanceof P4Cms_Diff_Result) { $count += $result->getDiffCount(); } } return $count; }
P4Cms_Diff_ResultCollection::getOptionsCollection | ( | ) |
Get the original options collection that produced this result (ie.
the options passed to the compare method).
{
return $this->_options;
}
P4Cms_Diff_ResultCollection::hasDiffs | ( | ) |
Determine if there are any differences in this collection.
{ return (bool) $this->getDiffCount(); }
P4Cms_Diff_ResultCollection::$_options = null [protected] |