1<?php 2/* 3 * Copyright 2014 Google Inc. 4 * 5 * Licensed under the Apache License, Version 2.0 (the "License"); you may not 6 * use this file except in compliance with the License. You may obtain a copy of 7 * the License at 8 * 9 * http://www.apache.org/licenses/LICENSE-2.0 10 * 11 * Unless required by applicable law or agreed to in writing, software 12 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 14 * License for the specific language governing permissions and limitations under 15 * the License. 16 */ 17 18/** 19 * The "interconnectLocations" collection of methods. 20 * Typical usage is: 21 * <code> 22 * $computeService = new Google_Service_Compute(...); 23 * $interconnectLocations = $computeService->interconnectLocations; 24 * </code> 25 */ 26class Google_Service_Compute_Resource_InterconnectLocations extends Google_Service_Resource 27{ 28 /** 29 * Returns the details for the specified interconnect location. Gets a list of 30 * available interconnect locations by making a list() request. 31 * (interconnectLocations.get) 32 * 33 * @param string $project Project ID for this request. 34 * @param string $interconnectLocation Name of the interconnect location to 35 * return. 36 * @param array $optParams Optional parameters. 37 * @return Google_Service_Compute_InterconnectLocation 38 */ 39 public function get($project, $interconnectLocation, $optParams = array()) 40 { 41 $params = array('project' => $project, 'interconnectLocation' => $interconnectLocation); 42 $params = array_merge($params, $optParams); 43 return $this->call('get', array($params), "Google_Service_Compute_InterconnectLocation"); 44 } 45 /** 46 * Retrieves the list of interconnect locations available to the specified 47 * project. (interconnectLocations.listInterconnectLocations) 48 * 49 * @param string $project Project ID for this request. 50 * @param array $optParams Optional parameters. 51 * 52 * @opt_param string filter A filter expression that filters resources listed in 53 * the response. The expression must specify the field name, a comparison 54 * operator, and the value that you want to use for filtering. The value must be 55 * a string, a number, or a boolean. The comparison operator must be either `=`, 56 * `!=`, `>`, or `<`. 57 * 58 * For example, if you are filtering Compute Engine instances, you can exclude 59 * instances named `example-instance` by specifying `name != example-instance`. 60 * 61 * You can also filter nested fields. For example, you could specify 62 * `scheduling.automaticRestart = false` to include instances only if they are 63 * not scheduled for automatic restarts. You can use filtering on nested fields 64 * to filter based on resource labels. 65 * 66 * To filter on multiple expressions, provide each separate expression within 67 * parentheses. For example: ``` (scheduling.automaticRestart = true) 68 * (cpuPlatform = "Intel Skylake") ``` By default, each expression is an `AND` 69 * expression. However, you can include `AND` and `OR` expressions explicitly. 70 * For example: ``` (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel 71 * Broadwell") AND (scheduling.automaticRestart = true) ``` 72 * @opt_param string maxResults The maximum number of results per page that 73 * should be returned. If the number of available results is larger than 74 * `maxResults`, Compute Engine returns a `nextPageToken` that can be used to 75 * get the next page of results in subsequent list requests. Acceptable values 76 * are `0` to `500`, inclusive. (Default: `500`) 77 * @opt_param string orderBy Sorts list results by a certain order. By default, 78 * results are returned in alphanumerical order based on the resource name. 79 * 80 * You can also sort results in descending order based on the creation timestamp 81 * using `orderBy="creationTimestamp desc"`. This sorts results based on the 82 * `creationTimestamp` field in reverse chronological order (newest result 83 * first). Use this to sort resources like operations so that the newest 84 * operation is returned first. 85 * 86 * Currently, only sorting by `name` or `creationTimestamp desc` is supported. 87 * @opt_param string pageToken Specifies a page token to use. Set `pageToken` to 88 * the `nextPageToken` returned by a previous list request to get the next page 89 * of results. 90 * @opt_param bool returnPartialSuccess Opt-in for partial success behavior 91 * which provides partial results in case of failure. The default value is 92 * false. 93 * @return Google_Service_Compute_InterconnectLocationList 94 */ 95 public function listInterconnectLocations($project, $optParams = array()) 96 { 97 $params = array('project' => $project); 98 $params = array_merge($params, $optParams); 99 return $this->call('list', array($params), "Google_Service_Compute_InterconnectLocationList"); 100 } 101} 102