Path: blob/master/src/applications/herald/query/HeraldWebhookQuery.php
12256 views
<?php12final class HeraldWebhookQuery3extends PhabricatorCursorPagedPolicyAwareQuery {45private $ids;6private $phids;7private $statuses;89public function withIDs(array $ids) {10$this->ids = $ids;11return $this;12}1314public function withPHIDs(array $phids) {15$this->phids = $phids;16return $this;17}1819public function withStatuses(array $statuses) {20$this->statuses = $statuses;21return $this;22}2324public function newResultObject() {25return new HeraldWebhook();26}2728protected function buildWhereClauseParts(AphrontDatabaseConnection $conn) {29$where = parent::buildWhereClauseParts($conn);3031if ($this->ids !== null) {32$where[] = qsprintf(33$conn,34'id IN (%Ld)',35$this->ids);36}3738if ($this->phids !== null) {39$where[] = qsprintf(40$conn,41'phid IN (%Ls)',42$this->phids);43}4445if ($this->statuses !== null) {46$where[] = qsprintf(47$conn,48'status IN (%Ls)',49$this->statuses);50}5152return $where;53}5455public function getQueryApplicationClass() {56return 'PhabricatorHeraldApplication';57}5859}606162