Differential D18341 Diff 44160 src/applications/differential/constants/DifferentialRevisionStatus.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/differential/constants/DifferentialRevisionStatus.php
| Show All 38 Lines | final class DifferentialRevisionStatus extends Phobject { | ||||
| public function isAccepted() { | public function isAccepted() { | ||||
| return ($this->key === self::ACCEPTED); | return ($this->key === self::ACCEPTED); | ||||
| } | } | ||||
| public function isNeedsReview() { | public function isNeedsReview() { | ||||
| return ($this->key === self::NEEDS_REVIEW); | return ($this->key === self::NEEDS_REVIEW); | ||||
| } | } | ||||
| public function isPublished() { | |||||
| return ($this->key === self::PUBLISHED); | |||||
| } | |||||
| public function isChangePlanned() { | |||||
| return ($this->key === self::CHANGES_PLANNED); | |||||
| } | |||||
| public static function newForLegacyStatus($legacy_status) { | public static function newForLegacyStatus($legacy_status) { | ||||
| $result = new self(); | $result = new self(); | ||||
| $map = self::getMap(); | $map = self::getMap(); | ||||
| foreach ($map as $key => $spec) { | foreach ($map as $key => $spec) { | ||||
| if (!isset($spec['legacy'])) { | if (!isset($spec['legacy'])) { | ||||
| continue; | continue; | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 105 Lines • Show Last 20 Lines | |||||