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.
8.6 kB · 281 lines
PHP
at main
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282<?php# Generated by the protocol buffer compiler. DO NOT EDIT!# NO CHECKED-IN PROTOBUF GENCODE# source: openstatus/maintenance/v1/service.proto
namespace Openstatus\Maintenance\V1;
use Google\Protobuf\Internal\GPBType;use Google\Protobuf\Internal\GPBUtil;use Google\Protobuf\RepeatedField;
/** * CreateMaintenanceRequest is the request to create a new maintenance window. * * Generated from protobuf message <code>openstatus.maintenance.v1.CreateMaintenanceRequest</code> */class CreateMaintenanceRequest extends \Google\Protobuf\Internal\Message{ /** * Title of the maintenance (required, 1-256 characters). * * Generated from protobuf field <code>string title = 1 [json_name = "title", (.gnostic.openapi.v3.property) = {</code> */ protected $title = ''; /** * Message describing the maintenance (required). * * Generated from protobuf field <code>string message = 2 [json_name = "message", (.buf.validate.field) = {</code> */ protected $message = ''; /** * Start time of the maintenance window (RFC 3339 format, required). * * Generated from protobuf field <code>string from = 3 [json_name = "from", (.gnostic.openapi.v3.property) = {</code> */ protected $from = ''; /** * End time of the maintenance window (RFC 3339 format, required). * * Generated from protobuf field <code>string to = 4 [json_name = "to", (.gnostic.openapi.v3.property) = {</code> */ protected $to = ''; /** * Page ID to associate with this maintenance (required). * * Generated from protobuf field <code>string page_id = 5 [json_name = "pageId", (.buf.validate.field) = {</code> */ protected $page_id = ''; /** * Page component IDs to associate with this maintenance (optional). * * Generated from protobuf field <code>repeated string page_component_ids = 6 [json_name = "pageComponentIds"];</code> */ private $page_component_ids; /** * Whether to notify subscribers about this maintenance (optional, defaults to false). * * Generated from protobuf field <code>optional bool notify = 7 [json_name = "notify"];</code> */ protected $notify = null;
/** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type string $title * Title of the maintenance (required, 1-256 characters). * @type string $message * Message describing the maintenance (required). * @type string $from * Start time of the maintenance window (RFC 3339 format, required). * @type string $to * End time of the maintenance window (RFC 3339 format, required). * @type string $page_id * Page ID to associate with this maintenance (required). * @type string[] $page_component_ids * Page component IDs to associate with this maintenance (optional). * @type bool $notify * Whether to notify subscribers about this maintenance (optional, defaults to false). * } */ public function __construct($data = NULL) { \GPBMetadata\Openstatus\Maintenance\V1\Service::initOnce(); parent::__construct($data); }
/** * Title of the maintenance (required, 1-256 characters). * * Generated from protobuf field <code>string title = 1 [json_name = "title", (.gnostic.openapi.v3.property) = {</code> * @return string */ public function getTitle() { return $this->title; }
/** * Title of the maintenance (required, 1-256 characters). * * Generated from protobuf field <code>string title = 1 [json_name = "title", (.gnostic.openapi.v3.property) = {</code> * @param string $var * @return $this */ public function setTitle(string $var) { GPBUtil::checkString($var, true); $this->title = $var;
return $this; }
/** * Message describing the maintenance (required). * * Generated from protobuf field <code>string message = 2 [json_name = "message", (.buf.validate.field) = {</code> * @return string */ public function getMessage() { return $this->message; }
/** * Message describing the maintenance (required). * * Generated from protobuf field <code>string message = 2 [json_name = "message", (.buf.validate.field) = {</code> * @param string $var * @return $this */ public function setMessage(string $var) { GPBUtil::checkString($var, true); $this->message = $var;
return $this; }
/** * Start time of the maintenance window (RFC 3339 format, required). * * Generated from protobuf field <code>string from = 3 [json_name = "from", (.gnostic.openapi.v3.property) = {</code> * @return string */ public function getFrom() { return $this->from; }
/** * Start time of the maintenance window (RFC 3339 format, required). * * Generated from protobuf field <code>string from = 3 [json_name = "from", (.gnostic.openapi.v3.property) = {</code> * @param string $var * @return $this */ public function setFrom(string $var) { GPBUtil::checkString($var, true); $this->from = $var;
return $this; }
/** * End time of the maintenance window (RFC 3339 format, required). * * Generated from protobuf field <code>string to = 4 [json_name = "to", (.gnostic.openapi.v3.property) = {</code> * @return string */ public function getTo() { return $this->to; }
/** * End time of the maintenance window (RFC 3339 format, required). * * Generated from protobuf field <code>string to = 4 [json_name = "to", (.gnostic.openapi.v3.property) = {</code> * @param string $var * @return $this */ public function setTo(string $var) { GPBUtil::checkString($var, true); $this->to = $var;
return $this; }
/** * Page ID to associate with this maintenance (required). * * Generated from protobuf field <code>string page_id = 5 [json_name = "pageId", (.buf.validate.field) = {</code> * @return string */ public function getPageId() { return $this->page_id; }
/** * Page ID to associate with this maintenance (required). * * Generated from protobuf field <code>string page_id = 5 [json_name = "pageId", (.buf.validate.field) = {</code> * @param string $var * @return $this */ public function setPageId(string $var) { GPBUtil::checkString($var, true); $this->page_id = $var;
return $this; }
/** * Page component IDs to associate with this maintenance (optional). * * Generated from protobuf field <code>repeated string page_component_ids = 6 [json_name = "pageComponentIds"];</code> * @return RepeatedField<string> */ public function getPageComponentIds() { return $this->page_component_ids; }
/** * Page component IDs to associate with this maintenance (optional). * * Generated from protobuf field <code>repeated string page_component_ids = 6 [json_name = "pageComponentIds"];</code> * @param string[] $var * @return $this */ public function setPageComponentIds(array|RepeatedField $var) { $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); $this->page_component_ids = $arr;
return $this; }
/** * Whether to notify subscribers about this maintenance (optional, defaults to false). * * Generated from protobuf field <code>optional bool notify = 7 [json_name = "notify"];</code> * @return bool */ public function getNotify() { return isset($this->notify) ? $this->notify : false; }
public function hasNotify() { return isset($this->notify); }
public function clearNotify() { unset($this->notify); }
/** * Whether to notify subscribers about this maintenance (optional, defaults to false). * * Generated from protobuf field <code>optional bool notify = 7 [json_name = "notify"];</code> * @param bool $var * @return $this */ public function setNotify(bool $var) { $this->notify = $var;
return $this; }
}