/var/www/flurhymez/vendor/phpspec/prophecy/src/Prophecy/Argument/Token
NameSizeModeActions
AnyValuesToken.php9860644editdlrm
AnyValueToken.php9390644editdlrm
ApproximateValueToken.php11660644editdlrm
ArrayCountToken.php17610644editdlrm
ArrayEntryToken.php37320644editdlrm
ArrayEveryEntryToken.php16820644editdlrm
CallbackToken.php15800644editdlrm
ExactValueToken.php30080644editdlrm
IdenticalValueToken.php15100644editdlrm
InArrayToken.php14890644editdlrm
LogicalAndToken.php17840644editdlrm
LogicalNotToken.php15510644editdlrm
NotInArrayToken.php14980644editdlrm
ObjectStateToken.php26170644editdlrm
StringContainsToken.php13000644editdlrm
TokenInterface.php9120644editdlrm
TypeToken.php17010644editdlrm
Edit: /var/www/flurhymez/vendor/phpspec/prophecy/src/Prophecy/Argument/Token/ArrayEveryEntryToken.php (1682B)
* Marcello Duarte * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Prophecy\Argument\Token; /** * Array every entry token. * * @author Adrien Brault */ class ArrayEveryEntryToken implements TokenInterface { /** * @var TokenInterface */ private $value; /** * @param mixed $value exact value or token */ public function __construct($value) { if (!$value instanceof TokenInterface) { $value = new ExactValueToken($value); } $this->value = $value; } /** * {@inheritdoc} */ public function scoreArgument($argument) { if (!$argument instanceof \Traversable && !is_array($argument)) { return false; } $scores = array(); foreach ($argument as $key => $argumentEntry) { $scores[] = $this->value->scoreArgument($argumentEntry); } if (empty($scores) || in_array(false, $scores, true)) { return false; } return array_sum($scores) / count($scores); } /** * {@inheritdoc} */ public function isLast() { return false; } /** * {@inheritdoc} */ public function __toString() { return sprintf('[%s, ..., %s]', $this->value, $this->value); } /** * @return TokenInterface */ public function getValue() { return $this->value; } }