Google_Service_Monitoring_Resource_ProjectsAlertPolicies
extends Google_Service_Resource
in package
The "alertPolicies" collection of methods.
Typical usage is:
$monitoringService = new Google_Service_Monitoring(...);
$alertPolicies = $monitoringService->alertPolicies;
Table of Contents
- $client : Google_Client
- $methods : array<string|int, mixed>
- $resourceName : string
- $rootUrl : string
- $serviceName : string
- $servicePath : string
- $stackParameters : mixed
- __construct() : mixed
- call() : Google_Http_Request|expectedClass
- TODO: This function needs simplifying.
- create() : Google_Service_Monitoring_AlertPolicy
- Creates a new alerting policy. (alertPolicies.create)
- createRequestUri() : string
- Parse/expand request parameters and create a fully qualified request uri.
- delete() : Google_Service_Monitoring_MonitoringEmpty
- Deletes an alerting policy. (alertPolicies.delete)
- get() : Google_Service_Monitoring_AlertPolicy
- Gets a single alerting policy. (alertPolicies.get)
- listProjectsAlertPolicies() : Google_Service_Monitoring_ListAlertPoliciesResponse
- Lists the existing alerting policies for the workspace.
- patch() : Google_Service_Monitoring_AlertPolicy
- Updates an alerting policy. You can either replace the entire policy with a new one or replace only certain fields in the current alerting policy by specifying the fields to be updated via updateMask. Returns the updated alerting policy. (alertPolicies.patch)
- convertToArrayAndStripNulls() : mixed
Properties
$client
private
Google_Client
$client
$methods
private
array<string|int, mixed>
$methods
$resourceName
private
string
$resourceName
$rootUrl
private
string
$rootUrl
$serviceName
private
string
$serviceName
$servicePath
private
string
$servicePath
$stackParameters
private
mixed
$stackParameters
= array('alt' => array('type' => 'string', 'location' => 'query'), 'fields' => array('type' => 'string', 'location' => 'query'), 'trace' => array('type' => 'string', 'location' => 'query'), 'userIp' => array('type' => 'string', 'location' => 'query'), 'quotaUser' => array('type' => 'string', 'location' => 'query'), 'data' => array('type' => 'string', 'location' => 'body'), 'mimeType' => array('type' => 'string', 'location' => 'header'), 'uploadType' => array('type' => 'string', 'location' => 'query'), 'mediaUpload' => array('type' => 'complex', 'location' => 'query'), 'prettyPrint' => array('type' => 'string', 'location' => 'query'))
Methods
__construct()
public
__construct(mixed $service, mixed $serviceName, mixed $resourceName, mixed $resource) : mixed
Parameters
- $service : mixed
- $serviceName : mixed
- $resourceName : mixed
- $resource : mixed
Return values
mixed —call()
TODO: This function needs simplifying.
public
call( $name, $arguments[, $expectedClass = null ]) : Google_Http_Request|expectedClass
Parameters
Tags
Return values
Google_Http_Request|expectedClass —create()
Creates a new alerting policy. (alertPolicies.create)
public
create(string $name, Google_Service_Monitoring_AlertPolicy $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Monitoring_AlertPolicy
Parameters
- $name : string
-
Required. The project in which to create the alerting policy. The format is: projects/[PROJECT_ID_OR_NUMBER] Note that this field names the parent container in which the alerting policy will be written, not the name of the created policy. |name| must be a host project of a workspace, otherwise INVALID_ARGUMENT error will return. The alerting policy that is returned will have a name that contains a normalized representation of this name as a prefix but adds a suffix of the form /alertPolicies/[ALERT_POLICY_ID], identifying the policy in the container.
- $postBody : Google_Service_Monitoring_AlertPolicy
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Return values
Google_Service_Monitoring_AlertPolicy —createRequestUri()
Parse/expand request parameters and create a fully qualified request uri.
public
createRequestUri(string $restPath, array<string|int, mixed> $params) : string
Parameters
- $restPath : string
- $params : array<string|int, mixed>
Tags
Return values
string —$requestUrl
delete()
Deletes an alerting policy. (alertPolicies.delete)
public
delete(string $name[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Monitoring_MonitoringEmpty
Parameters
- $name : string
-
Required. The alerting policy to delete. The format is: projects/[PROJECT_ID_OR_NUMBER]/alertPolicies/[ALERT_POLICY_ID] For more information, see AlertPolicy.
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Return values
Google_Service_Monitoring_MonitoringEmpty —get()
Gets a single alerting policy. (alertPolicies.get)
public
get(string $name[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Monitoring_AlertPolicy
Parameters
- $name : string
-
Required. The alerting policy to retrieve. The format is: projects/[PROJECT_ID_OR_NUMBER]/alertPolicies/[ALERT_POLICY_ID]
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Return values
Google_Service_Monitoring_AlertPolicy —listProjectsAlertPolicies()
Lists the existing alerting policies for the workspace.
public
listProjectsAlertPolicies(string $name[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Monitoring_ListAlertPoliciesResponse
(alertPolicies.listProjectsAlertPolicies)
Parameters
- $name : string
-
Required. The project whose alert policies are to be listed. The format is: projects/[PROJECT_ID_OR_NUMBER] Note that this field names the parent container in which the alerting policies to be listed are stored. To retrieve a single alerting policy by name, use the GetAlertPolicy operation, instead.
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Tags
Return values
Google_Service_Monitoring_ListAlertPoliciesResponse —patch()
Updates an alerting policy. You can either replace the entire policy with a new one or replace only certain fields in the current alerting policy by specifying the fields to be updated via updateMask. Returns the updated alerting policy. (alertPolicies.patch)
public
patch(string $name, Google_Service_Monitoring_AlertPolicy $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Monitoring_AlertPolicy
Parameters
- $name : string
-
Required if the policy exists. The resource name for this policy. The format is: projects/[PROJECT_ID_OR_NUMBER]/alertPolicies/[ALERT_POLICY_ID] [ALERT_POLICY_ID] is assigned by Stackdriver Monitoring when the policy is created. When calling the alertPolicies.create method, do not include the name field in the alerting policy passed as part of the request.
- $postBody : Google_Service_Monitoring_AlertPolicy
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Tags
Return values
Google_Service_Monitoring_AlertPolicy —convertToArrayAndStripNulls()
protected
convertToArrayAndStripNulls(mixed $o) : mixed
Parameters
- $o : mixed