Changeset View
Changeset View
Standalone View
Standalone View
src/search/PhutilSearchQueryToken.php
| <?php | <?php | ||||
| final class PhutilSearchQueryToken extends Phobject { | final class PhutilSearchQueryToken extends Phobject { | ||||
| private $isQuoted; | private $isQuoted; | ||||
| private $value; | private $value; | ||||
| private $operator; | private $operator; | ||||
| private $function; | |||||
| public static function newFromDictionary(array $dictionary) { | public static function newFromDictionary(array $dictionary) { | ||||
| $token = new self(); | $token = new self(); | ||||
| $token->isQuoted = $dictionary['quoted']; | $token->isQuoted = $dictionary['quoted']; | ||||
| $token->operator = $dictionary['operator']; | $token->operator = $dictionary['operator']; | ||||
| $token->value = $dictionary['value']; | $token->value = $dictionary['value']; | ||||
| $token->function = idx($dictionary, 'function'); | |||||
| return $token; | return $token; | ||||
| } | } | ||||
| public function isQuoted() { | public function isQuoted() { | ||||
| return $this->isQuoted; | return $this->isQuoted; | ||||
| } | } | ||||
| public function getValue() { | public function getValue() { | ||||
| return $this->value; | return $this->value; | ||||
| } | } | ||||
| public function getOperator() { | public function getOperator() { | ||||
| return $this->operator; | return $this->operator; | ||||
| } | } | ||||
| public function getFunction() { | |||||
| return $this->function; | |||||
| } | |||||
| } | } | ||||