Something went wrong. Try again.
[READ-ONLY] Mirror of https://github.com/openstatusHQ/sdk-php. php sdk for openstatus www.openstatus.dev
Something went wrong. Try again.
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970<?php# Generated by the protocol buffer compiler. DO NOT EDIT!# NO CHECKED-IN PROTOBUF GENCODE# source: openstatus/monitor/v1/monitor.proto
namespace Openstatus\Monitor\V1;
use UnexpectedValueException;
/** * MonitorStatus represents the operational status of a monitor. * * Protobuf type <code>openstatus.monitor.v1.MonitorStatus</code> */class MonitorStatus{ /** * MONITOR_STATUS_UNSPECIFIED indicates an unknown status. * * Generated from protobuf enum <code>MONITOR_STATUS_UNSPECIFIED = 0;</code> */ const MONITOR_STATUS_UNSPECIFIED = 0; /** * MONITOR_STATUS_ACTIVE indicates the monitor is actively checking. * * Generated from protobuf enum <code>MONITOR_STATUS_ACTIVE = 1;</code> */ const MONITOR_STATUS_ACTIVE = 1; /** * MONITOR_STATUS_DEGRADED indicates the monitor is degraded. * * Generated from protobuf enum <code>MONITOR_STATUS_DEGRADED = 2;</code> */ const MONITOR_STATUS_DEGRADED = 2; /** * MONITOR_STATUS_ERROR indicates the monitor is in an error state. * * Generated from protobuf enum <code>MONITOR_STATUS_ERROR = 3;</code> */ const MONITOR_STATUS_ERROR = 3;
private static $valueToName = [ self::MONITOR_STATUS_UNSPECIFIED => 'MONITOR_STATUS_UNSPECIFIED', self::MONITOR_STATUS_ACTIVE => 'MONITOR_STATUS_ACTIVE', self::MONITOR_STATUS_DEGRADED => 'MONITOR_STATUS_DEGRADED', self::MONITOR_STATUS_ERROR => 'MONITOR_STATUS_ERROR', ];
public static function name($value) { if (!isset(self::$valueToName[$value])) { throw new UnexpectedValueException(sprintf( 'Enum %s has no name defined for value %s', __CLASS__, $value)); } return self::$valueToName[$value]; }
public static function value($name) { $const = __CLASS__ . '::' . strtoupper($name); if (!defined($const)) { throw new UnexpectedValueException(sprintf( 'Enum %s has no value defined for name %s', __CLASS__, $name)); } return constant($const); }}