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\AdExchangeBuyer\Resource; 19 20use Google\Service\AdExchangeBuyer\AddOrderNotesRequest; 21use Google\Service\AdExchangeBuyer\AddOrderNotesResponse; 22use Google\Service\AdExchangeBuyer\GetOrderNotesResponse; 23 24/** 25 * The "marketplacenotes" collection of methods. 26 * Typical usage is: 27 * <code> 28 * $adexchangebuyerService = new Google\Service\AdExchangeBuyer(...); 29 * $marketplacenotes = $adexchangebuyerService->marketplacenotes; 30 * </code> 31 */ 32class Marketplacenotes extends \Google\Service\Resource 33{ 34 /** 35 * Add notes to the proposal (marketplacenotes.insert) 36 * 37 * @param string $proposalId The proposalId to add notes for. 38 * @param AddOrderNotesRequest $postBody 39 * @param array $optParams Optional parameters. 40 * @return AddOrderNotesResponse 41 */ 42 public function insert($proposalId, AddOrderNotesRequest $postBody, $optParams = []) 43 { 44 $params = ['proposalId' => $proposalId, 'postBody' => $postBody]; 45 $params = array_merge($params, $optParams); 46 return $this->call('insert', [$params], AddOrderNotesResponse::class); 47 } 48 /** 49 * Get all the notes associated with a proposal 50 * (marketplacenotes.listMarketplacenotes) 51 * 52 * @param string $proposalId The proposalId to get notes for. To search across 53 * all proposals specify order_id = '-' as part of the URL. 54 * @param array $optParams Optional parameters. 55 * 56 * @opt_param string pqlQuery Query string to retrieve specific notes. To search 57 * the text contents of notes, please use syntax like "WHERE note.note = "foo" 58 * or "WHERE note.note LIKE "%bar%" 59 * @return GetOrderNotesResponse 60 */ 61 public function listMarketplacenotes($proposalId, $optParams = []) 62 { 63 $params = ['proposalId' => $proposalId]; 64 $params = array_merge($params, $optParams); 65 return $this->call('list', [$params], GetOrderNotesResponse::class); 66 } 67} 68 69// Adding a class alias for backwards compatibility with the previous class name. 70class_alias(Marketplacenotes::class, 'Google_Service_AdExchangeBuyer_Resource_Marketplacenotes'); 71