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 18namespace Google\Service\Dfareporting\Resource; 19 20use Google\Service\Dfareporting\FloodlightActivitiesGenerateTagResponse; 21use Google\Service\Dfareporting\FloodlightActivitiesListResponse; 22use Google\Service\Dfareporting\FloodlightActivity; 23 24/** 25 * The "floodlightActivities" collection of methods. 26 * Typical usage is: 27 * <code> 28 * $dfareportingService = new Google\Service\Dfareporting(...); 29 * $floodlightActivities = $dfareportingService->floodlightActivities; 30 * </code> 31 */ 32class FloodlightActivities extends \Google\Service\Resource 33{ 34 /** 35 * Deletes an existing floodlight activity. (floodlightActivities.delete) 36 * 37 * @param string $profileId User profile ID associated with this request. 38 * @param string $id Floodlight activity ID. 39 * @param array $optParams Optional parameters. 40 */ 41 public function delete($profileId, $id, $optParams = []) 42 { 43 $params = ['profileId' => $profileId, 'id' => $id]; 44 $params = array_merge($params, $optParams); 45 return $this->call('delete', [$params]); 46 } 47 /** 48 * Generates a tag for a floodlight activity. (floodlightActivities.generatetag) 49 * 50 * @param string $profileId User profile ID associated with this request. 51 * @param array $optParams Optional parameters. 52 * 53 * @opt_param string floodlightActivityId Floodlight activity ID for which we 54 * want to generate a tag. 55 * @return FloodlightActivitiesGenerateTagResponse 56 */ 57 public function generatetag($profileId, $optParams = []) 58 { 59 $params = ['profileId' => $profileId]; 60 $params = array_merge($params, $optParams); 61 return $this->call('generatetag', [$params], FloodlightActivitiesGenerateTagResponse::class); 62 } 63 /** 64 * Gets one floodlight activity by ID. (floodlightActivities.get) 65 * 66 * @param string $profileId User profile ID associated with this request. 67 * @param string $id Floodlight activity ID. 68 * @param array $optParams Optional parameters. 69 * @return FloodlightActivity 70 */ 71 public function get($profileId, $id, $optParams = []) 72 { 73 $params = ['profileId' => $profileId, 'id' => $id]; 74 $params = array_merge($params, $optParams); 75 return $this->call('get', [$params], FloodlightActivity::class); 76 } 77 /** 78 * Inserts a new floodlight activity. (floodlightActivities.insert) 79 * 80 * @param string $profileId User profile ID associated with this request. 81 * @param FloodlightActivity $postBody 82 * @param array $optParams Optional parameters. 83 * @return FloodlightActivity 84 */ 85 public function insert($profileId, FloodlightActivity $postBody, $optParams = []) 86 { 87 $params = ['profileId' => $profileId, 'postBody' => $postBody]; 88 $params = array_merge($params, $optParams); 89 return $this->call('insert', [$params], FloodlightActivity::class); 90 } 91 /** 92 * Retrieves a list of floodlight activities, possibly filtered. This method 93 * supports paging. (floodlightActivities.listFloodlightActivities) 94 * 95 * @param string $profileId User profile ID associated with this request. 96 * @param array $optParams Optional parameters. 97 * 98 * @opt_param string advertiserId Select only floodlight activities for the 99 * specified advertiser ID. Must specify either ids, advertiserId, or 100 * floodlightConfigurationId for a non-empty result. 101 * @opt_param string floodlightActivityGroupIds Select only floodlight 102 * activities with the specified floodlight activity group IDs. 103 * @opt_param string floodlightActivityGroupName Select only floodlight 104 * activities with the specified floodlight activity group name. 105 * @opt_param string floodlightActivityGroupTagString Select only floodlight 106 * activities with the specified floodlight activity group tag string. 107 * @opt_param string floodlightActivityGroupType Select only floodlight 108 * activities with the specified floodlight activity group type. 109 * @opt_param string floodlightConfigurationId Select only floodlight activities 110 * for the specified floodlight configuration ID. Must specify either ids, 111 * advertiserId, or floodlightConfigurationId for a non-empty result. 112 * @opt_param string ids Select only floodlight activities with the specified 113 * IDs. Must specify either ids, advertiserId, or floodlightConfigurationId for 114 * a non-empty result. 115 * @opt_param int maxResults Maximum number of results to return. 116 * @opt_param string pageToken Value of the nextPageToken from the previous 117 * result page. 118 * @opt_param string searchString Allows searching for objects by name or ID. 119 * Wildcards (*) are allowed. For example, "floodlightactivity*2015" will return 120 * objects with names like "floodlightactivity June 2015", "floodlightactivity 121 * April 2015", or simply "floodlightactivity 2015". Most of the searches also 122 * add wildcards implicitly at the start and the end of the search string. For 123 * example, a search string of "floodlightactivity" will match objects with name 124 * "my floodlightactivity activity", "floodlightactivity 2015", or simply 125 * "floodlightactivity". 126 * @opt_param string sortField Field by which to sort the list. 127 * @opt_param string sortOrder Order of sorted results. 128 * @opt_param string tagString Select only floodlight activities with the 129 * specified tag string. 130 * @return FloodlightActivitiesListResponse 131 */ 132 public function listFloodlightActivities($profileId, $optParams = []) 133 { 134 $params = ['profileId' => $profileId]; 135 $params = array_merge($params, $optParams); 136 return $this->call('list', [$params], FloodlightActivitiesListResponse::class); 137 } 138 /** 139 * Updates an existing floodlight activity. This method supports patch 140 * semantics. (floodlightActivities.patch) 141 * 142 * @param string $profileId User profile ID associated with this request. 143 * @param string $id FloodlightActivity ID. 144 * @param FloodlightActivity $postBody 145 * @param array $optParams Optional parameters. 146 * @return FloodlightActivity 147 */ 148 public function patch($profileId, $id, FloodlightActivity $postBody, $optParams = []) 149 { 150 $params = ['profileId' => $profileId, 'id' => $id, 'postBody' => $postBody]; 151 $params = array_merge($params, $optParams); 152 return $this->call('patch', [$params], FloodlightActivity::class); 153 } 154 /** 155 * Updates an existing floodlight activity. (floodlightActivities.update) 156 * 157 * @param string $profileId User profile ID associated with this request. 158 * @param FloodlightActivity $postBody 159 * @param array $optParams Optional parameters. 160 * @return FloodlightActivity 161 */ 162 public function update($profileId, FloodlightActivity $postBody, $optParams = []) 163 { 164 $params = ['profileId' => $profileId, 'postBody' => $postBody]; 165 $params = array_merge($params, $optParams); 166 return $this->call('update', [$params], FloodlightActivity::class); 167 } 168} 169 170// Adding a class alias for backwards compatibility with the previous class name. 171class_alias(FloodlightActivities::class, 'Google_Service_Dfareporting_Resource_FloodlightActivities'); 172