Since: 1.0
Author: Bernhard Schussek (bschussek@gmail.com)
Example #1
0
 /**
  * {@inheritdoc}
  */
 public function toString()
 {
     return '===' . StringUtil::formatValue($this->comparedValue);
 }
Example #2
0
 /**
  * {@inheritdoc}
  */
 public function toString()
 {
     return 'contains(' . StringUtil::formatValue($this->comparedValue) . ')';
 }
Example #3
0
 /**
  * {@inheritdoc}
  */
 public function toString()
 {
     $exprString = $this->expr->toString();
     $argsString = implode(', ', StringUtil::formatValues($this->arguments));
     if ($this->expr instanceof AndX || $this->expr instanceof OrX) {
         return $this->methodName . '(' . $argsString . '){' . $exprString . '}';
     }
     // Append "functions" with "."
     if (isset($exprString[0]) && ctype_alpha($exprString[0])) {
         return $this->methodName . '(' . $argsString . ').' . $exprString;
     }
     return $this->methodName . '(' . $argsString . ')' . $exprString;
 }
Example #4
0
 /**
  * {@inheritdoc}
  */
 public function toString()
 {
     return 'startsWith(' . StringUtil::formatValue($this->acceptedPrefix) . ')';
 }
Example #5
0
 /**
  * {@inheritdoc}
  */
 public function toString()
 {
     return 'endsWith(' . StringUtil::formatValue($this->acceptedSuffix) . ')';
 }
Example #6
0
 /**
  * {@inheritdoc}
  */
 public function toString()
 {
     return 'matches(' . StringUtil::formatValue($this->regExp) . ')';
 }
Example #7
0
 /**
  * {@inheritdoc}
  */
 public function toString()
 {
     return 'keyExists(' . StringUtil::formatValue($this->key) . ')';
 }
Example #8
0
 /**
  * {@inheritdoc}
  */
 public function toString()
 {
     $values = array_map(function ($value) {
         return StringUtil::formatValue($value);
     }, $this->acceptedValues);
     return 'in(' . implode(', ', $values) . ')';
 }