'成功', self::FAILURE => '失败' }; } public function color():string{ return match($this) { self::SUCCESS => 'success', self::FAILURE => 'error' }; } }